Questions tagged [geopandas]

GeoPandas is an open source project to make working with geospatial data in python easier. GeoPandas extends the datatypes used by pandas to allow spatial operations on geometric types.

GeoPandas is an open source project to make working with geospatial data in python easier. GeoPandas extends the datatypes used by pandas to allow spatial operations on geometric types.

Geometric operations are performed by shapely. Geopandas further depends on fiona for file access and descartes and matplotlib for plotting.

If you're having trouble running or installing geopandas, it is recommended that you use conda to install geopandas into a new conda environment. When installing the GIS stack, it's recommended that you pull all of the dependencies from a single channel (e.g., only from the default channel or only from conda-forge):

> conda create --name=gis python=3.7 geopandas --channel=conda-forge

Resources:

2652 questions
0
votes
0 answers

Where can i download the the geopandas .whl file?

I am trying to install geopandas library without having to use pip install geopandas (admin constraints). My work around is to download the binaries and install this way. I can't find the geopandas windows binary, but I've been able to locate the…
John_gis
  • 117
  • 8
0
votes
0 answers

How to plot two GeoDataFrames with one legend in Python

I have the following code: import geopandas as gpd import matplotlib.pyplot as plt states_gdf = gpd.read_file('https://www2.census.gov/geo/tiger/GENZ2018/shp/cb_2018_us_state_5m.zip') CO_gdf = states_gdf[states_gdf['STUSPS'] == 'CO'] fig, ax =…
hm8
  • 1,381
  • 3
  • 21
  • 41
0
votes
1 answer

How to overlay hatches on shapefile with condition?

I've been trying to plot hatches (like this pattern, "//") on polygons of a shapefile, based on a condition. The condition is that whichever polygon values ("Sig") are greater than equal to 0.05, there should be a hatch pattern for them.…
Kee C
  • 5
  • 4
0
votes
0 answers

how to plot geo data with nodes and edges in networkx

I am trying to plot a warehouse location data using networkx. My sample dataset is as…
skiddy
  • 13
  • 3
0
votes
1 answer

unable to assign free hole to a shell error when flattening polygons

I have a list of polygons and I want to group them by the road_name property and flatten the polygons. I tried the following: {"type": "FeatureCollection", "features": [{"type": "Feature", "properties": {"compositeid":…
z star
  • 684
  • 6
  • 19
0
votes
1 answer

I have an error using OSMNX: OS error when using ox.graph_from_place

I recently reinstalled OSMNX using pip and now I get a strange OS error I honestly have never seen before and google did not help me as well... Here is a code excerpt with the error. I tried to restart the environment and also tried another VE to…
Skerre
  • 5
  • 2
0
votes
1 answer

How to create square shaped legend markers while using geopandas to plot a choropleth map?

I am trying create a legend which will have square shaped markers instead of round markers. I tried to use ".set_marker('s')" and it is adding multiple markers. Here is my code: fig, ax = plt.subplots(figsize=(18,…
0
votes
1 answer

Generating Multipolygon WKT from a Shapefile

I have a Shapefile with multiple polygons. When using the following method to generate a WKT the resultant output is only the first polygon of the Shapefile. The method works fine for single polygon Shapefiles but not for a Shapefile with multiple…
Larry
  • 45
  • 1
  • 8
0
votes
0 answers

Border Plot Not Displaying

I am plotting a gpd map with an overlay of scatterplot and circle patches. However, when I run the code, the output only displays the scatterplot and circle patches without the border maps. There is nothing wrong with the map as I tried running it…
0
votes
0 answers

Problem with voronoi library (scipy Voronoi, geovoronoi and libpysal Voronoi)

I'm having problems with several libraries and I can't think of a way to fix the problem. When I perform Voronoi processing. Some polygons are generated "inwards" causing numerous polygon overlaps. Here is the code snippet that generated the…
Ramon
  • 1
  • 1
0
votes
0 answers

How do I filter data using radio buttons on a Folium Map?

I was wondering how to add radio buttons to only select specific data to appear on a Folium Graph (basically be able to filter by the 'key' column in the data frame). Here's what I currently have: !pip install geopandas import numpy as np import…
0
votes
0 answers

Topological Error due to Geometry Invalidity when doing 'GEOSIntersection_r'

The error "TopologicalError: The operation 'GEOSIntersection_r' could not be performed. Likely cause is invalidity of the geometry " keeps popping up whenever I try to run my code with…
0
votes
1 answer

Not Able to Install Geopandas library using docker

I want to build a Docker container with airflow. The app requires geospatial packages like Geopandas. When trying to build the Docker Image it fails when trying to install Fiona, it says " FileNotFoundError: [Errno 2] No such file or directory:…
0
votes
0 answers

Downloading weekly Sentinel 2 data using SentinelApi

I'm trying to download weekly Sentinel 2 data for one year. So, one Sentinel dataset within each week of the year. I can create a list of datasets using the code: from sentinelsat import SentinelAPI api = SentinelAPI(user, password,…
Ross S
  • 1
0
votes
0 answers

speed up finding intersection between pandas dataframe/geodataframe and polygon

I need to intercept a 25 millions UTM points dataframe with a list of polygons. Point in Poligon problem. My code is taking a lot of time (2 hours). Can anyone please suggest any other way of accelerating this process? Thank you. Original data is in…
MaCoi
  • 1
  • 1