AssertionError in lut_manager with no data
- Dominant language
- Python
- Stars
- 1.4k
- Forks
- 316
- Avg merge
- 7h 44m
- Merged PRs (30d)
- 5
Description
When LUT data range is estimated from data, and data has no valid samples, several AssertionError exceptions appear on screen.
Somewhere a range of `[ 1.e+299 -1.e+299]` is being set in this case, triggering the exception.
These seem to be harmless but might perhaps hide an underlying problem?
```
Exception occurred in traits notification handler for object: , trait: data_range, old value: [0. 1.], new value: [ 1.e+299 -1.e+299]
Traceback (most recent call last):
File "C:\WinPython-64bit-3.8.3.0\python-3.8.3.amd64\lib\site-packages\traits\trait_notifiers.py", line 340, in __call__
self.handler(*args)
File "C:\WinPython-64bit-3.8.3.0\python-3.8.3.amd64\lib\site-packages\mayavi-4.7.2.dev0-py3.8-win-amd64.egg\mayavi\core\lut_manager.py", line 434, in _data_range_changed
assert value[0] <= value[1]
AssertionError
```
To reproduce, simply create an empty scalar scatter and try to plot glyphs. If subsequently data is added to that dataset everything works correctly.
```
from mayavi import mlab
ds = mlab.pipeline.scalar_scatter([], [], [], [])
h = mlab.pipeline.glyph(ds)
mlab.show()
```
Contributor guide
No contributing guide indexed for this repository
Assessment
This issue has not been assessed yet.