Omicron
4.2.0
An algorithm to detect and characterize transient events in gravitational-wave detectors
|
Omicron for Ox analyses. More...
#include <OxOmicron.h>
Public Member Functions | |
bool | CreateOutputFile (string &aOutFileName, const unsigned int aTime) |
Creates an ouput file. | |
unsigned int | GetAnalysisDuration (void) |
Returns the Ox analysis duration [s]. | |
Long64_t | GetEntries (const unsigned int aDetectorIndex) |
Returns the number of Omicron results. | |
int | GetEntry (const unsigned int aDetectorIndex, Long64_t aEntry) |
Loads an entry in the Omicron results. | |
double | GetLightTravelTime (void) |
Returns the light travel time between the two detectors. | |
string | GetOmicronChannelName (const unsigned int aDetectorIndex) |
Returns the Omicron channel name. | |
unsigned int | GetOmicronChunkDuration (void) |
Returns the Omicron chunk duration [s]. | |
unsigned int | GetOmicronEndTime (const unsigned int aDetectorIndex) |
Returns the end time of the current Omicron entry. | |
unsigned int | GetOmicronOverlapDuration (void) |
Returns the Omicron overlap duration [s]. | |
unsigned int | GetOmicronQ (const unsigned int aQindex) |
Returns Q value of a given Q plane. | |
unsigned int | GetOmicronQN (void) |
Returns the number of Omicron Q planes. | |
double | GetOmicronSnrSqMax (const unsigned int aDetectorIndex) |
Returns the maximum SNR squared of the current Omicron entry. | |
unsigned int | GetOmicronStartTime (const unsigned int aDetectorIndex) |
Returns the start time of the current Omicron entry. | |
bool | Process (const unsigned int aDetectorIndex, const unsigned int aTimeStart, const bool aResetPsd) |
Runs the Omicron analysis. | |
Constructors and destructors | |
OxOmicron (const string aOptionFile, const unsigned int aGpsRef) | |
Constructor of the OxOmicron class. | |
virtual | ~OxOmicron (void) |
Destructor of the OxOmicron class. | |
Public Member Functions inherited from OxInit | |
void | AttachTree (TTree *aTree) |
Attach a TTree to the output file. | |
void | CloseOutputFile (void) |
Closes the current ouput file (if any). | |
bool | CreateOutputFile (string &aOutFileName, const unsigned int aTime) |
Creates an ouput file. | |
string | GetName (void) |
Returns the object name. | |
string | GetOutputDirectory (void) |
Returns the path to the output directory. | |
unsigned int | GetOxFileN (void) |
Returns the number of Ox files. | |
bool | GetStatus (void) |
Returns the class status. | |
OxInit (const string aOptionFile) | |
Constructor of the OxInit class. | |
virtual | ~OxInit (void) |
Destructor of the OxInit class. | |
Protected Member Functions | |
int | FillTree (const unsigned int aDetectorIndex) |
Fills the output tree with the current Omicron event. | |
Protected Member Functions inherited from OxInit | |
void | AddOptions (void) |
Adds options from the text file. | |
void | DefineOption (const string aTag, const string aKey, const double aDefaultValue, const unsigned int aSize) |
Defines an option (double). | |
void | DefineOption (const string aTag, const string aKey, const int aDefaultValue, const unsigned int aSize) |
Defines an option (integer). | |
void | DefineOption (const string aTag, const string aKey, const string aDefaultValue, const unsigned int aSize) |
Defines an option (string). | |
void | DefineOption (const string aTag, const string aKey, const unsigned int aDefaultValue, const unsigned int aSize) |
Defines an option (unsigned integer). | |
string | GetOxFileName (const unsigned int aFileIndex) |
Returns the path to the Ox file. | |
void | OverloadOption (const string aTag, const string aKey) |
Overloads an option using the text file as a reference. | |
Protected Attributes | |
Streams * | detector [2] |
Detector streams. | |
Omicron * | omicron [2] |
Omicron objects (detector 0 and 1). | |
TTree * | oxo_tree [2] |
TTree: Omicron results. Do not delete as it is owned by the output file. | |
TChain * | oxo_tree_read [2] |
TChain: Omicron results (read-only). | |
Protected Attributes inherited from OxInit | |
GwollumOptions * | ox_opt |
List of options. | |
bool | status |
Class status. | |
Private Member Functions | |
bool | CheckOmicron (void) |
Checks the consistency between the 2 Omicron objects. | |
Omicron * | CreateOmicron (const unsigned int aDetectorIndex, const unsigned int aGpsRef) |
Creates the Omicron object for a given detector. | |
Private Attributes | |
double | light_travel_time |
Light travel time between detectors. | |
double | oxo_snrsq [2] |
TTree: Maximum squared SNR. | |
unsigned int | oxo_start_time [2] |
TTree: Omicron start time (removing padding). | |
Omicron for Ox analyses.
This class is designed to manage the Omicron analysis for Ox. Two Omicron objects are created by the constructor, one for each detector. Call Process() to run the Omicron analysis and generate spectrograms.
The Omicron options can either be provided by two option files or by a list of Ox files. The results of the Omicron analysis is saved in TTree in Ox files: see CreateOutputFile().
OxOmicron::OxOmicron | ( | const string | aOptionFile, |
const unsigned int | aGpsRef | ||
) |
Constructor of the OxOmicron class.
The list of options is given in a text file. They are identified with a set of tag and key words:
OXO OPTIONS
: path to the omicron option files for the first and second detectors.OXO FFL0
: path to the FFL file for the first detector. This option is used to overwrite what is read from Ox files (if any).OXO FFL1
: path to the FFL file for the second detector. This option is used to overwrite what is read from Ox files (if any).OXO INJGEN
: path to the InjGen file with injections. This option is used to overwrite what is read from Ox files (if any).Two Omicron objects are created with CreateOmicron().
If Ox files are provided (see OxInit::OxInit()), the Omicron results can also be read with this class.
[in] | aOptionFile | Path to the option file. |
[in] | aGpsRef | Reference GPS time to intiate Omicron objects. |
|
virtual |
Destructor of the OxOmicron class.
|
private |
Checks the consistency between the 2 Omicron objects.
Conditions to meet:
|
private |
Creates the Omicron object for a given detector.
If no Ox files are provided, the omicron object is created using the option text file provided with OXO/OPTIONS
. With Ox files, the Omicron object is created using the Omicron options saved in the Ox files.
ox.omicron.[0/1].[GPS].opt
) in the output directory.[in] | aDetectorIndex | Detector index: 0 = first detector, 1 = second detector. |
[in] | aGpsRef | Reference GPS time to initiate the Omicron object |
bool OxOmicron::CreateOutputFile | ( | string & | aOutFileName, |
const unsigned int | aTime | ||
) |
Creates an ouput file.
A new ROOT file is opened in the output directory to save the Ox analysis results (OxInit::CreateOutputFile()). The Omicron option TTrees are written in the file with the names "omicron0_options" and "omicron1_options" for the first and second detector respectively. The Omicron TTree "oxo" is initialized in the ouput file.
[out] | aOutFileName | Output ROOT file name. |
[in] | aTime | Time used to name the ouput file. |
|
inlineprotected |
Fills the output tree with the current Omicron event.
[in] | aDetectorIndex | Detector index: 0 = first detector, 1 = second detector. |
|
inline |
Returns the Ox analysis duration [s].
The Ox analysis duration is the duration of Omicron spectrograms excluding the overlap between analysis windows.
|
inline |
Returns the number of Omicron results.
[in] | aDetectorIndex | Detector index: 0 = first detector, 1 = second detector. |
|
inline |
Loads an entry in the Omicron results.
[in] | aDetectorIndex | Detector index: 0 = first detector, 1 = second detector. |
[in] | aEntry | Entry number. |
|
inline |
Returns the light travel time between the two detectors.
|
inline |
Returns the Omicron channel name.
[in] | aDetectorIndex | Detector index: 0 = first detector, 1 = second detector. |
|
inline |
Returns the Omicron chunk duration [s].
|
inline |
Returns the end time of the current Omicron entry.
[in] | aDetectorIndex | Detector index: 0 = first detector, 1 = second detector. |
|
inline |
Returns the Omicron overlap duration [s].
|
inline |
Returns Q value of a given Q plane.
[in] | aQindex | Q plane index. |
|
inline |
Returns the number of Omicron Q planes.
|
inline |
Returns the maximum SNR squared of the current Omicron entry.
[in] | aDetectorIndex | Detector index: 0 = first detector, 1 = second detector. |
|
inline |
Returns the start time of the current Omicron entry.
[in] | aDetectorIndex | Detector index: 0 = first detector, 1 = second detector. |
bool OxOmicron::Process | ( | const unsigned int | aDetectorIndex, |
const unsigned int | aTimeStart, | ||
const bool | aResetPsd | ||
) |
Runs the Omicron analysis.
The Omicron analysis of the chunk starting at a given GPS time is performed:
The analysis results are saved in the Omicron TTree: FillTree().
[in] | aDetectorIndex | Detector index: 0 = first detector, 1 = second detector. |
[in] | aTimeStart | Chunk GPS time start [s]. |
[in] | aResetPsd | Flag to reset the PSD estimation. |
|
protected |
Detector streams.
|
private |
Light travel time between detectors.
|
private |
TTree: Maximum squared SNR.
|
private |
TTree: Omicron start time (removing padding).
|
protected |
TTree: Omicron results. Do not delete as it is owned by the output file.
|
protected |
TChain: Omicron results (read-only).