[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

[python #BBS-584657]: Using Cartopy to recreate domains from Mcidas or Basemap



Greetings!

The best way I can think of is to use `set_extents`, but pass in the bounds in 
projected coordinates rather than lat/lon. If you can't get them from McIDAS, 
but you're confident the projections are matching between that and CartoPy, you 
could use CartoPy to transform the lat/lon.

The challenges is that CartoPy is usually drawing a rectangle in projected 
space, and the projections often result in a set of corner points (when 
converting lat/lon to projected) that no longer represent a rectangle.

Hope this helps,

Ryan

> Greetings,
> 
> We are making satellite imagery with McIDAS-X, and I'd like to create some
> images in Python that could be overlaid on the same domains.  I'm wondering
> if there's a way to do that with Cartopy.
> 
> In McIDAS domains are defined with center point and magnification.  I can
> use some McIDAS commands (PC & E)  to find the lat/lon of any location, so
> I can figure out what the positions are of the corners.  From there I was
> able to recreate those domains with Gempak and Basemap, but Basemap is
> deprecated and I'd like to move that over to Cartopy, but that uses extent
> instead of the corners.
> 
> I've been able to get close, but there are still some noticeable
> differences.  I have ways to remove the border of the image, and the
> projection itself seems to be replicating okay.  I tried iterating around
> the edge of that McIDAS domain finding the lats/lons using those McIDAS
> commands, thinking I could find the min/max lat/lons for extent that way,
> but I still couldn't get it to line up.  I can trial & error it enough to
> get the domains to match, but I've got something like 200 domains to do
> this for so I'd strongly prefer an automated approach.
> 
> Can you think of anything I could do to create domains in Cartopy that
> would match up what we do in McIDAS?  Even if I could define a domain like
> we could in Basemap that'd be fine.


Ticket Details
===================
Ticket ID: BBS-584657
Department: Support Python
Priority: Low
Status: Closed
===================
NOTE: All email exchanges with Unidata User Support are recorded in the Unidata 
inquiry tracking system and then made publicly available through the web.  If 
you do not want to have your interactions made available in this way, you must 
let us know in each email you send to us.