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

yamchan: a new channel class to read and write ASDF wcs objects #12

Merged
merged 4 commits into from
Sep 15, 2020

Conversation

dsberry
Copy link
Member

@dsberry dsberry commented Aug 21, 2020

Copy link
Member

@timj timj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

This looks great. My main comment is how the name YamlChan relates to ASDF. YamlChan is fine if the reader works out for itself what the format is. On output though do we have a configuration (like encoding=FITS-WCS) that specifies ASDF output?

src/yamlchan.c Outdated
* - Frames must be basic Frames or SkyFrames.
* - The following SkyFrame systems are not supported: GAPPT,
* HELIOECLIPTIC, J2000, UNKNOWN.
* - Only the following Napping classes are supported:
Copy link
Member

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Napping? (and then it doesn't list anything)

Copy link
Member Author

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

A nap is what I feel I need after 2 weeks frantic holiday! I've added the list of supported Mapping classes, which is: CmpMap, TranMap, UnitMap, ZoomMap, ShiftMap, WinMap, MatrixMap, PermMap, WcsMap, PolyMap, ChebyMap.

src/yamlchan.c Outdated Show resolved Hide resolved
@dsberry
Copy link
Member Author

dsberry commented Sep 7, 2020

The naming was modelled on FitsChan. So YAML is the storage format and the specific data model is (or will be) indicated by an Encoding attribute. At the moment, there's currently no need for an Encoding attribute since only one encoding (ASDF) is supported. But my hope is that I could find time, some time, to add an AST Native encoding to YamlChan (like FitsChan has a Native encoding). And who knows what other schemes people will come up with for storing WCS in yaml format.

@timj
Copy link
Member

timj commented Sep 9, 2020

I think I'd feel better if there was an encoding attribute now that said asdf so we are explicit about it. That seems better than having nothing and then suddenly having something later on.

@dsberry
Copy link
Member Author

dsberry commented Sep 10, 2020

OK. I can do that.

Currently, "ASDF" is the only legal value for YamlEncoding.
@dsberry
Copy link
Member Author

dsberry commented Sep 10, 2020

Done. So where do we go now with this?

Copy link
Member

@timj timj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

@dsberry I formally approve this pull request.

The AllowSimplify flag is a protected internal feature that is only
relevant to a Mapping when it is being simplified. Once the
simplification is complete, the flag should be cleared so that it does
not appear within public dumps of the Mapping.
@dsberry dsberry merged commit f16eef3 into master Sep 15, 2020
@dsberry dsberry deleted the yamlchan branch September 15, 2020 10:21
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

Successfully merging this pull request may close these issues.

2 participants