-
Notifications
You must be signed in to change notification settings - Fork 41
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
scatter_map NameError: name 'ccrs' is not defined #414
Comments
Hi @cywhale I can't reproduce the error though The output of |
Here is the completed argopy.show_versions()
|
Hi @cywhale I could not managed to exactly reproduce your environment, in particular I had to work with: cartopy 0.24.0 But using the environment below (based on yours) the code snippets works ok and I can't reproduce the error. Env. for argopy-issue414name: argopy-issue414
channels:
- conda-forge
dependencies:
- python = 3.12.5
# CORE:
- aiohttp ==3.10.5
- decorator ==5.1.1
- erddapy ==2.2.0
- fsspec ==2023.10.0
- netCDF4 ==1.7.2 #==1.7.1.post2
- packaging ==24.1
- requests ==2.32.3
- scipy ==1.14.1
- toolz ==0.12.1
- xarray ==2024.2.0
# EXT.UTIL:
- zarr==2.18.3
# EXT.PERF:
- dask==2024.10.0
- distributed==2024.10.0
- pyarrow==18.0.0
# EXT.PLOT:
- IPython==8.29.0
- cartopy==0.24.0 #==0.24.1
- ipykernel==6.29.5
- matplotlib==3.8.4
- pyproj==3.6.1
# DEV:
- cftime==1.6.4
- numpy==1.26.4
- pandas==2.2.2
- pip==24.3.1
- setuptools==75.6.0 #==75.4.0 |
It works after reinstalling my env. I did not expect that and should try this. Thanks. Sorry that waste your time and appreciate your help. I close the issue then. |
Reproducible code using official example:
Got NameError:
---> 11 scatter_map(df)
File ~/.pyenv/versions/py312numpy1/lib/python3.12/site-packages/argopy/plot/plot.py:525, in scatter_map(data, x, y, hue, #skip....
--> 525 subplot_kw = {"projection": ccrs.PlateCarree()}
#skip....
NameError: name 'ccrs' is not defined
scatter_map works before, so it may due to missing import for cartopy.crs (ccrs)?
Versions
python -c "import cartopy; print(cartopy.version)"
0.24.1
Output of `argopy.show_versions()`
SYSTEM ------ commit: None python: 3.12.5 (main, Sep 2 2024, 14:21:15) [GCC 13.2.0] python-bits: 64 OS: Linux OS-release: 6.8.0-49-generic machine: x86_64 processor: x86_64 byteorder: little LC_ALL: None LANG: zh_TW.UTF-8 LOCALE: zh_TW.UTF-8 libhdf5: 1.14.2 libnetcdf: 4.9.3-developmentINSTALLED VERSIONS: CORE
aiohttp : 3.10.5
argopy : 1.0.0
decorator : 5.1.1
erddapy : 2.2.0
fsspec : 2023.10.0
netCDF4 : 1.7.1.post2
...
INSTALLED VERSIONS: PIP
The text was updated successfully, but these errors were encountered: