Closed
Description
The following code leads to a fatal Floating Point Exception 8 error with Matplotlib 2.0:
In [1]: import numpy as np
In [2]: im = plt.imshow(np.random.random((128,128)))
In [3]: im.set_data([[]])
In [4]: /Users/tom/miniconda3/envs/dev/lib/python3.6/site-packages/matplotlib/image.py:327: RuntimeWarning: divide by zero encountered in double_scalars
in_bbox.width / A.shape[1],
Floating point exception: 8
which then causes the Python session to end. This is a regression in 2.0, as it worked in 1.5.