Skip to content

Problem when plotting #108

@PeterKammLab

Description

@PeterKammLab

I had a problems with importing prettymaps, that's solved now. However there is a specific problem now (see image):

import prettymaps
plot = prettymaps.plot('Stad van de Zon, Heerhugowaard, Netherlands')
C:\Users\pkoljensic\Anaconda3\envs\prettymaps\Lib\site-packages\osmnx\geocoder.py:110: FutureWarning: The frame.append method is deprecated and will be removed from pandas in a future version. Use pandas.concat instead.
gdf = gdf.append(_geocode_query_to_gdf(q, wr, by_osmid))
C:\Users\pkoljensic\Anaconda3\envs\prettymaps\Lib\site-packages\prettymaps\draw.py:109: ShapelyDeprecationWarning: Iteration over multi-part geometries is deprecated and will be removed in Shapely 2.0. Use the geoms property to access the constituent parts of a multi-part geometry.
layers = dict(zip(k, v))

AttributeError Traceback (most recent call last)
Cell In[3], line 1
----> 1 plot = prettymaps.plot('Stad van de Zon, Heerhugowaard, Netherlands')

File ~\Anaconda3\envs\prettymaps\Lib\site-packages\prettymaps\draw.py:251, in plot(query, backup, postprocessing, radius, layers, drawing_kwargs, osm_credit, figsize, ax, title, vsketch, x, y, scale_x, scale_y, rotation)
244 ############
245 ### Plot ###
246 ############
247
248 # Matplot-specific stuff (only run if vsketch mode isn't activated)
249 if vsketch is None:
250 # Ajust axis
--> 251 ax.axis("off")
252 ax.axis("equal")
253 ax.autoscale()

AttributeError: 'NoneType' object has no attribute 'axis'

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