question-mark
Stuck on an issue?

Lightrun Answers was designed to reduce the constant googling that comes with debugging 3rd party libraries. It collects links to all the places you might be looking at while hunting down a tough bug.

And, if you’re still stuck at the end, we’re happy to hop on a call to see how we can help out.

BUG: Cannot get ride of Decprecation Warning with cKDTreeNode

See original GitHub issue

Describe your issue.

Cannot get ride of Deprecation Warning with cKDTreeNode As cKDTreeNode is not exposed at the root of scipy.spatial

Reproducing Code Example

import scipy.spatial.ckdtree

scipy.spatial.ckdtree.cKDTree()     # fixable!
scipy.spatial.ckdtree.cKDTreeNode() # not fixable!

# to fix it,as the Deprecation Warning states

import scipy.spatial
scipy.spatial.cKDTree() # fixes it!
scipy.spatial.cKDTreeNode() # errors out

The problem is that cKDTreeNode is not exposed in scipy.spatial
python -c "import scipy.spatial; print( scipy.spatial.cKDTreeNode )"
AttributeError: module 'scipy.spatial' has no attribute 'cKDTreeNode'

Error message

DeprecationWarning: Please use `cKDTree` from the `scipy.spatial` namespace, the `scipy.spatial.ckdtree` namespace is deprecated.

DeprecationWarning: Please use `cKDTreeNode` from the `scipy.spatial` namespace, the `scipy.spatial.ckdtree` namespace is deprecated.

SciPy/NumPy/Python version information

1.9.1 1.23.3 sys.version_info(major=3, minor=9, micro=13, releaselevel=‘final’, serial=0)

Issue Analytics

  • State:open
  • Created a year ago
  • Comments:13 (7 by maintainers)

github_iconTop GitHub Comments

1reaction
davelajoiecommented, Sep 19, 2022

Sure, but I will need to get up to speed on how to submit a PR first 😃 Maybe is the my time to get into open source software contributions after all…

1reaction
davelajoiecommented, Sep 19, 2022

as an information, I am using that class (cKDTreeNode), as it is returned by the code, so I am doing type checking. I checked and cKDTreeNode is not derived from cKDTree, otherwise I would just used cKDTree.

Read more comments on GitHub >

github_iconTop Results From Across the Web

How to ignore deprecation warnings in Python - Stack Overflow
In my case, the code that was causing the warning was from xgboost import XGBClassifier . I had to put warnings.filterwarnings("ignore", ...
Read more >
Chronic kidney disease - Treatment - NHS
Find out about the main treatments for chronic kidney disease (CKD), including lifestyle changes, medication, dialysis and kidney transplants.
Read more >
Chronic kidney disease - Illnesses & conditions - NHS inform
If you have stage four or five kidney disease, you can get a build-up of phosphate in your body because your kidneys cannot...
Read more >
Kidney disease: 11 ways it can affect your skin
If you have kidney disease, you won't see early warning signs on your skin. ... When kidneys cannot remove waste from your body,...
Read more >
Kidney failure (ESRD) - Symptoms, causes and treatment ...
Kidney failure cannot be reversed and is life-threatening if left untreated. However, dialysis or a kidney transplant can help you live for many ......
Read more >

github_iconTop Related Medium Post

No results found

github_iconTop Related StackOverflow Question

No results found

github_iconTroubleshoot Live Code

Lightrun enables developers to add logs, metrics and snapshots to live code - no restarts or redeploys required.
Start Free

github_iconTop Related Reddit Thread

No results found

github_iconTop Related Hackernoon Post

No results found

github_iconTop Related Tweet

No results found

github_iconTop Related Dev.to Post

No results found

github_iconTop Related Hashnode Post

No results found