casa  5.7.0-16
 All Classes Namespaces Files Functions Variables Typedefs Enumerations Enumerator Friends Macros Groups Pages
SDDoubleCircleFilter.h
Go to the documentation of this file.
1 //# SDDoubleCircleFilter.h: Filter for SDDoubleCircleGainCal
2 //# Copyright (C) 1996,1997,1998,1999,2000,2001,2002,2003
3 //# Associated Universities, Inc. Washington DC, USA.
4 //#
5 //# This library is free software; you can redistribute it and/or modify it
6 //# under the terms of the GNU Library General Public License as published by
7 //# the Free Software Foundation; either version 2 of the License, or (at your
8 //# option) any later version.
9 //#
10 //# This library is distributed in the hope that it will be useful, but WITHOUT
11 //# ANY WARRANTY; without even the Implied warranty of MERCHANTABILITY or
12 //# FITNESS FOR A PARTICULAR PURPOSE. See the GNU Library General Public
13 //# License for more details.
14 //#
15 //# You should have received a copy of the GNU Library General Public License
16 //# along with this library; if not, write to the Free Software Foundation,
17 //# Inc., 675 Massachusetts Ave, Cambridge, MA 02139, USA.
18 //#
19 //# Correspondence concerning AIPS++ should be addressed as follows:
20 //# Internet email: aips2-request@nrao.edu.
21 //# Postal address: AIPS++ Project Office
22 //# National Radio Astronomy Observatory
23 //# 520 Edgemont Road
24 //# Charlottesville, VA 22903-2475 USA
25 //#
26 
27 #ifndef _MSVIS_SD_DOUBLE_CIRCLE_FILTER_H_
28 #define _MSVIS_SD_DOUBLE_CIRCLE_FILTER_H_
29 
30 #include <map>
31 
32 #include <casacore/casa/aips.h>
34 
37 
38 namespace casacore {
39 // forward declaration
40 template<class T> class Vector;
41 class MeasurementSet;
42 class Record;
43 class String;
44 }
45 
46 namespace casa { //# NAMESPACE CASA - BEGIN
47 
48 namespace vi { //# NAMESPACE vi - BEGIN
49 
50 // forward declaration
51 class VisBuffer2;
52 
54 public:
55  // constructor
56  SDDoubleCircleFilter(casacore::Record const &configuration);
57 
58  // destructor
60  }
61 
62  // return string representation of the filter type
64 
65  // filter query
66  // isResidue returns true if given vb doesn't pass through the filter
67  bool isResidue(VisBuffer2 const *vb) {
68  return !isFiltrate(vb);
69  }
70 
71  // isFiltrate returns true if given vb does pass through the filter
72  // (either fully and partly)
73  bool isFiltrate(VisBuffer2 const *vb);
74 
75  // row-wise filtration information
76  // it fills in is_filtrate vector (resize if necessary)
77  // and returns number of rows that pass through the filter
78  int isFiltratePerRow(VisBuffer2 const *vb, casacore::Vector<bool> &is_filtrate);
79 
80  // sync with VI2
81  void syncWith(ViImplementation2 const *vii);
82 
83 private:
84  void initFilter();
85 
88 
89  // parameter for filtering
90  bool smooth_;
92 
93  // time range list that observed central region
94  std::map<TimeRangeKey, TimeRangeList, TimeRangeKey::Less> timerange_list_;
95 };
96 
97 } //# NAMESPACE vi - END
98 
99 } //# NAMESPACE CASA - END
100 
101 #endif // _MSVIS_SD_DOUBLE_CIRCLE_FILTER_H_
std::vector< double > Vector
Definition: ds9context.h:24
bool smooth_
parameter for filtering
bool isFiltrate(VisBuffer2 const *vb)
isFiltrate returns true if given vb does pass through the filter (either fully and partly) ...
bool isResidue(VisBuffer2 const *vb)
filter query isResidue returns true if given vb doesn&#39;t pass through the filter
casacore::String filterType() const
return string representation of the filter type
void syncWith(ViImplementation2 const *vii)
sync with VI2
double Double
Definition: aipstype.h:55
SDDoubleCircleFilter(casacore::Record const &configuration)
constructor
int isFiltratePerRow(VisBuffer2 const *vb, casacore::Vector< bool > &is_filtrate)
row-wise filtration information it fills in is_filtrate vector (resize if necessary) and returns numb...
A hierarchical collection of named fields of various types.
Definition: Record.h:180
std::map< TimeRangeKey, TimeRangeList, TimeRangeKey::Less > timerange_list_
time range list that observed central region
VisBuffer2s encapsulate one chunk of visibility data for processing.
Definition: VisBuffer2.h:141
VisibilityIterator2 iterates through one or more readonly MeasurementSets.
String: the storage and methods of handling collections of characters.
Definition: String.h:223
casacore::Record const & configuration_
#define casacore
&lt;X11/Intrinsic.h&gt; #defines true, false, casacore::Bool, and String.
Definition: X11Intrinsic.h:42