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.

Numpy warning on adding point layer

See original GitHub issue

🐛 Bug

Although I’ve not checked with other layer types yet, numpy warns every time a point layer is created.

To Reproduce

import napari
viewer = napari.view_points([1,2])

This warning is printed out

FutureWarning: elementwise comparison failed; returning scalar instead, but in the future will perform elementwise comparison
  return bool(asarray(a1 == a2).all())

Expected behavior

Environment

  • Please copy and paste the information at napari info option in help menubar here:

napari: 0.4.15rc0 Platform: Windows-10-10.0.22000-SP0 Python: 3.9.7 (default, Sep 16 2021, 16:59:28) [MSC v.1916 64 bit (AMD64)] Qt: 5.15.2 PyQt5: 5.15.6 NumPy: 1.21.5 SciPy: 1.7.3 Dask: 2021.11.1 VisPy: 0.9.6

OpenGL:

  • GL version: 4.6.0 - Build 27.20.100.9621
  • MAX_TEXTURE_SIZE: 16384

Screens:

  • screen 1: resolution 1368x912, scale 2.0

Plugins:

  • animation: 0.0.2
  • console: 0.0.4
  • napari-multitask: 0.0.2
  • napari-roi: 0.1.0
  • scikit-image: 0.4.15rc0
  • svg: 0.1.5

Any other relevant information:

  • numpy: 1.21.5

Additional context

Issue Analytics

  • State:closed
  • Created 2 years ago
  • Reactions:1
  • Comments:5 (5 by maintainers)

github_iconTop GitHub Comments

1reaction
VolkerHcommented, Mar 18, 2022

just confirming that it is fixed

0reactions
VolkerHcommented, Mar 18, 2022

Thanks, I looked for an issue with FutureWarning. I found this and overlooked #4526

Will give it a try.

Read more comments on GitHub >

github_iconTop Results From Across the Web

shapely 2.0 warning Convert the '.coords' to a NumPy array ...
Unless I am missing something, the warning seems completely unrelated to the code. Does anybody know if this will become an issue when...
Read more >
numpy warning with django 4 - 'numpy.float64'> type is zero
OpenCV has the habit of setting the floating point handling to "flush to zero". There is a good reason for wanting to do...
Read more >
The numpy.ma module — NumPy v1.24 Manual
Masked arrays are arrays that may have missing or invalid entries. The numpy.ma module provides a nearly work-alike replacement for numpy that supports...
Read more >
Numpy - mbedded.ninja
A tutorial on how to use Numpy, a popular library for Python that provides powerful array/matrix manipulation.
Read more >
Numpy Axes, Explained - Sharp Sight
I'll explain more about this later in the tutorial. NumPy array axes are numbered starting with '0'. It is probably obvious at this...
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