Skip to content

Commit

Permalink
dataarray_to_matrix: Make sure that the returned region/inc is a list…
Browse files Browse the repository at this point in the history
… of scalar values
  • Loading branch information
seisman committed Jun 17, 2024
1 parent 92a69e0 commit 62194d9
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions pygmt/clib/conversion.py
Original file line number Diff line number Diff line change
Expand Up @@ -124,6 +124,8 @@ def dataarray_to_matrix(grid):
grid = grid.sortby(variables=list(grid.dims), ascending=True)

matrix = as_c_contiguous(grid[::-1].to_numpy())
region = [float(i) for i in region]
inc = [float(i) for i in inc]
return matrix, region, inc


Expand Down

0 comments on commit 62194d9

Please sign in to comment.