8000 FIX: bypass inverse in collection · matplotlib/matplotlib@5f878c1 · GitHub
[go: up one dir, main page]

Skip to content

Commit 5f878c1

Browse files
committed
FIX: bypass inverse in collection
1 parent ee2d046 commit 5f878c1

File tree

1 file changed

+4
-3
lines changed

1 file changed

+4
-3
lines changed

lib/matplotlib/collections.py

Lines changed: 4 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -234,9 +234,10 @@ def get_datalim(self, transData):
234234
# (i.e. like scatter). We can't uniquely set limits based on
235235
# those shapes, so we just set the limits based on their
236236
# location.
237-
# Finish the transform:
238-
offsets = (transOffset.get_affine() +
239-
transData.inverted()).transform(offsets)
237+
if not (transOffset.is_affine or (transOffset == transData)):
238+
# Finish the transform started above
239+
offsets = (transOffset.get_affine() +
240+
transData.inverted()).transform(offsets)
240241
offsets = np.ma.masked_invalid(offsets)
241242
if not offsets.mask.all():
242243
points = np.row_stack((offsets.min(axis=0),

0 commit comments

Comments
 (0)
0