-
-
Notifications
You must be signed in to change notification settings - Fork 8.2k
Closed as not planned
Labels
New featurestatus: closed as inactiveIssues closed by the "Stale" Github Action. Please comment on any you think should still be open.Issues closed by the "Stale" Github Action. Please comment on any you think should still be open.status: inactiveMarked by the “Stale” Github ActionMarked by the “Stale” Github Actiontopic: contour
Description
Problem
Follow up on #21309.
The problem is contour on discontinuous functions. Mpl makes the (sane) assumption that, if a quad's corners have the values 0.0 and 0.78, the level contour of 0.51 (for example) has to pass somewhere through the quad, and draws it. This is incorrect where the function is actually discontinuous, but of course mpl has no way of knowing that.
See this stackoverflow post or here.
Proposed solution
A simple solution for this would be to allow for a user-supplied float parameter, max_jump or discontinuity_threshold or something like that, defaulting to np.inf. If within a quad the function values differ by more than this threshold, a discontinuity is assumed and the level contour is assumed not to pass through the quad.
Additional context and prior art
No response
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
New featurestatus: closed as inactiveIssues closed by the "Stale" Github Action. Please comment on any you think should still be open.Issues closed by the "Stale" Github Action. Please comment on any you think should still be open.status: inactiveMarked by the “Stale” Github ActionMarked by the “Stale” Github Actiontopic: contour