4.6.3.1.1. match_filter.Detection

class eqcorrscan.core.match_filter.Detection(template_name, detect_time, no_chans, detect_val, threshold, typeofdet, threshold_type, threshold_input, chans=None, event=None, id=None)[source]

Bases: object

Single detection from detection routines in eqcorrscan. Information required for a full detection based on cross-channel correlation sums.

Parameters:
  • template_name (str) The name of the template for which this detection was made.
  • detect_time (obspy.core.utcdatetime.UTCDateTime) Time of detection as an obspy UTCDateTime object
  • no_chans (int) The number of channels for which the cross-channel correlation sum was calculated over.
  • detect_val (float) The raw value of the cross-channel correlation sum for this detection.
  • threshold (float) The value of the threshold used for this detection, will be the raw threshold value related to the cccsum.
  • typeofdet (str) Type of detection, STA, corr, bright
  • threshold_type (str) Type of threshold used for detection
  • threshold_input (float) Threshold set for detection, relates to threshold according to the threshold_type.
  • chans (list) List of stations for the detection
  • event (obspy.core.event.event.Event) Obspy Event object for this detection, note that this is lost when writing to a Detection objects to csv files using eqcorrscan.core.match_filter.Detection.write()
  • id (str) Identification for detection (should be unique).

Methods

copy() Returns a copy of the detection.
write(fname[, append]) Write detection to csv formatted file.
__init__(template_name, detect_time, no_chans, detect_val, threshold, typeofdet, threshold_type, threshold_input, chans=None, event=None, id=None)[source]

Main class of Detection.

copy()[source]

Returns a copy of the detection.

Returns:Copy of detection
write(fname, append=True)[source]

Write detection to csv formatted file.

Will append if append==True and file exists

Parameters:
  • fname (str) Full path to file to open and write to.
  • append (bool) Set to true to append to an existing file, if True and file doesn’t exist, will create new file and warn. If False will overwrite old files.