Polarimetric calibrators. More...

#include <PolnCalibrator.h>

Inheritance diagram for Pulsar::PolnCalibrator:
Pulsar::Calibrator Reference::Able Reference::HeapTracked Pulsar::HybridCalibrator Pulsar::ManualPolnCalibrator Pulsar::ReferenceCalibrator Pulsar::SystemCalibrator Pulsar::PolarCalibrator Pulsar::SingleAxisCalibrator Pulsar::PulsarCalibrator Pulsar::ReceptionCalibrator Pulsar::DoPCalibrator Pulsar::OffPulseCalibrator

Public Member Functions

 PolnCalibrator (const Archive *archive=0)
 Construct with optional processed calibrator Archive. More...
 
 PolnCalibrator (const PolnCalibrator &calibrator)
 Copy constructor.
 
virtual ~PolnCalibrator ()
 Destructor.
 
void set_calibrator (const Archive *archive)
 Set the calibrator archive used to define basic attributes.
 
void set_subint (const Index &isub)
 Set the sub-integration index.
 
virtual void set_response_nchan (unsigned nchan)
 Set the number of frequency channels in the response array.
 
virtual unsigned get_response_nchan () const
 Get the number of frequency channels in the response array.
 
virtual Jones< float > get_response (unsigned ichan) const
 Return the system response for the specified channel.
 
bool has_Receiver () const
 Return true if the Receiver is set.
 
const Receiverget_Receiver () const
 Return the Receiver.
 
void set_Receiver (const Archive *)
 Set the Receiver extension to that of the input Archive.
 
std::string get_receiver_basis_filename () const
 
void transformation_resize (unsigned nchan)
 
bool get_transformation_valid (unsigned ch) const
 Return true if the transformation for the specified channel is valid. More...
 
void set_transformation_invalid (unsigned ch, const std::string &reason)
 Set the transformation invalid flag for the specified channel. More...
 
const std::string & get_transformation_invalid_reason (unsigned ichan) const
 Get the reason that the transformation in the specified channel is invalid.
 
const MEAL::Complex2get_transformation (unsigned ichan) const
 Return the transformation for the specified channel. More...
 
MEAL::Complex2get_transformation (unsigned ichan)
 Return the transformation for the specified channel. More...
 
void set_transformation (unsigned ichan, MEAL::Complex2 *)
 Set the transformation for the secified channel.
 
bool has_covariance () const
 Return true if parameter covariances are stored.
 
void get_covariance (unsigned ichan, std::vector< double > &) const
 Return the covariance matrix vector for the specified channel.
 
virtual bool has_solver () const
 Return true if least squares minimization solvers are available.
 
virtual const MEAL::LeastSquaresget_solver (unsigned ichan) const
 Return the transformation for the specified channel.
 
MEAL::LeastSquaresget_solver (unsigned ichan)
 
void set_backend_correction (bool f)
 Perform backend corrections before inverting response.
 
virtual void calibrate (Archive *archive)
 Calibrate the polarization of the given archive. More...
 
virtual const Typeget_type () const
 Return the Calibrator::Type of derived class.
 
virtual unsigned get_nchan () const
 Get the number of frequency channels in the calibrator.
 
unsigned get_nchan (bool build_if_needed) const
 Get the number of frequency channels in the calibrator.
 
CalibratorExtensionnew_Extension () const
 Return a new PolnCalibratorExtension.
 
Calibrator::Infoget_Info () const
 Return plotting information.
 
void calibration_setup (const Archive *arch)
 Set up done before calibrating an archive.
 
- Public Member Functions inherited from Pulsar::Calibrator
 Calibrator ()
 Default constructor.
 
virtual ~Calibrator ()
 Destructor.
 
Archivenew_solution (const std::string &archive_class) const
 Return a new processed calibrator Archive with a CalibratorExtension.
 
virtual MJD get_epoch () const
 Return the reference epoch of the calibration experiment.
 
virtual std::string get_filenames () const
 Return a string containing the file information.
 
const Archiveget_Archive () const
 Return a const reference to the calibrator archive.
 
template<class T >
bool is_a () const
 
- Public Member Functions inherited from Reference::Able
 Able (const Able &)
 
Ableoperator= (const Able &)
 
unsigned get_reference_count () const
 
- Public Member Functions inherited from Reference::HeapTracked
 HeapTracked (const HeapTracked &)
 
HeapTrackedoperator= (const HeapTracked &)
 
bool __is_on_heap () const
 

Static Public Attributes

static Option< double > minimum_determinant
 Minimum allowable determinant of Jones matrices. More...
 
- Static Public Attributes inherited from Pulsar::Calibrator
static unsigned verbose = 0
 Verbosity level.
 
static Pulsar::Option< float > median_smoothing
 Fractional bandwidth of the window used in median filter.
 
static Pulsar::Option< float > interpolating
 Fractional bandwidth over which interpolation will be performed.
 
static Pulsar::Option< float > det_threshold
 Tolerance to non-physical values of the coherency matrix.
 

Protected Member Functions

void setup_transformation () const
 Set up to call calculate_transformation.
 
virtual void calculate_transformation ()
 Derived classes can create and fill the transformation array.
 
virtual bool get_valid (unsigned ichan) const
 Derived classes can add conditions for channel validity. More...
 
float get_weight (unsigned ichan) const
 Return the weight (0 or 1) of the specified channel.
 
virtual unsigned get_maximum_nchan () const
 Derived classes may be able to shrink the transformation array. More...
 
- Protected Member Functions inherited from Pulsar::Calibrator
void copy_variation (Calibrator *)
 
void set_variation (Variation *var)
 
const Archiveget_calibrator () const
 Provide derived classes with access to the calibrator. More...
 
Archiveget_calibrator ()
 Provide derived classes with mutable access to the calibrator.
 
bool has_calibrator () const
 Return true if the calibrator attribute has been set. More...
 
- Protected Member Functions inherited from Reference::Able
Handle__reference (bool active) const
 
void __dereference (bool auto_delete=true) const
 

Protected Attributes

std::vector< std::vector< double > > covariance
 The array of covariance matrix vectors.
 
std::vector< Jones< float > > response
 The array of Jones matrices derived from the transformation array.
 
Reference::To< const PolnCalibratorExtensionpoln_extension
 The PolnCalibratorExtension of the Archive passed during construction.
 
Reference::To< const FeedExtensionfeed
 The FeedExtension of the Archive passed during construction.
 
bool built
 Flag set when response has been built.
 
unsigned observation_nchan
 The number of frequency channels in the observation to be calibrated.
 
bool do_backend_correction
 Perform backend corrections before inverting.
 
Index subint
 The sub-integration from which to construct a solution.
 
- Protected Attributes inherited from Pulsar::Calibrator
Reference::To< Typetype
 The type of the Calibrator.
 
Reference::To< Variationvariation
 Updates model parameters.
 
Reference::To< const CalibratorExtensionextension
 The CalibratorExtension of the Archive passed during construction.
 
std::vector< std::string > filenames
 Filenames of Pulsar::Archives from which instance was created.
 

Additional Inherited Members

- Static Public Member Functions inherited from Pulsar::Calibrator
static unsigned get_instance_count ()
 Returns the number of Calibrator instances currently in existence.
 
- Static Public Member Functions inherited from Reference::Able
static size_t get_instance_count ()
 
- Static Public Member Functions inherited from Reference::HeapTracked
static void * operator new (size_t size, void *ptr=0)
 
static void operator delete (void *location, void *ptr)
 
static void operator delete (void *location)
 
static size_t get_heap_queue_size ()
 

Detailed Description

Polarimetric calibrators.

The calibrated archive will have its flux normalized by the calibrator flux, such that the FluxCalibrator class need only multiply the archive by the absolute calibrator flux. Polarimetric calibration does not require a flux calibrator in order to work.

Constructor & Destructor Documentation

◆ PolnCalibrator()

Pulsar::PolnCalibrator::PolnCalibrator ( const Archive archive = 0)

Construct with optional processed calibrator Archive.

If a Pulsar::Archive is provided, and if it contains a PolnCalibratorExtension, then the constructed instance can be used to calibrate other Pulsar::Archive instances.

References Reference::To< class, active >::get().

Member Function Documentation

◆ calibrate()

void Pulsar::PolnCalibrator::calibrate ( Archive arch)
virtual

◆ get_maximum_nchan()

unsigned Pulsar::PolnCalibrator::get_maximum_nchan ( ) const
protectedvirtual

Derived classes may be able to shrink the transformation array.

Some calibrators (e.g. HybridCalibrator) may be capable of shrinking the size of the transformation array to match the number of frequency channels in the observation. If this is done, and the next observation to be calibrated has more channels than the first, then the transformation array should be recomputed to match the new frequency resolution.

However, to date, the decision to recompute the transformation array has been based on it having zero size. It is not possible to compare tranformation.size() with get_nchan(), because PolnCalibrator::get_nchan makes the same comparison and returns transformation.size().

Rather than add a new method that must be implemented by all of the derived classes, this new method gives shrink-capable classes the opportunity to communicate this feature.

By default, the method returns zero. Otherwise, it should return the maximum possible size of the transformation array that can be supported.

Reimplemented in Pulsar::HybridCalibrator.

◆ get_transformation() [1/2]

MEAL::Complex2 * Pulsar::PolnCalibrator::get_transformation ( unsigned  ichan)

Return the transformation for the specified channel.

Return the system response for the specified channel.

◆ get_transformation() [2/2]

const ::MEAL::Complex2 * Pulsar::PolnCalibrator::get_transformation ( unsigned  ichan) const

Return the transformation for the specified channel.

Return the system response for the specified channel.

◆ get_transformation_valid()

bool Pulsar::PolnCalibrator::get_transformation_valid ( unsigned  ch) const

Return true if the transformation for the specified channel is valid.

Return the system response for the specified channel.

◆ get_valid()

bool Pulsar::PolnCalibrator::get_valid ( unsigned  ichan) const
protectedvirtual

Derived classes can add conditions for channel validity.

Return true if the response for the specified channel is valid.

Reimplemented in Pulsar::HybridCalibrator.

◆ set_transformation_invalid()

void Pulsar::PolnCalibrator::set_transformation_invalid ( unsigned  ch,
const std::string &  reason 
)

Set the transformation invalid flag for the specified channel.

Return the system response for the specified channel.

Referenced by Pulsar::ReferenceCalibrator::calculate_transformation().

Member Data Documentation

◆ minimum_determinant

Pulsar::Option< double > Pulsar::PolnCalibrator::minimum_determinant
static

Minimum allowable determinant of Jones matrices.

Set this parameter to avoid unstable inversion of matrices with a determinant close to zero by flagging such channels as invalid.


The documentation for this class was generated from the following files:

Generated using doxygen 1.8.17