NCFS-Pack
A generic (astro)particle physics analysis framework
 
Loading...
Searching...
No Matches
IceMakeHits Class Reference

TTask derived class to perform hit extraction from waveforms. More...

#include "IceMakeHits.h"

Inheritance diagram for IceMakeHits:

Detailed Description

TTask derived class to perform hit extraction from waveforms.

Copyright(c) 2003, IceCube Experiment at the South Pole. All rights reserved.
Author: The IceCube NCFS-based Offline Project.
Contributors are mentioned in the code where appropriate.
Permission to use, copy, modify and distribute this software and its
documentation strictly for non-commercial purposes is hereby granted
without fee, provided that the above copyright notice appears in all
copies and that both the copyright notice and this permission notice
appear in the supporting documentation.
The authors make no claims about the suitability of this software for
any purpose. It is provided "as is" without express or implied warranty.
// Class IceMakeHits
// TTask derived class to perform hit extraction from waveforms.
//
// In case an event has been rejected by an NcEventSelector (based) processor,
// this task (and its sub-tasks) is not executed.
//
// The code in this processor is based on the algorithms as developed by
// Nick van Eijndhoven and Garmt de Vries-Uiterweerd (Utrecht University, The Netherlands).
// The parameters have been tuned for IceCube waveforms by Dennis Diederix (IIHE, Brussels).
// Further tuning and automatic progression of parameters introduced by Nick van Eijndhoven (IIHE, Brussels).
//
// Procedure applied for Amanda TWR data :
// ---------------------------------------
//
// 1) The waveform is fed to a NcSpectrum object, and the peak locations
// are determined with the NcSpectrum::Search() function.
//
// 2) The waveform is divided into regions corresponding to the peaks found by
// NcSpectrum. The region boundary between two peaks is at the location of
// the minimum between the two peaks.
//
// 3) For each region the "effective baseline" (used in e.g. the
// evaluation of the leading edge value) is determined as :
// AMANDA : effective baseline = fBasefracXXX * value at lower region boundary
// IceCube : effective baseline = previous baseline + fBasefracXXX * (value at lower region boundary - previous baseline).
// In case the "value at lower region boundary" is below the overall baseline, the pulses are obviously
// well separated and the effective baseline is set to the overall baseline again.
// This takes into account the effect from the previous pulse.
// For the first pulse, the effective baseline is equal to the overall
// baseline.
//
// 4) For each region, the point of steepest rise between the lower region
// boundary and the peak location is determined. The tangent at this point
// is extrapolated to the effective baseline. The point of intersection yields the
// leading edge.
//
// 5) For each region the range of charge integration is determined as :
// - Start of integration at the lower region boundary or at the leading edge,
// whichever comes last.
// - End of integration at the upper region boundary or at the point where the
// signal drops below the overall baseline, whichever comes first.
//
// 6) For each region the integrated charge is determined as :
// Sum over bins in integration range of (value in bin - overall baseline).
// Note : For IceCube the effective baseline is used in the charge integration.
//
// 7) For each pulse the quality is evaluated by requiring that :
// peak location - lower region boundary > lower region boundary - leading edge.
// For a too shallow steepest rise, the leading edge value is unreliable, in
// which case the pulse is merged with the previous pulse.
//
// 8) Each pulse is checked for saturation and discarded if necessary.
// Note : For IceCube only the RAW waveforms are checked for saturation.
//
// 9) NcSpectrum needs a minimum number of bins for its Search function, otherwise
// the clipping window is too large, which causes an error. If a waveform does
// not contain enough bins, the following alternative approach is used :
// - A loop over all bins is performed.
// - As soon as the signal exceeds a given threshold, a pulse is started.
// - The pulse ends when the signal drops below the threshold again.
// - While looping, the charge is integrated for each pulse.
//
// The defaults of the various parameters can be changed by the corresponding
// Set memberfunctions.
//
// Procedure applied for IceCube waveform (ATWD and/or FADC) data :
// ----------------------------------------------------------------
//
// The procedure for ATWD/FADC data is essentially the same as for TWR data.
// However, an extension for IceCube is that the baseline of the waveform is
// determined automatically from the waveform itself via the median of all the
// signals below 20% of the maximum signal w.r.t. a first approximation of the baseline.
// The latter is obtained by just taking the median of all the signals in the waveform.
// This baseline value is also stored as a slot value in the corresponding DOM device.
// All relevant parameters can be set independently.
//
// Information about the actual parameter settings can be found in the event
// structure itself via the device named "IceMakeHits".
//
//--- Author: Nick van Eijndhoven and Garmt de Vries-Uiterweerd 15-jan-2007 Utrecht University
//- Modified: Nick van Eijndhoven, IIHE-VUB, Brussel, May 29, 2025 08:41Z

Definition at line 25 of file IceMakeHits.h.

Public Member Functions

 IceMakeHits (const char *name="IceMakeHits", const char *title="Hit extraction")
 
virtual ~IceMakeHits ()
 
virtual void Exec (Option_t *opt)
 
void PrintWaveformNamesI () const
 
void SetBasefracA (Float_t val)
 
void SetBasefracI (Float_t val)
 
void SetMaxPeaksA (Int_t val)
 
void SetMaxPeaksI (Int_t val)
 
void SetMinPulseHeightA (Float_t val)
 
void SetMinPulseHeightI (Float_t val)
 
void SetPeakAcceptanceLevelI (Float_t val)
 
void SetSigmaA (Float_t val)
 
void SetSigmaI (Float_t val)
 
void SetThresholdA (Float_t val)
 
void SetThresholdI (Float_t val)
 
void SetWaveformNameI (const char *name)
 
void UseWaveformNameI (TString name)
 

Protected Member Functions

void Amanda ()
 
void IceCube ()
 

Protected Attributes

Float_t fBasefracA
 
Float_t fBasefracI
 
IceEventfEvt
 
Int_t fMaxPeaksA
 
Int_t fMaxPeaksI
 
Float_t fMinPulseHeightA
 
Float_t fMinPulseHeightI
 
Float_t fPeakAcceptanceLevelI
 
Float_t fSigmaA
 
Float_t fSigmaI
 
Float_t fThresholdA
 
Float_t fThresholdI
 
TObjArray * fUseNamesI
 

Constructor & Destructor Documentation

◆ IceMakeHits()

IceMakeHits::IceMakeHits ( const char * name = "IceMakeHits",
const char * title = "Hit extraction" )
// Default constructor.

Definition at line 114 of file IceMakeHits.cxx.

◆ ~IceMakeHits()

IceMakeHits::~IceMakeHits ( )
virtual
// Default destructor.

Definition at line 139 of file IceMakeHits.cxx.

Member Function Documentation

◆ Amanda()

void IceMakeHits::Amanda ( )
protected
// Hit extraction from the Amanda TWR data.

Definition at line 480 of file IceMakeHits.cxx.

◆ Exec()

void IceMakeHits::Exec ( Option_t * opt)
virtual
// Implementation of the feature extraction.

Definition at line 414 of file IceMakeHits.cxx.

◆ IceCube()

void IceMakeHits::IceCube ( )
protected
// Hit extraction from all IceCube (incl. IceTop) waveform (ATWD and/or FADC) data.

Definition at line 735 of file IceMakeHits.cxx.

◆ PrintWaveformNamesI()

void IceMakeHits::PrintWaveformNamesI ( ) const
// Print the name (pattern) of all the InIce waveforms which will be analysed.

Definition at line 387 of file IceMakeHits.cxx.

◆ SetBasefracA()

void IceMakeHits::SetBasefracA ( Float_t val)
// Set baseline fractional update for Amanda TWR extraction.
// The default as set in the constructor of this class is 0.5.

Definition at line 154 of file IceMakeHits.cxx.

◆ SetBasefracI()

void IceMakeHits::SetBasefracI ( Float_t val)
// Set baseline fractional update for IceCube waveform hit extraction.
// The default as set in the constructor of this class is 0.5.

Definition at line 217 of file IceMakeHits.cxx.

◆ SetMaxPeaksA()

void IceMakeHits::SetMaxPeaksA ( Int_t val)
// Set maximum number of peaks in a waveform for Amanda TWR extraction.
// The default as set in the constructor of this class is 10.

Definition at line 178 of file IceMakeHits.cxx.

◆ SetMaxPeaksI()

void IceMakeHits::SetMaxPeaksI ( Int_t val)
// Set maximum number of peaks in a waveform for IceCube hit extraction.
// The default as set in the constructor of this class is 10.

Definition at line 241 of file IceMakeHits.cxx.

◆ SetMinPulseHeightA()

void IceMakeHits::SetMinPulseHeightA ( Float_t val)
// Set minimum required pulse height for Amanda TWR extraction.
// This is used only for narrow pulses that cannot be handled with NcSpectrum.
// The default as set in the constructor of this class is 50.

Definition at line 190 of file IceMakeHits.cxx.

◆ SetMinPulseHeightI()

void IceMakeHits::SetMinPulseHeightI ( Float_t val)
// Set minimum required pulse height for IceCube waveform hit extraction.
// This is used only for narrow pulses that cannot be handled with NcSpectrum.
// The default as set in the constructor of this class is 0.

Definition at line 265 of file IceMakeHits.cxx.

◆ SetPeakAcceptanceLevelI()

void IceMakeHits::SetPeakAcceptanceLevelI ( Float_t val)
// Set the IceCube minimum height of a peak above the baseline, in terms of baseline spread.
// The default as set in the constructor of this class is 5.

Definition at line 253 of file IceMakeHits.cxx.

◆ SetSigmaA()

