Debian Codegraph @

asdf_astropy/converters/wcs/highlevelwrapper.py

raw
1 from asdf.extension import Converter
2
3
4 class HighLevelWCSWrapperConverter(Converter):
5 tags = ("tag:astropy.org:astropy/wcs/highlevelwcswrapper-*",)
6 types = ("astropy.wcs.wcsapi.high_level_wcs_wrapper.HighLevelWCSWrapper",)
7
8 def from_yaml_tree(self, node, tag, ctx):
9 from astropy.wcs.wcsapi import HighLevelWCSWrapper
10
11 return HighLevelWCSWrapper(node["wcs"])
12
13 def to_yaml_tree(self, hlwcs, tag, ctx):
14 return {"wcs": hlwcs.low_level_wcs}