PURIFY
Next-generation radio interferometric imaging
Public Member Functions | Public Attributes | List of all members
purify::pfitsio::header_params Struct Reference

#include <pfitsio.h>

+ Collaboration diagram for purify::pfitsio::header_params:

Public Member Functions

 header_params (const std::string &fits_name_, const std::string &pix_units_, const t_real channels_total_, const t_real ra_, const t_real dec_, const stokes pol, const t_real cellx_, const t_real celly_, const t_real mean_frequency_, const t_real channel_width_, const t_uint niters_, const bool hasconverged_, const t_real relative_variation_, const t_real residual_convergence_, const t_real epsilon_)
 create fits header object and fill More...
 
 header_params ()
 create empty fits header More...
 
bool operator== (const header_params &h2) const
 
bool operator!= (const header_params &h2) const
 

Public Attributes

std::string fits_name = "output_image.fits"
 
t_real mean_frequency = 0
 
t_real cell_x = 1
 
t_real cell_y = 1
 
t_real ra = 0
 
t_real dec = 0
 
t_int pix_ref_x = 0
 
t_int pix_ref_y = 0
 
std::string pix_units = "Jy/BEAM"
 
t_real channels_total = 1
 
t_real channel_width = 8
 
t_real polarisation = 1
 
t_int niters = 0
 
bool hasconverged = false
 
t_real relative_variation = 0
 
t_real residual_convergence = 0
 
t_real epsilon = 0
 

Detailed Description

Definition at line 13 of file pfitsio.h.

Constructor & Destructor Documentation

◆ header_params() [1/2]

purify::pfitsio::header_params::header_params ( const std::string &  fits_name_,
const std::string &  pix_units_,
const t_real  channels_total_,
const t_real  ra_,
const t_real  dec_,
const stokes  pol,
const t_real  cellx_,
const t_real  celly_,
const t_real  mean_frequency_,
const t_real  channel_width_,
const t_uint  niters_,
const bool  hasconverged_,
const t_real  relative_variation_,
const t_real  residual_convergence_,
const t_real  epsilon_ 
)
inline

create fits header object and fill

Definition at line 33 of file pfitsio.h.

39  : fits_name(fits_name_),
40  pix_units(pix_units_),
41  channels_total(channels_total_),
42  mean_frequency(mean_frequency_),
43  channel_width(channel_width_),
44  cell_x(cellx_),
45  cell_y(celly_),
46  ra(ra_),
47  dec(dec_),
48  niters(niters_),
49  hasconverged(hasconverged_),
50  epsilon(epsilon_),
51  relative_variation(relative_variation_),
52  residual_convergence(residual_convergence_) {
53  try {
54  this->polarisation = stokes_int.at(pol);
55  } catch (std::out_of_range &e) {
56  PURIFY_LOW_LOG("Polarisation type not recognised by FITS, assuming Stokes I.");
57  this->polarisation = stokes_int.at(stokes::I);
58  };
59  };
#define PURIFY_LOW_LOG(...)
Low priority message.
Definition: logging.h:207
const std::map< stokes, t_int > stokes_int
Definition: types.h:45

References purify::I, PURIFY_LOW_LOG, and purify::stokes_int.

◆ header_params() [2/2]

purify::pfitsio::header_params::header_params ( )
inline

create empty fits header

Definition at line 61 of file pfitsio.h.

61 {};

Member Function Documentation

◆ operator!=()

bool purify::pfitsio::header_params::operator!= ( const header_params h2) const
inline

Definition at line 74 of file pfitsio.h.

74 { return not(*this == h2); }

◆ operator==()

bool purify::pfitsio::header_params::operator== ( const header_params h2) const
inline

Member Data Documentation

◆ cell_x

t_real purify::pfitsio::header_params::cell_x = 1

Definition at line 17 of file pfitsio.h.

Referenced by operator==(), TEST_CASE(), and purify::pfitsio::write3d().

◆ cell_y

t_real purify::pfitsio::header_params::cell_y = 1

Definition at line 18 of file pfitsio.h.

Referenced by operator==(), TEST_CASE(), and purify::pfitsio::write3d().

◆ channel_width

t_real purify::pfitsio::header_params::channel_width = 8

Definition at line 25 of file pfitsio.h.

Referenced by operator==(), TEST_CASE(), and purify::pfitsio::write3d().

◆ channels_total

t_real purify::pfitsio::header_params::channels_total = 1

Definition at line 24 of file pfitsio.h.

Referenced by operator==(), and TEST_CASE().

◆ dec

t_real purify::pfitsio::header_params::dec = 0

Definition at line 20 of file pfitsio.h.

Referenced by operator==(), TEST_CASE(), and purify::pfitsio::write3d().

◆ epsilon

t_real purify::pfitsio::header_params::epsilon = 0

Definition at line 31 of file pfitsio.h.

Referenced by operator==(), TEST_CASE(), and purify::pfitsio::write3d().

◆ fits_name

std::string purify::pfitsio::header_params::fits_name = "output_image.fits"

◆ hasconverged

bool purify::pfitsio::header_params::hasconverged = false

Definition at line 28 of file pfitsio.h.

Referenced by main(), operator==(), TEST_CASE(), and purify::pfitsio::write3d().

◆ mean_frequency

t_real purify::pfitsio::header_params::mean_frequency = 0

Definition at line 16 of file pfitsio.h.

Referenced by operator==(), TEST_CASE(), and purify::pfitsio::write3d().

◆ niters

t_int purify::pfitsio::header_params::niters = 0

Definition at line 27 of file pfitsio.h.

Referenced by main(), operator==(), TEST_CASE(), and purify::pfitsio::write3d().

◆ pix_ref_x

t_int purify::pfitsio::header_params::pix_ref_x = 0

Definition at line 21 of file pfitsio.h.

Referenced by operator==().

◆ pix_ref_y

t_int purify::pfitsio::header_params::pix_ref_y = 0

Definition at line 22 of file pfitsio.h.

Referenced by operator==().

◆ pix_units

std::string purify::pfitsio::header_params::pix_units = "Jy/BEAM"

◆ polarisation

t_real purify::pfitsio::header_params::polarisation = 1

Definition at line 26 of file pfitsio.h.

Referenced by operator==(), and TEST_CASE().

◆ ra

t_real purify::pfitsio::header_params::ra = 0

Definition at line 19 of file pfitsio.h.

Referenced by operator==(), TEST_CASE(), and purify::pfitsio::write3d().

◆ relative_variation

t_real purify::pfitsio::header_params::relative_variation = 0

Definition at line 29 of file pfitsio.h.

Referenced by operator==(), TEST_CASE(), and purify::pfitsio::write3d().

◆ residual_convergence

t_real purify::pfitsio::header_params::residual_convergence = 0

Definition at line 30 of file pfitsio.h.

Referenced by operator==(), TEST_CASE(), and purify::pfitsio::write3d().


The documentation for this struct was generated from the following file: