27 #ifndef FLAGGING_RFCUBELATTICE_H
28 #define FLAGGING_RFCUBELATTICE_H
85 unsigned nchan,
unsigned nifr,
86 unsigned ntime,
unsigned nbit,
unsigned ncorr);
162 template<
class T>
class RFCubeLattice
166 std::vector<std::vector<bool> >
lat;
190 {
return nx*ny*nz*
sizeof(T)/(1024*1024) + 1; }
211 {
iter.set(i, j, val); }
214 {
iter.set(ichan, ifr, icorr, val); }
233 #ifndef AIPS_NO_TEMPLATE_SRC
234 #include <flagging/Flagging/RFCubeLattice.tcc>
235 #endif //# AIPS_NO_TEMPLATE_SRC
A Vector of integers, for indexing into Array<T> objects.
RFCubeLatticeIterator()
default constructor creates empty iterator
RFCubeLatticeIterator< T > newIter()
creates a new iterator for this lattice
void advance(casacore::Int iz)
advances internal iterator to specified slot along the Z axis
RFCubeLatticeIterator: iterator over a cubic buffer.
void init(casacore::uInt nx, casacore::uInt ny, casacore::uInt nz, casacore::uInt ncorr, casacore::uInt nAgent)
creates NX x NY x NZ cube tile_mb is the tile size, in MB (when using paging)
T operator()(casacore::uInt i, casacore::uInt j) const
returns element at i,j of cursor
std::vector< std::vector< bool > > lat
T operator()(casacore::uInt i, casacore::uInt j) const
returns element at i,j of cursor
RFCubeLatticeIterator< T > iter
void advance(casacore::uInt iz)
advances internal iterator to specified slot along the Z axis
casacore::IPosition & shape()
returns shape
void cleanup()
destroys cube
casacore::uInt position()
returns position of internal iterator
void set_column(casacore::uInt ifr, const T &val)
sets element for all (ichan, icorr)
void reset()
resets the lattice iterator to beginning.
RFCubeLattice()
default constructor creates empty cube
static casacore::uInt estimateMemoryUse(casacore::uInt nx, casacore::uInt ny, casacore::uInt nz)
returns size of cube
void reset()
resets the lattice iterator to beginning
~RFCubeLatticeIterator()
destructor
void set(casacore::uInt i, casacore::uInt j, const T &val)
void set(casacore::uInt i, casacore::uInt j, const T &val)
sets element at i, j of cursor
std::vector< std::vector< bool > > * lattice
RFCubeLatticeIterator< T > & iterator()
provides access to lattice itself std::vector<std::vector<bool> > & lattice() { return lat; } ...
casacore::IPosition lat_shape
void set(casacore::uInt ichan, casacore::uInt ifr, casacore::uInt icorr, bool val)
~RFCubeLattice()
destructor
casacore::Int position()
returns position of internal iterator