You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I am trying out the example as listed on the hompage
However, I am getting urllib.error.HTTPError: HTTP Error 403: Forbidden in line fig = AnimationTrack(df_points=ibiza_trk, dpi=300, bg_map=True, map_transparency=0.5)
Does anyone know how to resolve this?
The text was updated successfully, but these errors were encountered:
UPDATE: well, I notice that this has already been solved in master branch (#8 ) and I have no idea why it is not published on PyPI.
This is solved in smopy==0.0.7.
As the dependency for trackanimation is specified with smopy==0.0.6, you can manually fix the fetch_tile function used in smopy as follows.
deffetch_tile(x, y, z):
"""Fetch tile (x, y) at zoom level z from OpenStreetMap's servers. Return a PIL image. """fromsix.moves.urllib.requestimportRequesturl=get_url(x, y, z)
req=Request(url, data=None, headers={'User-Agent': 'smopy'})
png=BytesIO(urlopen(req).read())
img=Image.open(png)
img.load()
returnimg
I am trying out the example as listed on the hompage
However, I am getting
urllib.error.HTTPError: HTTP Error 403: Forbidden
in linefig = AnimationTrack(df_points=ibiza_trk, dpi=300, bg_map=True, map_transparency=0.5)
Does anyone know how to resolve this?
The text was updated successfully, but these errors were encountered: