Questions tagged [scipy.spatial]

Spatial algorithms and data structures from the SciPy library

Filter by
Sorted by
Tagged with
1 vote
1 answer
615 views

Extracting convex_hull polygon from CSVwith scipy.spatial ConvexHull and output it to a shapefile

I'm looking for a Python solution for extract a convex_hull polygon from quite big CSV (nearly 150 millions points) and return back the polygon to a shapefile. After reading the CSV with pandas (pd....
user avatar
1 vote
1 answer
322 views

Getting scipy.cKDTree to return everything with a given meter radius

I want to find everything within a 0.1 meter radius. I'm confused on exactly how query_ball_point is getting distance. I'm using decimal degree coordinates when creating the cKDTree, ie. [(-73....
user avatar
1 vote
0 answers
1k views

calculate difference between two interpolated grids using python [closed]

I'm trying to calculate difference between two interpolated grids. The grids are of different shapes, so cannot use np.subtract to calculate the difference. Any help on how to calculate the difference?...
user avatar
  • 11
4 votes
1 answer
3k views

Classifying LiDAR ground points using laspy?

I have a classified LiDAR point cloud (.las) with misclassifications. The walls of steep surfaces that should be ground (class 2) have been misclassified as vegetation (classes 3, 4, 5). I am ...
user avatar
  • 371
1 vote
1 answer
636 views

Fiona import error when updated to version 1.7

I would like to update scipy to version 0.19 as it has the nice calculate area of a convex hull method. When updating with conda, this updates fiona to version 1.7. Now I get an error trying to import ...
user avatar
  • 353
2 votes
1 answer
5k views

How do I import multiple tif images and save it as one tiff file with skimage or gdal in python?

I am new to Python and I am trying to import multiple tif images so that I can do image processing with skimage. I want to do image processing on a Landsat image to define linear features for a ...
user avatar
  • 21
1 vote
1 answer
2k views

Interpolating point data using scipy/python is not covering rectangular extent

I am trying to write a python script with help of GDAL to a red point shapefile and considering a field value as z vales where I need interpolation to get raster with interpolated values. I am using ...
user avatar
1 vote
1 answer
2k views

Invalid x dimension error in spatial point interpolation?

I have a point shapefile with altitude values. I have used gdal/ogr to open shapefile and read points(x,y) and altitude(z) values. It showing error when I am trying to interpolate with scipy griddata ...
user avatar
1 vote
1 answer
683 views

Python new packages installation with ArcGIS interpreter?

I would like to introduce some functions derived from scipyin my code. Since I also need arcpy, I use the Interpreter installed inside ArcGIS, whose directory is: (C:\Python27\ArcGIS10.3\python.exe). ...
user avatar
1 vote
1 answer
560 views

Calculating distances with SciPy and subsequently join identifiers

I have lots of start points and a handful of destination points. Using 'Point Distance' from the toolbox takes ages to calculate and write the results. Hence, I was looking for alternatives and went ...
user avatar
10 votes
1 answer
3k views

Birch algorithm does not cluster as expected

I'm using Birch algorithm from scipy-learn Python package for clustering a set of points in one small city in sets of 10. I use following code: no = len(list_of_points)/10 brc = Birch(...
user avatar
  • 197
3 votes
0 answers
1k views

How to create a shapefile having Voronoi diagrams from the shapefile of an existing region?

I have a shapefile of a region and I want to generate random sub regions of that shapefile using Voronoi class of scipy.spatial package of Python. But I am a newbie to GIS. I found out about Voronoi ...
user avatar
2 votes
1 answer
707 views

Where can I find the version of scipy python package used in QGIS Lyon 2.12?

I am using QGIS Pisa 2.10. I want to use the Voronio class of scipy.spatial in QGIS python console. QGIS Pisa has 0.11 version of scipy package. This package doesn't have Voronoi class. I even tried ...
user avatar
3 votes
0 answers
1k views

Performing Grouping Analysis in QGIS? [duplicate]

Is there a QGIS tool that does the function of http://pro.arcgis.com/en/pro-app/tool-reference/spatial-statistics/grouping-analysis.htm MY NEED - I have about 15,000 points. I need them clustered in ...
user avatar
  • 7,552
4 votes
1 answer
812 views

Polygon inner rings/holes issue

I am working on a script to smooth polygons. Essentially it, separates the inner and outer rings/polygons and send the coordinates to a smoothing def/function. The "smoothed" coordinates are then ...
user avatar
  • 1,491
1 vote
1 answer
391 views

How to calculate the raster statistics with polygon layer using numpy and scipy in python?

I have used zonal statistics from processing to calculate the raster statastics with polygon layer. processing.runalg('qgis:zonalstatistics', rlayersource, 1, vlayer, None, True, Path) But this is ...
user avatar
  • 949
6 votes
1 answer
3k views

Find shortest path between points avoiding shapefile?

I am an intermediate python developer with very limited GIS experience. I have a list of latitude/longitudes of a ship at sea. I need to join them into a polyline using the shortest distance between ...
user avatar
2 votes
1 answer
559 views

ImportError: cannot import scipy from windows powershell

I am having an importError message while trying to import scipy from powershell. But I am able to do this when I try to do this in the python shell in ArcGIS. The error I get is this: Traceback (...
user avatar
  • 51
2 votes
0 answers
403 views

Converting points using FeatureClassToNumPyArray to interpolate cross-section with scipy "interpolate" [closed]

I'm trying to plot elevation cross section and extract elevations along a cross section using scipy's "interpolate" function. I'm converting a point feature class of profile elevation points to 2 ...
user avatar
2 votes
0 answers
4k views

Polygon of Voronoi cell using scipy.spatial?

I have points (e.g., lat, lon pairs of cell tower locations) and I need to get the polygon of the Voronoi cells they form. from scipy.spatial import Voronoi tower = [[ 24.686 , 46.7081], [ ...
user avatar
  • 441
6 votes
2 answers
4k views

Installing scipy.spatial with ArcPy gives DLL load failed error on import?

I am running python 2.7.6 from an ArcGIS installation. I have tried to install scipy from the Python Exchange Packages here, using the scipy-0.14.0.win32-py2.7.exe executable. I get no error importing ...
user avatar
  • 635