[GRASS-SVN] r73475 - grass-addons/grass7/vector/v.gsflow.grid
svn_grass at osgeo.org
svn_grass at osgeo.org
Mon Oct 1 15:18:14 PDT 2018
Author: awickert
Date: 2018-10-01 15:18:14 -0700 (Mon, 01 Oct 2018)
New Revision: 73475
Modified:
grass-addons/grass7/vector/v.gsflow.grid/v.gsflow.grid.py
Log:
v.gsflow.grid: typecast whole array
Modified: grass-addons/grass7/vector/v.gsflow.grid/v.gsflow.grid.py
===================================================================
--- grass-addons/grass7/vector/v.gsflow.grid/v.gsflow.grid.py 2018-10-01 21:57:44 UTC (rev 73474)
+++ grass-addons/grass7/vector/v.gsflow.grid/v.gsflow.grid.py 2018-10-01 22:18:14 UTC (rev 73475)
@@ -259,12 +259,12 @@
# Find out if this is diagonal: finite difference works only N-S, W-E
colNames = np.array(gscript.vector_db_select(pp, layer=1)['columns'])
colValues = np.array(gscript.vector_db_select(pp, layer=1)['values'].values())
- pp_row = int(colValues[:,colNames == 'row'].astype(int).squeeze())
- pp_col = int(colValues[:,colNames == 'col'].astype(int).squeeze())
+ pp_row = colValues[:,colNames == 'row'].astype(int).squeeze()
+ pp_col = colValues[:,colNames == 'col'].astype(int).squeeze()
colNames = np.array(gscript.vector_db_select(bc_cell, layer=1)['columns'])
colValues = np.array(gscript.vector_db_select(bc_cell, layer=1)['values'].values())
- bc_row = int(colValues[:,colNames == 'row'].astype(int).squeeze())
- bc_col = int(colValues[:,colNames == 'col'].astype(int).squeeze())
+ bc_row = colValues[:,colNames == 'row'].astype(int).squeeze()
+ bc_col = colValues[:,colNames == 'col'].astype(int).squeeze()
# Also get x and y while we are at it: may be needed later
bc_x = float(colValues[:,colNames == 'x'].astype(float).squeeze())
bc_y = float(colValues[:,colNames == 'y'].astype(float).squeeze())
More information about the grass-commit
mailing list