Skip to content

Commit 8681439

Browse files
committed
Backport fix for broken Proj.__call__ with single input array
1 parent 87bebc5 commit 8681439

File tree

2 files changed

+4
-1
lines changed

2 files changed

+4
-1
lines changed

CHANGELOG.md

Lines changed: 2 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -22,6 +22,8 @@ https://semver.org/spec/v2.0.0.html
2222
- Fix flipped coastlines with pseudocylindrical projections when `lon_0`
2323
is greater than 0 deg (solves issues [#443] and [#463], thanks to
2424
@YilongWang).
25+
- Fix broken `Proj.__call__` when the input arguments are provided as
26+
a combined single array.
2527
- Fix `antialiased` argument being ignored in `Basemap.drawcounties` and
2628
`Basemap.readshapefile` (solves issue [#501], thanks to @TheFizzWare).
2729
- Fix wrong reference to `ireland.py` example in FAQ, which should be

packages/basemap/src/mpl_toolkits/basemap/proj.py

Lines changed: 2 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -290,7 +290,8 @@ def __call__(self, *args, **kw):
290290
return x,y
291291
inverse = kw.get('inverse', False)
292292
if onearray:
293-
outxy = self._proj4(xy, inverse=inverse)
293+
outx, outy = self._proj4(*xy.T, inverse=inverse)
294+
outxy = np.asarray([outx, outy]).T
294295
else:
295296
outx,outy = self._proj4(x, y, inverse=inverse)
296297
if inverse:

0 commit comments

Comments
 (0)