8000
Skip to content

geoplot.voronoi example in reference/documentation fails #299

@par00sh

Description

@par00sh

I am working the geoplot quick start and plot examples given in the reference.
Installed geoplot in fresh env.
geoplot version 0.5.1
numpy version 2.1.3 - installed automatically - I did not set the version

Code: start
import geoplot as gplt
import geoplot.crs as gcrs
import geopandas as gpd

boroughs = gpd.read_file(gplt.datasets.get_path('nyc_boroughs'))
injurious_collisions = gpd.read_file(gplt.datasets.get_path('nyc_injurious_collisions'))

ax = gplt.voronoi(injurious_collisions.head(1000))
gplt.polyplot(boroughs, ax=ax)
Code: end
Example fails with error: AttributeError: ptp was removed from the ndarray class in NumPy 2.0. Use np.ptp(arr, ...) instead.
Is a fix coming in near future? To which version of numpy should I downgrade to?

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions

      0