Skip to content
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

Allow proj strings for area definition intialization #29

Closed
mitkin opened this issue Dec 14, 2015 · 5 comments
Closed

Allow proj strings for area definition intialization #29

mitkin opened this issue Dec 14, 2015 · 5 comments

Comments

@mitkin
Copy link
Contributor

mitkin commented Dec 14, 2015

Currently AreaDefinition accepts only proj4 dicts. Would be useful to pass proj4 strings, since Proj can parse both.

@djhoese
Copy link
Member

djhoese commented Dec 14, 2015

This isn't really a solution to this issue at all, but @mraspaud and I have also talked about allowing different numbers of parameters too (figuring parameters out on the fly). As part of mpop 2 we had talked about a new Areas definition file format (INI or other), however since pyresample has utilities for loading from a file I guess this would affect pyresample more than mpop.

@mraspaud
Copy link
Member

Why not. string to dict conversion can be done like this:

dict(item.strip().split("=") for item in p4string.split("+")[1:])

So then it's just a matter of testing in if the argument is a string or a dict and make the conversion if necessary

@mitkin
Copy link
Contributor Author

mitkin commented Dec 15, 2015

Yeah, it's not dificult. Let's see if the build passes :)
@davidh-ssec i'd be keen to check how the new format could look like

@mraspaud
Copy link
Member

Can I close this issue ?

@mitkin
Copy link
Contributor Author

mitkin commented Nov 22, 2016

yes, please

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

3 participants