Conversation
This module will be described more a bit later.
Compiles
Also add -Cb to get bounding polygon.
Ugh, sorry typed the wrong letter. I meant -M. |
|
AH, -M. OK, well it currently supports arc units, so -M30m and -M15s/30s works. There is no support to accept distances in km, for instance, if that is what you where thinking? BTW, I made minor changes to allow for images. Basically exclude -W -N for images. |
It's not so much that I really want to be able to specify (e.g.) 10 km margins, but that I would prefer the description for -M specify what types of units are supported and what the default units are for margins if not given. Thanks for adding some details.
Great, thanks! Regarding images, the specific use case that I considered was selecting all images that have <X% of the pixels matching some criteria based on the data values (commonly used to select images with minimal cloud cover based on a bitmask band). I agree that it's better to get the base functionality merged rather than focus on additional features, so I am not requesting that this be included in this PR. But, do you think these types of selections based on values in images would be reasonable feature requests in the future? |
|
Thanks, just updated -M description do say d, m, and s units are available for geographic grids. |
|
Let me know if you think this one is OK to go. I added that it is experimental at the top of the RST docs. |
Yes, I think so. I haven't tried out the latest image addition but tested the other features this morning and it seems like a nice addition. My one comment for now is that the module description "Determine common regions from 2-D grids, images or 3-D cubes" doesn't capture the latest features that you've added. |
maxrjones
left a comment
There was a problem hiding this comment.
There's some comments from my review this morning still at https://github.com/GenericMappingTools/gmt/pull/5929/files. OK to merge without them if you do not agree we the changes.
|
True. Maybe Make selections or determine common regions from 2-D grids, images or 3-D |
Sounds good. |
|
Strange, I went through a bunch of this hours ago and merged in but not in the repo...they were all suggestions and I accepted them. Now they are listed as differences - I guess I need to make the edits. |
Description of proposed changes
The grdselect module fills a gap in GMT capabilities and simplifies a series of workflows that otherwise require considerable scripting. The module operates on a series of grids (or data cubes) and then, depending on options, can
-Rw/e/s/n[/b/t]string, or the closed bounding box polygon for the region.I have added two tests so far. One computes the intersection and union (plus a pad of 2 degrees) of three geographic grids, of which one is off by 360 degrees relative to the others, and another that outputs the list of grids that passed a variety of tests.
Because we are close to 6.3 and this module may well need to add a few more features and/or revise what has been implemented after more discussion, it will remain WIP until after 6.3. Suggestions for additional capability can be added to this PR. Here is the image for the new test, showing in bold the determined regions:
See the man page for more details.