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
Ehn/cartopy fan plots #219
Conversation
…and if it needs cartopy
…lor is not working
@Shirling-VT updated the error message though it will point to the current main page which does not have the install guidelines. I did this so I don't have remember to update it come to release :p instead are the current ones: https://pydarn.readthedocs.io/en/ehn-cartopy_fan_plots/user/install/ |
MacOS 10.15.7 Installed cartopy through conda: conda install -c conda-forge cartopy. Other related dependencies (e.g., geos, proj, pyshp, and shapely) are installed automatically with cartopy in conda. When I ran the plot_fov test code using projs=pydarn.Projs.GEO_COASTALINE, the following error appears: I checked the pydarn projs.py and found only COASTALINE and POLAR are available. I then changed projs=pydarn.Projs.GEO_COASTALINE to projs=pydarn.Projs.COASTALINE, this error shows up: When I changed projs=pydarn.Projs.GEO_COASTALINE to projs=pydarn.Projs.POLAR, now I get a figure, which does not look right as well: Not sure if it's on my side that I didn't install cartopy correctly or needs more dependencies, or if there's something wrong with the test codes. @mts299 Would you mind double checking the test codes? |
Thanks @Shirling-VT I may have made minor change that affected everything :( |
@Shirling-VT try now, sorry I seem to keep pushing to the wrong cartopy branch |
@Shirling-VT nvm looks like there is some other bugs ... @carleyjmartin keeps breaking it |
@Shirling-VT Okay now everything should be working: |
Please ignore the layering of the grid line and fov_color this has been a known issue just need time to think about it more and will make another PR. |
MacOS 10.15.7 Here are my test codes: data = pydarn.Fan.plot_fov(stid=65, date=dt.datetime(2022, 1, 8, 14, 5), grid=True, data = pydarn.Fan.plot_fan(fitacf_data, grid=True, scan_index=5, fov_color='blue', Both plot_fov and plot_fan give me the same error: |
what is your fitacf data just so I can test it? |
Unless you picked some weird data again or not pulling the newest changes... I get no errors :( The only thing I can think of once again is 3.5.1 @carleyjmartin what are your specs on those two libraries since you use a Mac as well and report no issues with my code? |
macos: 10.15.5 |
@mts299 @carleyjmartin Thanks for checking this. I did pull all the newest changes. My cartopy version is 0.18.0. It's very likely that I need to upgrade my cartopy. I remember I saw some posts online mentioning the same issue when using an old version of cartopy. I'll see how I can upgrade it in conda and if I can make it work this time. |
Thank you @Shirling-VT for figuring it out :) Since its not an actual install in the setup.py where we would force it ... I can make some documentation on it and see if we cna make an exception to also check the version number before a user gets to using it :) I will get this done today! |
@Shirling-VT added in the documentation and an exception that is raised if the version is incorrect:
|
Scope
This PR focuses on using
cartopy
in pyDARN'splot_fan
plots andplot_fov
by passing inProjs.GEO_COASTALINE
andCoords.GEOGRAPHIC
. There is a lot missing nice features but this is the base PR.Things still to do that are not included in this PR:
issue: #206
Approval
Number of approvals: 3 approvals if possible
Test
matplotlib version: 3.5.1
Note testers: please indicate what version of matplotlib you are using
Also test without the coordinate and projection changes and if possible if cartopy is not installed.
You should get the same results in as before without new coordinates and projects and if you don't have cartopy installed and request for a coastaline then it should throw an exception.