Search code examples
cartopy

Cartopy Cimgt not retrieving tiles within PySpark notebook


Cartopy version 0.18.0. This works in a juptyer notebook:

import cartopy.io.img_tiles as cimgt
import matplotlib.pyplot as plt
extent =[-94, -84, 43, 37]
request=cimgt.GoogleTiles(desired_tile_form='RGB', style='street')
fig = plt.figure(figsize=(16, 12))
ax = plt.axes(projection=ccrs.PlateCarree())
ax.set_extent(extent)
ax.add_image(request, 6)
plt.show()

However, when I attempt to do the exact same thing in a pyspark notebook with Cartopy 0.18.0 added as a package library, I get this error:

ValueError: A non-empty list of tiles should be provided to merge.

Thoughts?


Solution

  • Turns out my pyspark environment was not set up correctly. Issue is resolved.