Where communities thrive


  • Join over 1.5M+ people
  • Join over 100K+ communities
  • Free without limits
  • Create your own community
People
Repo info
Activity
  • 20:42
    liamjkelly closed #2109
  • 20:42
    liamjkelly commented #2109
  • 18:44
    greglucas commented #2083
  • 18:39
    greglucas synchronize #2083
  • 18:29
    ocefpaf commented #2083
  • 17:38
    greglucas commented #2083
  • 17:33
    dopplershift commented #2083
  • 17:31
    greglucas commented #2083
  • 17:17
    greglucas commented #2111
  • 15:57

    greglucas on v0.21.x

    Compatibility with shapely 2.0 … Merge pull request #2110 from j… (compare)

  • 15:57
    greglucas closed #2110
  • 13:18
    jorisvandenbossche commented #2110
  • 10:43
    PBrockmann edited #2111
  • 10:41
    PBrockmann edited #2111
  • 10:40
    PBrockmann edited #2111
  • 09:52
    PBrockmann edited #2111
  • 09:50
    PBrockmann opened #2111
  • Dec 07 23:50
    PBrockmann commented #2103
  • Dec 07 23:15
    jorisvandenbossche commented #2083
  • Dec 07 22:14
    jorisvandenbossche commented #2080
anuappu
@anuappu
Hello: I am a a beginner in Python/cartopy etc so pardon my ignorance. I am encountering an error when I utilize the cointourf utility. Toplology exception side conflict error.
Snippet of my code
 ax = plt.axes(projection=ccrs.LambertConformal(central_longitude=10.0, central_latitude=40.0, standard_parallels=(40.0, 40.0)))
I am a bit confused on what the ax.extent transform should be:
ax.set_extent([-30, 40, 25, 70],crs=ccrs.???())
and finally sc=plt.contourf(xnew, ynew, perc, clevs,
transform=ccrs.PlateCarree(),colors=colours,extend='max')
where xnew is lon and lat in degrees and perc is probability values that I am computing.
anuappu
@anuappu
The code works 95% of the time but once in while fails with a an error "Toplology exception side conflict error at .."
The input data and the calculated probability values seem correct.
Appreciate the feedback.
Greg Lucas
@greglucas
Yes, it looks like there are some bad transformations going on creating invalid geometries at some point in the chain. No one has addressed that issue yet. You can try "transform_first=True" to the contouring algorithm which may lead to nicer geometries... See: https://scitools.org.uk/cartopy/docs/latest/gallery/scalar_data/contour_transforms.html
anuappu
@anuappu
Thank you @greglucas for the quick response. The "transform_first=True" did not work. However, may I ask, you mention that "bad transformations going on creating invalid geometries at some point in the chain" could it be in the way the ax.extent is defined?
Greg Lucas
@greglucas
Yes, it certainly could be, you can try adjusting the limits to see if that helps.
anuappu
@anuappu
Thanks, I will try that and keep you posted.
anuappu
@anuappu
@greglucas I have not have had any success with the issue by altering the ax.extent limits. Is it fair to say the it could be the conflict between the projection of LambertConformal and the transformation to PlateCaree? Also, the area where I am trying to project crosses the 0 longitude (domain includes both the hemispheres). Any suggestions would really be appreciated.
Greg Lucas
@greglucas
Yes, it is very likely bad transformation with some points in a Polygon, and that object being cut/stitched back together incorrectly. No one has found the cause of this yet in that issue, so unfortunately there isn't much we can do until the root cause is determined. One other thought is to try adjusting your contouring levels, which will produce different sets of coordinates.
anuappu
@anuappu
Thanks @greglucas
Alexandre ROULEAU
@arouleau56

Hello everyone, I trie to apply the second cell of this link https://www.geophysique.be/2014/02/25/shaded-relief-map-in-python/

See the code here :

Subplot 2: STRM Map

plt.figure(figsize=(15, 10))
ax = plt.subplot(111, projection=ccrs.PlateCarree())

elev, crs, extent = srtm_composite(12, 47, 1, 1)
elev = np.ma.masked_less_equal(elev,0,copy=False)
plt.imshow(elev, extent=extent, transform=crs,
cmap='gist_earth', origin='lower')

However I got these message : "HTTP Error 401: Unauthorized".
Do you have an idea howto solve it?
Thank you :)

Ryan May
@dopplershift
I'm not even sure how that code could run that far? srtm_composite was removed in CartoPy 0.12 according to the changelog
The SRTM example was removed in #847 due to login issues, but if you have access maybe that version will work for you?
Alex Crosby
@acrosby
is there a problem with the recent versions' packaging for pypi/pip
getting pip complaints about the version metadata not matching the stated version, eventually rolls back to an earlier version that it is happy with
Greg Lucas
@greglucas
What version are you trying? This should be fixed on v0.20.3 that was just released. SciTools/cartopy#2053
Alex Crosby
@acrosby
oh I see, i think i saw it going through 0.20.x<0.20.3 but this was just prior to 0.20.3, thanks!
Elliott Sales de Andrade
@QuLogic
lots of image comparison failures with mpl 3.6, after patching the removed API
haven't checked yet if main is better with the switch to pytest-mpl
Elliott Sales de Andrade
@QuLogic
Ryan May
@dopplershift
oof
Houssam Halaby
@hhalaby
Hello,
Any plans to release cartopy without proj dependency (#2069) ? would be very useful for our installation process.
edit: I see it's in the 0.21 milestone. Any rough idea when that might be ?
Elliott Sales de Andrade
@QuLogic
Greg Lucas
@greglucas
Apparently back to 0.19 at least... https://scitools.org.uk/cartopy/docs/v0.19/gallery/miscellanea/animate_surface.html I'm not sure why I put a break in there (2 * x in the meshgrid)... I know I wanted to make sure the wrap was accounted for.