EQTransformer.utils.associator module

Created on Fri Dec 27 18:52:42 2019

@author: mostafamousavi

last update: 01/29/2021

EQTransformer.utils.associator.run_associator(input_dir, start_time, end_time, moving_window=15, pair_n=3, output_dir='.', consider_combination=False)[source]

It performs a very simple association based on detection times on multiple stations. It works fine when you have a small and local network of seismic stations.

Parameters:
  • input_dir (str, default=None) – Directory name containing hdf5 and csv files-preprocessed data.
  • start_time (str, default=None) – Start of a time period of interest in ‘YYYY-MM-DD hh:mm:ss.f’ format.
  • end_time (str, default=None) – End of a timeperiod of interest in ‘YYYY-MM-DD hh:mm:ss.f’ format.
  • moving_window (int, default=15) – The length of time window used for association in second.
  • pair_n (int, default=2) – The minimum number of stations used for the association.
  • output_dir (str, default='.') – Path to the directory to write the output file.
  • consider_combination (bool, default=False) – If True, it will write down all possible combinations of picked arrival times for each event. This will generate multiple events with the same ID, and you will need to remove those with poor solutions after location. This helps to remove the false positives from the associated event.
Returns:

  • output_dir/Y2000.phs (Phase information for the associated events in hypoInverse format.)
  • output_dir/associations.xml (quakeml output (containing origin and pick objects - using ObsPy functions). QuakeML is useful so that the user can then easily use ObsPy to generate input for other relocator methods (e.g. NonLinLoc). Contributed by Stephen Hicks)
  • output_dir/traceNmae_dic.json (A dictionary where the trace name for all the detections associated to an event are listed. This can be used later to access the traces for calculating the cross-correlations during the relocation process.)

Warning

Unlike the other modules, this function does not create the ouput directory. So if the given path does not exist will give an error.