Skip to content

Matplotlib 2.0.0 crashes on plotting contour of array with two dimensions of size 1 in Python 3.4 #8197

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Closed
jeroenmuller opened this issue Mar 5, 2017 · 1 comment
Assignees
Milestone

Comments

@jeroenmuller
Copy link

jeroenmuller commented Mar 5, 2017

Bug report

Bug summary

Python crashes on plotting contour of array with two dimensions of size 1.

Code for reproduction

import numpy as np
import matplotlib.pyplot as plt

im = np.array([[0]])
plt.contour(im)

Actual outcome

Python interpreter craches, with this message:
Floating point exception (core dumped) 

Expected outcome
This is the output I get on Python 2.6.6:
ValueError: zero-size array to reduction operation minimum which has no identity

Matplotlib version
Fedora 23, with Matplotlib 2.0.0 and numpy 1.12.0 installed using pip.

@tacaswell tacaswell modified the milestones: 2.0.1 (next bug fix release), 2.1 (next point release) Mar 10, 2017
NelleV added a commit that referenced this issue Mar 11, 2017
@ianthomas23
Copy link
Member

Fixed by PR #8227. Thanks for the bug report @jeroenmuller.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants