source: trunk/src/python_STSideBandSep.cpp@ 2733

Last change on this file since 2733 was 2726, checked in by Kana Sugimoto, 12 years ago

New Development: No

JIRA Issue: Yes (CAS-4141)

Ready for Test: Yes

Interface Changes: Yes

What Interface Changed: moved various set methods in python to c++

Test Programs:

Put in Release Notes: No

Module(s): sbseparator

Description:

Moved set methods in sbseparator module to c++ (STSideBandSep class).
Defined boost python interface methods, set_freq, set_dirtol, set_shift,
set_limit, solve_both, subtract_other to access them from python codes.


File size: 1.6 KB
RevLine 
[2707]1//#---------------------------------------------------------------------------
2//# python_STSideBandSep.cpp: python exposure of c++ STSideBandSep class
3//#---------------------------------------------------------------------------
4//# Author: Kanako Sugimoto, (C) 2012
5//#
6//# Copyright: See COPYING file that comes with this distribution
7//#
8//#---------------------------------------------------------------------------
9#include <boost/python.hpp>
10#include <boost/python/args.hpp>
11
12#include "STSideBandSep.h"
13
14using namespace boost::python;
15
16namespace asap {
17 namespace python {
18
19void python_STSideBandSep() {
20 class_<STSideBandSep>("SBSeparator")
21 .def( init <> () )
[2726]22 .def( init < const std::vector<std::string> > () )
23 .def( init < const std::vector<ScantableWrapper> > () )
[2707]24 .def( "set_freq", &STSideBandSep::setFrequency,
25 (boost::python::arg("frame")="") )
[2726]26 .def( "set_dirtol", &STSideBandSep::setDirTolerance )
27 .def( "set_shift", &STSideBandSep::setShift )
28 .def( "set_limit", &STSideBandSep::setThreshold )
29 .def( "solve_both", &STSideBandSep::solveBoth )
30 .def( "subtract_other", &STSideBandSep::solvefromOther )
[2707]31 .def( "set_lo1", &STSideBandSep::setLO1,
32 (boost::python::arg("frame")="TOPO",
33 boost::python::arg("reftime")=-1,
34 boost::python::arg("refdir")="") )
[2711]35 .def( "set_lo1root", &STSideBandSep::setLO1Root )
[2707]36 // temporal methods
37 .def( "set_imgtable", &STSideBandSep::setImageTable )
38 .def( "solve_imgfreq", &STSideBandSep::solveImageFreqency )
[2712]39 .def( "_get_asistb_from_scantb", &STSideBandSep::setScanTb0 )
[2707]40 ;
41};
42
43 } // python
44} // asap
Note: See TracBrowser for help on using the repository browser.