You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
The contour plot crashes for some reason [1] with stacktrace [2] when a 0.00 charge is added as the only object.
A more fundamental question is whether to allow 0.00 charges and if that makes physics sense - then stop the user with a warning before even calling the python exec.
/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/matplotlib/contour.py:1230: UserWarning: No contour levels were found within the data range.
warnings.warn("No contour levels were found"
Traceback (most recent call last):
File "Plotter.py", line 82, in <module>
main()
File "Plotter.py", line 72, in main
plt.colorbar()
File "/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/matplotlib/pyplot.py", line 2320, in colorbar
ret = gcf().colorbar(mappable, cax = cax, ax=ax, **kw)
File "/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/matplotlib/figure.py", line 2098, in colorbar
cb = cbar.colorbar_factory(cax, mappable, **cb_kw)
File "/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/matplotlib/colorbar.py", line 1399, in colorbar_factory
cb = Colorbar(cax, mappable, **kwargs)
File "/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/matplotlib/colorbar.py", line 935, in __init__
ColorbarBase.__init__(self, ax, **kw)
File "/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/matplotlib/colorbar.py", line 327, in __init__
self.draw_all()
File "/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/matplotlib/colorbar.py", line 353, in draw_all
self._config_axes(X, Y)
File "/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/matplotlib/colorbar.py", line 437, in _config_axes
xy = self._outline(X, Y)
File "/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/matplotlib/colorbar.py", line 485, in _outline
x = np.take(np.ravel(np.transpose(X)), ii)
File "/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/numpy/core/fromnumeric.py", line 189, in take
return _wrapfunc(a, 'take', indices, axis=axis, out=out, mode=mode)
File "/workspace/ProjectX_Workspace/venv/local/lib/python2.7/site-packages/numpy/core/fromnumeric.py", line 56, in _wrapfunc
return getattr(obj, method)(*args, **kwds)
IndexError: index 2 is out of bounds for size 2
The text was updated successfully, but these errors were encountered:
The contour plot crashes for some reason [1] with stacktrace [2] when a 0.00 charge is added as the only object.
A more fundamental question is whether to allow 0.00 charges and if that makes physics sense - then stop the user with a warning before even calling the python exec.
[1] https://github.com/palkiakerr/ProjectX_Workspace/blob/4ef9ed7e0f7dcdb1afa447e49966305854b87954/src/Plotter.py#L72
[2]
The text was updated successfully, but these errors were encountered: