TypeError in Numpy v1.13
Issue #4
new
The latest release of numpy (v.1.13) fails to save binary images with scipy.misc.pilutil.imsave
and throws the following error:
Traceback (most recent call last):
File "setup.py", line 327, in <module>
my_manager.run()
File "~/Repositories/usda-ars/image_analysis/py_version/3d/pria/manager.py", line 1473, in run
self.do_next()
File "~/Repositories/usda-ars/image_analysis/py_version/3d/pria/manager.py", line 882, in do_next
self.params[ans]['func']()
File "~/Repositories/usda-ars/image_analysis/py_version/3d/pria/manager.py", line 1818, in start_image_process
self.execute()
File "~/Repositories/usda-ars/image_analysis/py_version/3d/pria/manager.py", line 981, in execute
imsave(im_out_path, out_array)
File "~/Envs/prida/lib/python3.6/site-packages/scipy/misc/pilutil.py", line 197, in imsave
im = toimage(arr, channel_axis=2)
File "~/Envs/prida/lib/python3.6/site-packages/scipy/misc/pilutil.py", line 299, in toimage
cmin=cmin, cmax=cmax)
File "~/Envs/prida/lib/python3.6/site-packages/scipy/misc/pilutil.py", line 94, in bytescale
cscale = cmax - cmin
TypeError: numpy boolean subtract, the `-` operator, is deprecated, use the bitwise_xor, the `^` operator, or the logical_xor function instead.
Current work-around is to use an earlier version of numpy (e.g., 1.12.1 or 1.11.3).