[yt-dev] Issue #644: PR 87 causes test failure in test_offaxisprojection (yt_analysis/yt)

Kacper Kowalik issues-reply at bitbucket.org
Tue Sep 3 12:31:56 PDT 2013


New issue 644: PR 87 causes test failure in test_offaxisprojection
https://bitbucket.org/yt_analysis/yt/issue/644/pr-87-causes-test-failure-in

Kacper Kowalik:

Revision 3aba7ca1ff0b causes

````
======================================================================
ERROR: Failure: ValueError (The truth value of an array with more than one element is ambiguous. Use a.any() or a.all())
----------------------------------------------------------------------
Traceback (most recent call last):
  File "/usr/lib64/python2.7/site-packages/nose/loader.py", line 231, in generate
    for test in g():
  File "/home/xarth/codes/yt-3.0/yt/visualization/tests/test_offaxisprojection.py", line 86, in test_write_projection
    write_projection(image, fn, **wp_kwargs)
  File "/home/xarth/codes/yt-3.0/yt/visualization/image_writer.py", line 417, in write_projection
    cbar = fig.colorbar(cax)
  File "/usr/lib64/python2.7/site-packages/matplotlib/figure.py", line 1394, in colorbar
    cb = cbar.colorbar_factory(cax, mappable, **kw)
  File "/usr/lib64/python2.7/site-packages/matplotlib/colorbar.py", line 1173, in colorbar_factory
    cb = Colorbar(cax, mappable, **kwargs)
  File "/usr/lib64/python2.7/site-packages/matplotlib/colorbar.py", line 854, in __init__
    ColorbarBase.__init__(self, ax, **kw)
  File "/usr/lib64/python2.7/site-packages/matplotlib/colorbar.py", line 298, in __init__
    self.draw_all()
  File "/usr/lib64/python2.7/site-packages/matplotlib/colorbar.py", line 319, in draw_all
    self._process_values()
  File "/usr/lib64/python2.7/site-packages/matplotlib/colorbar.py", line 632, in _process_values
    b = self.norm.inverse(self._uniform_y(self.cmap.N+1))
  File "/usr/lib64/python2.7/site-packages/matplotlib/colors.py", line 982, in inverse
    return vmin * ma.power((vmax / vmin), val)
  File "/usr/lib64/python2.7/site-packages/numpy/ma/core.py", line 3648, in __mul__
    return multiply(self, other)
  File "/usr/lib64/python2.7/site-packages/numpy/ma/core.py", line 941, in __call__
    if m:
ValueError: The truth value of an array with more than one element is ambiguous. Use a.any() or a.all()
````





More information about the yt-dev mailing list