You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Is your feature request related to a problem? Please describe.
Sometimes a user may want to write to files with a specific naming scheme. The builtin python formatting can get someone pretty far especially thinking about how datetime objects can be formatted. The issue comes when someone has different ideas about capitalization and/or use of hyphens in platform, sensor, and product name (G16, GOES-16, goes-16, goes16, etc). It would be nice if the file pattern could encode some of these types of operations until satpy can do a better job of standardizing names for things. This is especially useful for my Geo2Grid project where users are using the command line and don't modify the python.
Describe the solution you'd like
Follow the solution mentioned here: https://stackoverflow.com/a/17848303/433202
To create a custom string formatter that would support the !u and !l format string to run .upper and .lower on that string argument. I'm not sure how many other ones I would want. Maybe one to remove hyphen, one to replace hyphen with underscore, etc.
Describe any changes to existing user workflow
Nothing changes from what a user can currently do, just added features that would need to be documented.
Additional python or other dependencies
None.
Describe any changes required to the build process
No.
Describe alternatives you've considered
If we standardized platform and sensor across all readers then it would be easier to provide the user a series of keys to choose from like platform_oscar or platform_lower or platform_upper or come up with "standard" ways that things are named (good luck) like platform_nasa. Then the user just puts that in their file pattern: {platform_oscar}_{sensor_lower}_...tif
Additional context
Add any other context or screenshots about the feature request here.
The text was updated successfully, but these errors were encountered:
Is your feature request related to a problem? Please describe.
Sometimes a user may want to write to files with a specific naming scheme. The builtin python formatting can get someone pretty far especially thinking about how datetime objects can be formatted. The issue comes when someone has different ideas about capitalization and/or use of hyphens in platform, sensor, and product name (G16, GOES-16, goes-16, goes16, etc). It would be nice if the file pattern could encode some of these types of operations until satpy can do a better job of standardizing names for things. This is especially useful for my Geo2Grid project where users are using the command line and don't modify the python.
Describe the solution you'd like
Follow the solution mentioned here: https://stackoverflow.com/a/17848303/433202
To create a custom string formatter that would support the
!u
and!l
format string to run.upper
and.lower
on that string argument. I'm not sure how many other ones I would want. Maybe one to remove hyphen, one to replace hyphen with underscore, etc.Describe any changes to existing user workflow
Nothing changes from what a user can currently do, just added features that would need to be documented.
Additional python or other dependencies
None.
Describe any changes required to the build process
No.
Describe alternatives you've considered
If we standardized platform and sensor across all readers then it would be easier to provide the user a series of keys to choose from like
platform_oscar
orplatform_lower
orplatform_upper
or come up with "standard" ways that things are named (good luck) likeplatform_nasa
. Then the user just puts that in their file pattern:{platform_oscar}_{sensor_lower}_...tif
Additional context
Add any other context or screenshots about the feature request here.
The text was updated successfully, but these errors were encountered: