25 #include <pybind11/pybind11.h>
26 #include <pybind11/stl.h>
34 using namespace pybind11::literals;
40 py::module::import(
"astshim.frame");
42 py::class_<SpecFrame, std::shared_ptr<SpecFrame>, Frame>
cls(mod,
"SpecFrame");
44 cls.def(py::init<std::string const &>(),
"options"_a =
"");
45 cls.def(py::init<SpecFrame const &>());
47 cls.def(
"copy", &SpecFrame::copy);
49 cls.def(
"getAlignSpecOffset", &SpecFrame::getAlignSpecOffset);
50 cls.def(
"getAlignStdOfRest", &SpecFrame::getAlignStdOfRest);
51 cls.def(
"getRefDec", &SpecFrame::getRefDec);
52 cls.def(
"getRefRA", &SpecFrame::getRefRA);
53 cls.def(
"getRefPos", py::overload_cast<SkyFrame const &>(&SpecFrame::getRefPos, py::const_),
"frame"_a);
54 cls.def(
"getRefPos", py::overload_cast<>(&SpecFrame::getRefPos, py::const_));
55 cls.def(
"getRestFreq", &SpecFrame::getRestFreq);
56 cls.def(
"getSourceSys", &SpecFrame::getSourceSys);
57 cls.def(
"getSourceVel", &SpecFrame::getSourceVel);
58 cls.def(
"getSourceVRF", &SpecFrame::getSourceVRF);
59 cls.def(
"getSpecOrigin", &SpecFrame::getSpecOrigin);
60 cls.def(
"getStdOfRest", &SpecFrame::getStdOfRest);
62 cls.def(
"setAlignSpecOffset", &SpecFrame::setAlignSpecOffset,
"align"_a);
63 cls.def(
"setAlignStdOfRest", &SpecFrame::setAlignStdOfRest,
"stdOfRest"_a);
64 cls.def(
"setRefDec", &SpecFrame::setRefDec,
"refDec"_a);
65 cls.def(
"setRefRA", &SpecFrame::setRefRA,
"refRA"_a);
66 cls.def(
"setRefPos", py::overload_cast<SkyFrame const &, double, double>(&SpecFrame::setRefPos),
67 "frame"_a,
"lon"_a,
"lat"_a);
68 cls.def(
"setRefPos", py::overload_cast<double, double>(&SpecFrame::setRefPos),
"ra"_a,
"dec"_a);
69 cls.def(
"setRestFreq", py::overload_cast<double>(&SpecFrame::setRestFreq),
"freq"_a);
70 cls.def(
"setRestFreq", py::overload_cast<std::string const &>(&SpecFrame::setRestFreq),
"freq"_a);
71 cls.def(
"setSourceSys", &SpecFrame::setSourceSys,
"system"_a);
72 cls.def(
"setSourceVel", &SpecFrame::setSourceVel,
"vel"_a);
73 cls.def(
"setSourceVRF", &SpecFrame::setSourceVRF,
"vrf"_a);
74 cls.def(
"setSpecOrigin", &SpecFrame::setSpecOrigin,
"origin"_a);
75 cls.def(
"setStdOfRest", &SpecFrame::setStdOfRest,
"stdOfRest"_a);