In [1]:
import cartopy
import cartopy.crs as ccrs
import matplotlib.pyplot as plt
%matplotlib inline
## NASA earth-at-night simple
## Live 8.5 * darkblue-b
##
In [3]:
## note: requires a live internet connection
## and availability in your area of NASA wmts service
url = 'http://map1c.vis.earthdata.nasa.gov/wmts-geo/wmts.cgi'
layer = 'VIIRS_CityLights_2012'
ax = plt.axes(projection=ccrs.PlateCarree())
ax.add_wmts(url, layer)
## Set the extent (x0, x1, y0, y1) of the map in the given
## coordinate system.
ax.set_extent((-123.2, -120, 36.4, 41))
##--
plt.title('San Francisco Bay Area plus, April/October 2012')
plt.show()
In [ ]: