Skip to content

Empty areas at the horizon when using add_image to NearsidePerspective #2135

@bratushka

Description

@bratushka

Description

When plotting NearsidePerspective in cartopy using add_image I get many empty areas (as shown on the image) close to the horizon line.

Map with empty areas

Code to reproduce

Here's the code to reproduce:

import matplotlib.pyplot as plt
import cartopy.crs as ccrs
import cartopy.io.img_tiles as cimgt


plt.figure(figsize=(7, 7), frameon=False)
projection = ccrs.NearsidePerspective(
    central_longitude=-86.055024,
    central_latitude=11.9320027,
    satellite_height=700000,
)
ax = plt.subplot(1, 1, 1, projection=projection)
ax.add_image(cimgt.GoogleTiles(), 7)
ax.set_global()
plt.show()
Full environment definition

Dockerfile where the environment is defined:

FROM jupyter/scipy-notebook:x86_64-python-3.10.9


RUN conda install -c conda-forge cartopy
RUN conda install -c conda-forge gdal

RUN pip3 install countryinfo
RUN pip3 install haversine
RUN pip3 install reverse-geocode
RUN pip3 install pymbtiles

CMD ["start-notebook.sh"]

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions