EventMap Class Reference

Map triggers. More...

#include <EventMap.h>

Inheritance diagram for EventMap:
Inheritance graph
[legend]
Collaboration diagram for EventMap:
Collaboration graph
[legend]

List of all members.

Public Member Functions

bool BuildClusterMap (const int aMapIndex, const int aCl, const double aTimeCenter=0.0)
 Builds the map of a given cluster.
bool BuildMap (const int aMapIndex, const double aTime)
 Builds the map centered on given GPS time.
int GetMapFrequencyMax (const int aMapIndex)
 Returns the map maximum frequency.
int GetMapFrequencyMin (const int aMapIndex)
 Returns the map minimum frequency.
int GetMapFrequencyResolution (const int aMapIndex)
 Returns the map frequency resolution.
double GetMapLoudestFrequency (const int aMapIndex)
 Returns the frequency value of the (SNR) loudest tile of a given map.
double GetMapLoudestSNR (const int aMapIndex)
 Returns the SNR value of the loudest (SNR) tile of a given map.
double GetMapLoudestTime (const int aMapIndex)
 Returns the time value of the loudest (SNR) tile of a given map.
double GetMapMatch (double &aTimeShift, double &aMatchSumw2, const int aMapIndex, EventMap *aExtMap, const int aExtMapIndex, const double aTimeJitter=0.0)
 Measures and returns the morphology match with an external map.
double GetMapMatch (double &aTimeShift, double &aMatchSumw2, const int aMapIndex1, const int aMapIndex2, const double aTimeJitter=0.0)
 Measures and returns the morphology match between 2 maps.
int GetMapTimeRange (const int aMapIndex)
 Returns the map time range.
int GetMapTimeResolution (const int aMapIndex)
 Returns the map time resolution.
bool NormalizeMap (const int aMapIndex)
 Normalizes the map pixels by the highest pixel value.
bool NormalizeMapLoudest (const int aMapIndex)
 Normalizes the map pixels by the value of the loudest (SNR) tile.
bool PrintMap (const int aMapIndex)
 Prints the map with a given index.
bool PrintMapLive (const double aDuration, const string aOutFile="none")
 Prints a live movie of maps incrementing the current central time.
bool PrintMapNext (const double aTimeFraction=0.25)
 Prints the map incrementing the current central time.
void SetMapAmplitudeContent (void)
 Sets map content to tile amplitude.
bool SetMapFrequencyRange (const int aMapIndex, const double aFreqMin, const double aFreqMax)
 Sets a new map frequency range.
bool SetMapQRange (const int aMapIndex, const double aQMin, const double aQMax)
 Sets a new map Q range.
bool SetMapResolution (const int aMapIndex, const int aTresolution, const int aFresolution)
 Sets a new map resolution.
void SetMapSNRContent (void)
 Sets map content to tile SNR.
bool SetMapTimeRange (const int aMapIndex, const double aTimeRange)
 Sets a new map time range.
Constructors and destructors



 EventMap (const int aNmaps, const string aPattern, const string aDirectory="", const int aVerbose=0)
 Constructor of the EventMap class.
virtual ~EventMap (void)
 Destructor of the EventMap class.

Detailed Description

Map triggers.

This class was designed to plot time-frequency maps of triggers. When initialized, the EventMap object creates map containers centered on 0. These containers can be filled with trigger SNR or amplitude. Maps can be used interactively or saved on disk. This class offers functions to interact with the maps, to compare maps, to animate the maps etc...

Author:
Florent Robinet

Constructor & Destructor Documentation

EventMap::EventMap ( const int  aNmaps,
const string  aPattern,
const string  aDirectory = "",
const int  aVerbose = 0 
)

Constructor of the EventMap class.

aNmaps map containers are initialized. The map parameters are set to default using input triggers (see TriggerSelect). The time range is set to +/- 2 seconds with a 201-pixels resolution and the frequency resolution is set to 200 pixels. By default, maps are filled with tile SNR.

Parameters:
aNmaps number of map containers
aPattern input file pattern
aDirectory trigger ROOT directory
aVerbose verbosity level
EventMap::~EventMap ( void   )  [virtual]

Destructor of the EventMap class.


Member Function Documentation

bool EventMap::BuildClusterMap ( const int  aMapIndex,
const int  aCl,
const double  aTimeCenter = 0.0 
)

Builds the map of a given cluster.

Only tiles of a given cluster are represented on the map. By default, the map is centered on the cluster peak time. Use PrintMap() to update the interactive pad.

Parameters:
aMapIndex map index
aCl cluster index
aTimeCenter if this value is non 0.0, the map is centered on this time value.
bool EventMap::BuildMap ( const int  aMapIndex,
const double  aTime 
)

Builds the map centered on given GPS time.

Use PrintMap() to update the interactive pad.

Parameters:
aMapIndex map index
aTime central GPS time
int EventMap::GetMapFrequencyMax ( const int  aMapIndex  )  [inline]

Returns the map maximum frequency.

Parameters:
aMapIndex map index
int EventMap::GetMapFrequencyMin ( const int  aMapIndex  )  [inline]

Returns the map minimum frequency.

