Questions tagged [geometry]

(1) abstract geometry; (2) storing geographic data in projected coordinates; (3) a generic ESRI term for vector features; a class for "geometry" objects.

Filter by
Sorted by
Tagged with
0
votes
1answer
12 views

Correct area calculations: When to use planimetric, when ellipsoidal?

Sometimes I am not sure whether to use planimetric or ellipsoidal model to calculate areas of polygons. If there is a "reference" data (e.g. a given shape_area column) I compare results and take the ...
0
votes
2answers
26 views

Invalid geometry after gdal.polygonize

After converting a raster file to a vector file using gdal.polygonize, I cannot carry out further commands (e.g. Clip) because the vector is produced with invalid geometries (as determined by the QGIS ...
0
votes
0answers
15 views

use the result of thresholding as a new geometry for further analysis in google earth engine [on hold]

I have calculated the maximum NDVI for 10 days interval from Modis images. I am going to first classify the NDVI image by thresholding, then, analyze the variations of mean value in each class over 20 ...
1
vote
0answers
11 views

Find closest points using S2, given point and radius

I'm trying to use the go s2 package to find closest points, given a point and a radius (meters). I'm modeling my alg. after dynamodb-geo.js as I'm storing my points in DyanmoDB. I can't seem to get ...
4
votes
1answer
66 views

Extracting data within geometry (shape)

I have a NetCDF dataset which I normally call using the xarray function. I have recently been doing some transect analysis on the dataset, which looks something like this (the area between the ...
1
vote
0answers
21 views

Solid is invalid : PolyhedralSurface (shell) 0 is invalid: self intersects

I am trying to calculate the volume of an object with geometry type --PolyhedralSurface. ST_MakeSolid(geom) is valid, while ST_Volume(ST_MakeSolid(geom)) is invalid for the following reasons: ...
1
vote
1answer
18 views

Splitting or decomposing LineString into original single lines or segments using shapely?

I am trying to split a LineString into single segments: from shaply import LineString,MultiPoint from shapely.ops import split xp = [-2,1,2,2.5,4,1,-1,2,4,5,6] yp = [-2,1,1,0,1,2,2,3,4,4,4] ...
1
vote
1answer
41 views

Calculating the length of a single edge in QGIS

I need the correct length of a edge between to points(yellow line in the picture below) in the unit [m] for validation of an equation. I just found the possbility to add geometry (length) to the ...
0
votes
1answer
41 views

Understanding why LatLng returned from L.GeometryUtil.closest() are not from array being checked over?

I am using this function below from this library Leaflet.GeometryUtil to help find the closest distance between two points. L.GeometryUtil,closest(map, array, latlng) It is returning this ...
2
votes
1answer
42 views

TypeError: Input geometry column must contain valid geometry objects

I'm working in a urban biodiversity project and I have a csv file for a birds inventory with a column index called 'geom' composed by multypolygons as this: name geom ...
2
votes
0answers
35 views

Generate arc from projection coordinates

I have a mind to generate arc from given parameters: start point coordinates arcDistance arcBearing arcOrigin coordinates. My concept is, calculate the end point of arc (function geo.sphere....
1
vote
0answers
34 views

Spatial operations between WMS geometry and client data

I am using geoserver WMS service to visualize some geometry on the map (via Leaflet) which is working fine. Now I have a requirement to perform the spatial operation (say intersects) between two ...
1
vote
1answer
23 views

Dictionary.toArray: Unable to convert dictionary to array, key 'NDVI' has a null value

I am trying to reduce a region by clipping an image from copernicus to get NDVI and then calculate a Kc value. However, Once I use a polygon I imported with the "Draw a Shape" tool, the calculations ...
1
vote
0answers
34 views

What could cause a Spatial Join (Completely Within) to return false positives?

Im using ArcMap 10.3 I have a large feature class of Archaeological surveys that I need to Spatial Join to a target feature class of buffered work locations to find locations that are Completely ...
2
votes
2answers
47 views

Adding shape of defined dimensions using PyQGIS in QGIS 3.4

I am attempting to add a feature with defined geometry as a layer. Having added the feature I checked on the dimensions of its sides and they measure differently. This is the code that I am using. x ...
3
votes
0answers
47 views

Lines length plugin - QgsVectorLayer error

Several similar questions have already been made, but none of the is helping me. I have a layer of polygons and I want to known the length of each line of each polygon. And based on the length I ...
2
votes
0answers
49 views

Can I correct position data from a device suffering from the 4/6/19 roll-over problem?

I work for a company that sells apparatus containing GPS receivers. Over the years a lot of this gear has been sold and deployed. A number of machines in the field contain GPS receivers that feature ...
1
vote
0answers
59 views

Why coordinates are saved like “0101000020110F00003CDBA337DCC351C06D37C1374D374840” in db? [closed]

On my DB, the data looks like this: In the DAO I am executing a query: public Object login(UserEntity user) { StringBuffer sb = new StringBuffer(); sb.append("SELECT user FROM ...
0
votes
1answer
61 views

Converting lat long strings to xy linestrings [closed]

In PostGIS, I have a dataset with road segments including a column with coordinates for the various segments. The coordinates are in a lat-long format and the data type of the column is character ...
1
vote
1answer
30 views

Store geometry change on modify interaction OpenLayers

I am using OpenLayers modify interaction with events modifystart and modifyend. I am trying to remember state of feature before it is modified. I do it this way: var modificirane_cestice=new Object()...
1
vote
2answers
49 views

AttributeError: 'QgsVectorLayer' object has no attribute 'geometry'. How to fix?

Ok... So I am trying to add a column (Length) in attribut table that shows the length of each line of a line feature. A part of my code is this: geom = layer.geometry() len = ...
0
votes
1answer
20 views

gdal FlattenTo2D makes geom null

I have a df that has geoms as ogr geom in 3D. I was trying to convert to 2D but it empties out the geom. ipdb> df['default_geom'][0] <osgeo.ogr.Geometry; proxy of <Swig Object of ...
0
votes
1answer
41 views

Pixel alignment for trend analysis in Earth Engine

I am trying to calculate NDVI trends over time using Landsat scenes and the earth engine code below: var point = /* color: #d63000 */ee.Geometry.Point([-133.49, 69.18]); var l5 = ee....
0
votes
1answer
22 views

Exporting feature class to geometry objects and preserving attributes - ArcGIS, ArcPy

I'm using ArcPy and would like to copy features in a feature class to geometry objects and then perform a buffer on the geometry objects and copy them back to a feature class. I am doing this in ...
0
votes
0answers
20 views

Reverse direction of “Add Geometry Attributes” tool? [duplicate]

The ArcGIS Desktop tools Add XY Coordinates and Add Geometry Attributes read from [Shape] column and write the shape XY properties to new X and Y columns. I need to go the other direction, from X and ...
0
votes
1answer
40 views

Using Cumulative Geometry Calculation to Add Field in ArcPy

I am using Desktop 10.6, Basic license, Spatial Analyst, Python 2.6, 2019 AD. I have 4 overlapping features in a polygon feature class. I'd like to sort the features by the depth field, calculate the ...
2
votes
1answer
72 views

Drawing geometry with fixed scaling?

I drew the wind barbs on the map based on the coordinates data with the step of 2 degrees. But I am not satisfied with the fact that after the map reprojecting the size of the wind barbs changes. Is ...
3
votes
1answer
64 views

Seeking code behind Fix Geometries tool in QGIS?

I used the very nice "Fix Geometries" tool in the Processing Toolbox of QGIS 3.6 to repair a vector layer that was giving me trouble. The tool in QGIS worked just fine, but I was hoping to find out ...
0
votes
0answers
27 views

PyGRASS: storing attribute table values to variables

Goal: to store the sum of all values (lengths) of a vector map in a variable inside a Python script. This variable will later be shown to the user in a GUI. The computation time has to be as low as ...
1
vote
1answer
28 views

Split 3D polyline at point using QGIS

I want to split a QgsPolyline geometry into two separate lines at a given QgsPoint (by projection onto the line), adding the point to the line as end point of the incoming line and start point of the ...
1
vote
1answer
33 views

R or Python geometry checker that outputs results as table

Is there a R or Python solution that 1) checks the geometry validity of vectors and 2) outputs the results in form of a table (see table below). QGIS for example has a nice plugin that carries out ...
1
vote
1answer
48 views

PostGIS: Running multiple intersections within a single SQL query?

PostgreSQL 11 + PostGIS, on Windows 10. I'm working with a PostGIS-enabled database. I want to UPDATE a large polygon table (100,000+ rows) WHERE the geometry of that host table intersects the ...
0
votes
1answer
14 views

Google Earth hide geometry except for a small area

In a Google Earth tour, I only want to show a specific small area, that is, I want to hide (not render) all terrain outside of this area. If such hiding is impossible, can I use a black "image overlay"...
1
vote
1answer
44 views

Area Value not getting reflected in attribute Table using PyQGIS?

I have a WardBoundary.shp file in my project. I need to find the area of each polygon ( representing different wards).With the help of this comment on Adding Area column in Polygon layer using PyQGIS?,...
1
vote
1answer
113 views

Type geometry does not exist PostGIS [duplicate]

I am trying to add a geometry column to an existing table in PostgreSQL inside a plpgsql function using EXECUTE format('ALTER table %I add column geom geometry(Point, 102003)', target_table); Its ...
-1
votes
1answer
84 views

Adding Area column in Polygon layer using PyQGIS? [closed]

I have a WardBoundary.shp file with Polygon Features in it. I have to calculate the area of each Polygon and write into attribute Table. I can do manually by using '$area` but I need to automate ...
0
votes
1answer
138 views

How to create a function for finding the largest of 2 polygons by area in PostGIS?

I tried my level in creating the function but it shows error while running. I have enclosed the code here : create function largest_poly (geom1, geom2) returns geometry as $largest_poly$ begin from ...
3
votes
1answer
39 views

Exporting render of polygon after applying smooth geometry command using QGIS?

I have recently discovered the smooth($geometry,x) command in QGIS which is very convenient for me. However, when exporting polygons, the "smoothness" obviously goes away as the vertices are untouched ...
0
votes
1answer
46 views

Using geometries to extract line segments in ArcPy with ArcGIS Pro?

I'm trying to use geometries to cut down a feature class of polylines to just the first 400m of each polyline. I modified an answer from Split a shapefile of lines into even spaced segments and am ...
0
votes
0answers
16 views

MySQL update geometry field

I have MySQL database with table in X varchar(50) latin1_swedish_ci No None Change Change Drop Drop More More 11 Y varchar(50) latin1_swedish_ci No None ...
1
vote
1answer
35 views

Storing date in m-dimension of PostGIS geometries

Do you know if it is possible to assign a date (whatever the format) as the 4th dimension to a geometry in PostGIS? If so, does it recognize it as a date?
2
votes
1answer
105 views

Client-Side Polygon split

I wanted to know if there is a way to split a polygon using JavaScript. So I have a web map which uses Leaflet API, and the user needs to cut polygons which are shown in the map using a straight line. ...
0
votes
1answer
42 views

ST_SnapToGrid doesn't work properly, e.g. 41.94186153740355 -> 41.941861499999995

I'm using ST_SnapToGrid: ST_SnapToGrid(somePoint, 0.0000001) and I get strange result on many points, such as: - POINT (21.619820510769063 41.94186153740355) -> POINT (21.6198205 41....
1
vote
1answer
38 views

Harmonize geometry of different shapefiles (QGIS) [closed]

I have got to harmonize the geometry of a big amount of shapefiles in QGIS The files are actually very big. So it would be a lot of work to do it manually. Do you have any suggestions for me?
2
votes
1answer
93 views

Converting MULTIPOLYGON field stored as text to geometry data type in PostGIS and plotting in QGIS

I have this column Multipolygon which has data stored in this format which is in TEXT: MULTIPOLYGON(-115.528984981578 51.2006109579736, -115.526434407604 51.1974145241941, -115.546464451 51....
2
votes
2answers
157 views

What is the unit of the area when geometry attributes are calculated in QGIS?

My CRS is WGS 84. I intersected two files containing polygons. Each file has an attribute table stating the area of each of the polygons (in m2). After intersecting them I navigate to: Vector >> ...
0
votes
1answer
41 views

Transform geometry of polygons [closed]

I am new to PostGIS. I'm making a spatial join, but it does not work. From what I saw it is something of the geometry of polygons. My polygons are saved with the "Geom" field like this (Geom geometry (...
0
votes
1answer
16 views

Counting (Multi)Polygons Within (Multi)Polygons on same Table

So I have a table with approximately 10k rows, with each row having its corresponding geometry entry. What I am attempting to do is count how many row geometries are contained/within the geometry of a ...
0
votes
0answers
23 views

Compare Specific Points of Line Features in two Feature Classes using FeatureClassToNumPyArray

I am looking to compare the first and last point between features in two different feature classes. The features share a common ID. My thought was to create two arrays via FeatureClassToNumPyArray. ...
1
vote
1answer
32 views

Defining geometry type in QgsDataSourceUri

There is a PostgreSQL database containing some layers that have few types of geometry (multipolygons and linestrings). I need to distinguish these geometries in two separate layers. My basic strings ...