void IceMakeHits::SetSigmaA ( Float_t val)
// Set clipping window width for Amanda TWR extraction.
// The default as set in the constructor of this class is 1.5.

Definition at line 166 of file IceMakeHits.cxx.

◆ SetSigmaI()

void IceMakeHits::SetSigmaI ( Float_t val)
// Set clipping window width for IceCube waveform hit extraction.
// The default as set in the constructor of this class is 2.

Definition at line 229 of file IceMakeHits.cxx.

◆ SetThresholdA()

void IceMakeHits::SetThresholdA ( Float_t val)
// Set threshold for use in analysis of narrow pulses for Amanda TWR extraction.
// A peak is assumed to start when the signal rises above threshold*maxval,
// where maxval is the maximum value found in the waveform.
// The default as set in the constructor of this class is 0.2.

Definition at line 203 of file IceMakeHits.cxx.

◆ SetThresholdI()

void IceMakeHits::SetThresholdI ( Float_t val)
// Set threshold for use in analysis of narrow pulses for IceCube waveform hit extraction.
// A peak is assumed to start when the signal rises above threshold*maxval,
// where maxval is the maximum value found in the waveform.
// The default as set in the constructor of this class is 0.2.

Definition at line 278 of file IceMakeHits.cxx.

◆ SetWaveformNameI()

void IceMakeHits::SetWaveformNameI ( const char * name)
// Set the name of a specific IceCube waveform to be analysed.
//
// Notes :
// -------
// 1) Invokation of this memberfunction allows to only specify 1 single
// waveform name (pattern).
// Previously specified name patterns will be overwritten.
// 2) This memberfunction is kept for backward compatibility.
// You are advised to use UseWaveformNameI() instead for more flexibility.
// 3) The search for the corresponding waveform will be performed on basis of
// a pattern name matching, so the functionality is like searching with "wildcards".
// However, the pattern needs to match exactly, i.e. the search is case sensitive.

Definition at line 292 of file IceMakeHits.cxx.

◆ UseWaveformNameI()

void IceMakeHits::UseWaveformNameI ( TString name)
// Specification of the name(s) of the IceCube waveforms to be analysed.
//
// Consecutive invokations of this memberfunction with different names
// will result in an incremental effect.
//
// Example :
// ---------
// UseWaveformNameI("CAL-ATWD");
// UseWaveformNameI("CAL-FADC");
// UseWaveFormNameI("RAW-ATWD0");
//
// This will analyse the waveforms "CAL-ATWD", "CAL-FADC" and "RAW-ATWD0" for each
// DOM encountered in the event structure.
//
// Note :
// ------
// The search for the corresponding waveform will be performed on basis of
// a pattern name matching, so the functionality is like searching with "wildcards".
// For example, UseWaveformNameI("ATWD") will select all the waveforms which have the
// pattern "ATWD" in their name.
// However, the pattern needs to match exactly, i.e. the search is case sensitive.

Definition at line 321 of file IceMakeHits.cxx.

Member Data Documentation

◆ fBasefracA

Float_t IceMakeHits::fBasefracA
protected

Definition at line 48 of file IceMakeHits.h.

◆ fBasefracI

Float_t IceMakeHits::fBasefracI
protected

Definition at line 53 of file IceMakeHits.h.

◆ fEvt

IceEvent* IceMakeHits::fEvt
protected

Definition at line 47 of file IceMakeHits.h.

◆ fMaxPeaksA

Int_t IceMakeHits::fMaxPeaksA
protected

Definition at line 50 of file IceMakeHits.h.

◆ fMaxPeaksI

Int_t IceMakeHits::fMaxPeaksI
protected

Definition at line 55 of file IceMakeHits.h.

◆ fMinPulseHeightA

Float_t IceMakeHits::fMinPulseHeightA
protected

Definition at line 51 of file IceMakeHits.h.

◆ fMinPulseHeightI

Float_t IceMakeHits::fMinPulseHeightI
protected

Definition at line 57 of file IceMakeHits.h.

◆ fPeakAcceptanceLevelI

Float_t IceMakeHits::fPeakAcceptanceLevelI
protected

Definition at line 56 of file IceMakeHits.h.

◆ fSigmaA

Float_t IceMakeHits::fSigmaA
protected

Definition at line 49 of file IceMakeHits.h.

◆ fSigmaI

Float_t IceMakeHits::fSigmaI
protected

Definition at line 54 of file IceMakeHits.h.

◆ fThresholdA

Float_t IceMakeHits::fThresholdA
protected

Definition at line 52 of file IceMakeHits.h.

◆ fThresholdI

Float_t IceMakeHits::fThresholdI
protected

Definition at line 58 of file IceMakeHits.h.

◆ fUseNamesI

TObjArray* IceMakeHits::fUseNamesI
protected

Definition at line 59 of file IceMakeHits.h.


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