source: trunk/src/CalibrationManager.h@ 3123

Last change on this file since 3123 was 3106, checked in by Takeshi Nakazato, 8 years ago

New Development: No

JIRA Issue: No

Ready for Test: Yes/No

Interface Changes: Yes/No

What Interface Changed: Please list interface changes

Test Programs: List test programs

Put in Release Notes: Yes/No

Module(s): Module Names change impacts.

Description: Describe your changes here...


Check-in asap modifications from Jim regarding casacore namespace conversion.

File size: 2.3 KB
Line 
1//
2// C++ Interface: CalibrationManager
3//
4// Description:
5//
6//
7// Author: Takeshi Nakazato <takeshi.nakazato@nao.ac.jp>, (C) 2012
8//
9// Copyright: See COPYING file that comes with this distribution
10//
11//
12#ifndef ASAP_CALIBRATION_MANAGER_H
13#define ASAP_CALIBRATION_MANAGER_H
14
15// ASAP
16// ScantableWrapper.h must be included first to avoid compiler warnings
17// related with _XOPEN_SOURCE
18#include "ScantableWrapper.h"
19#include "STApplyCal.h"
20#include "STCalTsys.h"
21#include "STCalibration.h"
22#include "STCalEnum.h"
23
24#include <string>
25#include <vector>
26
27//#include <boost/scoped_ptr>
28
29#include <casa/BasicSL/String.h>
30#include <casa/Utilities/CountedPtr.h>
31#include <casa/Logging/LogIO.h>
32
33namespace asap {
34
35/**
36 * Class for calibration management.
37 * It also intends to be an interface for Python layer.
38 * @author TakeshiNakazato
39 */
40class CalibrationManager {
41public:
42 CalibrationManager();
43
44 virtual ~CalibrationManager();
45
46 void setScantable(ScantableWrapper &s);
47 void setScantableByName(const std::string &s);
48 void addApplyTable(const std::string &c);
49 void addSkyTable(const std::string &c);
50 void addTsysTable(const std::string &c);
51 void setMode(const std::string &mode);
52 void setTimeInterpolation(const std::string &interp, int order=-1);
53 void setFrequencyInterpolation(const std::string &interp, int order=-1);
54 void setTsysSpw(const std::vector<int> &spwlist);
55 void setTsysSpwWithRange(const casacore::Record &spwlist, bool average=false);
56 void setTsysTransfer(unsigned int from,
57 const std::vector<unsigned int> &to);
58 void setCalibrationOptions(const casacore::Record &options) {options_ = options;}
59 void resetCalSetup();
60 void reset();
61
62 void calibrate();
63 void apply(bool insitu=false, bool filltsys=true);
64 void saveCaltable(const std::string &name);
65 void split(const std::string &name);
66private:
67 STCalEnum::InterpolationType stringToInterpolationEnum(const std::string &s);
68
69 casacore::Bool isAlmaAntenna();
70
71 casacore::CountedPtr<STApplyCal> applicator_;
72
73 std::vector<casacore::CountedPtr<STApplyTable> > skytables_;
74 std::vector<casacore::CountedPtr<STApplyTable> > tsystables_;
75
76 casacore::CountedPtr<Scantable> target_;
77
78 casacore::String calmode_;
79 std::vector<int> spwlist_;
80 casacore::Record spwlist_withrange_;
81 bool do_average_;
82
83 casacore::LogIO os_;
84
85 casacore::Record options_;
86};
87
88}
89#endif
Note: See TracBrowser for help on using the repository browser.