Parameters:
aMapIndex map index
int EventMap::GetMapFrequencyResolution ( const int  aMapIndex  )  [inline]

Returns the map frequency resolution.

Parameters:
aMapIndex map index
double EventMap::GetMapLoudestFrequency ( const int  aMapIndex  ) 

Returns the frequency value of the (SNR) loudest tile of a given map.

Returns 0.0 if failure.

Parameters:
aMapIndex map index
double EventMap::GetMapLoudestSNR ( const int  aMapIndex  ) 

Returns the SNR value of the loudest (SNR) tile of a given map.

Returns -1.0 if failure.

Parameters:
aMapIndex map index
double EventMap::GetMapLoudestTime ( const int  aMapIndex  ) 

Returns the time value of the loudest (SNR) tile of a given map.

Returns 0.0 if failure.

Parameters:
aMapIndex map index
double EventMap::GetMapMatch ( double &  aTimeShift,
double &  aMatchSumw2,
const int  aMapIndex,
EventMap aExtMap,
const int  aExtMapIndex,
const double  aTimeJitter = 0.0 
)

Measures and returns the morphology match with an external map.

FIXME: explain the match algorithm. Returns -1.0 if this function fails.

Parameters:
aTimeShift time-shift used to get the best match (applied to pixels of aEmap)
aMatchSumw2 sum of weights squared
aMapIndex map index
aExtMap external EventMap object.
aExtMapIndex map index for the external EventMap object.
aTimeJitter time jitter +/- [s]
double EventMap::GetMapMatch ( double &  aTimeShift,
double &  aMatchSumw2,
const int  aMapIndex1,
const int  aMapIndex2,
const double  aTimeJitter = 0.0 
)

Measures and returns the morphology match between 2 maps.

FIXME: explain the match algorithm. Returns -1.0 if this function fails.

Parameters:
aTimeShift time-shift used to get the best match (applied to pixels of aMapIndex2)
aMatchSumw2 sum of weights squared
aMapIndex1 first map index
aMapIndex2 second map index
aTimeJitter time jitter +/- [s]
int EventMap::GetMapTimeRange ( const int  aMapIndex  )  [inline]

Returns the map time range.

Parameters:
aMapIndex map index
int EventMap::GetMapTimeResolution ( const int  aMapIndex  )  [inline]

Returns the map time resolution.

Parameters:
aMapIndex map index
bool EventMap::NormalizeMap ( const int  aMapIndex  ) 

Normalizes the map pixels by the highest pixel value.

Parameters:
aMapIndex map index
bool EventMap::NormalizeMapLoudest ( const int  aMapIndex  ) 

Normalizes the map pixels by the value of the loudest (SNR) tile.

Parameters:
aMapIndex map index
bool EventMap::PrintMap ( const int  aMapIndex  ) 

Prints the map with a given index.

Parameters:
aMapIndex map index
bool EventMap::PrintMapLive ( const double  aDuration,
const string  aOutFile = "none" 
)

Prints a live movie of maps incrementing the current central time.

Once a map is plotted, this function can be called to move forward in time. The live map stops after 'aDuration' seconds have been covered. This movie can be saved as an animated gif if an output file is given. Use a negative duration to move backward in time.

Parameters:
aDuration duration in seconds after what the live map stops
aOutFile path to output file.
bool EventMap::PrintMapNext ( const double  aTimeFraction = 0.25  ) 

Prints the map incrementing the current central time.

Once a map is plotted, this function can be used to move back and forth in time. The time fraction indicates the fraction of the map time range used for the shift. A positive value will move forward in time while a negative value will move backward.

Parameters:
aTimeFraction time range fraction used to move to the next map
void EventMap::SetMapAmplitudeContent ( void   )  [inline]

Sets map content to tile amplitude.

bool EventMap::SetMapFrequencyRange ( const int  aMapIndex,
const double  aFreqMin,
const double  aFreqMax 
)

Sets a new map frequency range.

Parameters:
aMapIndex map index
aFreqMin new minimal frequency value [Hz]
aFreqMax new maximal frequency value [Hz]
bool EventMap::SetMapQRange ( const int  aMapIndex,
const double  aQMin,
const double  aQMax 
)

Sets a new map Q range.

Parameters:
aMapIndex map index
aQMin new minimal Q value
aQMax new maximal Q value
bool EventMap::SetMapResolution ( const int  aMapIndex,
const int  aTresolution,
const int  aFresolution 
)

Sets a new map resolution.

The map resolution is defined by the number of time/frequency pixels in the map.

Parameters:
aMapIndex map index
aTresolution time resolution (number of pixels)
aFresolution frequency resolution (number of pixels)
void EventMap::SetMapSNRContent ( void   )  [inline]

Sets map content to tile SNR.

bool EventMap::SetMapTimeRange ( const int  aMapIndex,
const double  aTimeRange 
)

Sets a new map time range.

Parameters:
aMapIndex map index
aTimeRange new time range value [s]

The documentation for this class was generated from the following files:
 All Classes Files Functions Variables Friends Defines

Generated on 29 Sep 2016 by  doxygen 1.6.1