When a large number of waveform files are available and it is known that they are real events, it might be an advantage to automatically register them into a database. Remember, the database must be made beforehand with MAKEREA. If the filename follows the SEISAN filename convention, the date and time used to generate the S-file are taken from the filename. Otherwise, the file is read to get the date and time from waveform headers. Obviously, the first option is faster. It is possible to register events both to the default database, any other database or the local directory. To run the program, make a filenr.lis of the waveform files and run AUTOREG. It is possible to put blank lines into the filenr.lis to separate into events, in case there is more than one waveform file from the same event. All waveform files before a blank line are put together into one S-file. Alternatively, one waveform file can be given on the prompt line and then no filenr.lis is needed. Optionally, the waveform files can also be moved or copied to WAV or a WAV database subdirectory (including year and month). This can either be the default parameter COPY_WAV_DIR (in SEISAN.DEF) if different from blank. COPY_WAV_DIR should be the same as the data base used by the S-files. However an optionally data base directory entered interactively if COPY_WAV_DIR is set to blank. AUTOREG can also be operated entirely or partly with flags on the prompt line. The flags are:
-file : file name of a single file to register, can be filenr.lis for many
-op : operator
-copy: flag to indicate if copy or move wav files: b for blank, no move or copy, c is copy and m is move
-base: data base for s-files, b for blank for default
-wbase: base for waveform files b for default WAV. If blank, the data base given in SEISAN.DEF will be used.
-model : x model flag for STATIOx.HYP
You can run AUTOREG with any number of flags, parameters not given with the flags will be asked for.
c:\seismo\WOR>autoreg Event type for all events: Local: L (default) Regional: R Distant: D r Move (m) or copy (c) waveform files to WAV (enter=n) ? c Enter wav base to copy/move to, enter for WAV main folder TEST Files will be copied to default WAV base: TEST_ Operator, max 3 chars jh 2004-05-11-0050-42S.NSN___013 sfile: c:\seismo\REA\TEST_\2004\05\11-0050-42R.S200405 File already registered, options are: Ignore (leave old event): Return Ignore all I Overwrite duplicate: O Overwite all duplicates: A Create a new event, different ID: N Create new events for ALL duplicates: *o Sure you want to overwrite(y/n) y c:\seismo\REA\TEST_\2004\05\11-0050-42R.S200405 copy 2004-05-11-0050-42S.NSN___013 c:\seismo\WAV\TEST_\2004\05\ 1 file(s) copied. File transferred to WAV base TEST_ ********** 2004-07-05-1809-44S.NNN___010 sfile: c:\seismo\REA\TEST_\2004\07\05-1809-44R.S200407 c:\seismo\REA\TEST_\2004\07\05-1809-44R.S200407 copy 2004-07-05-1809-44S.NNN___010 c:\seismo\WAV\TEST_\2004\07\ 1 file(s) copied. File transferred to WAV base TEST_ **********
Now comes a listing of waveform file names and S-file names. The program will check if the event is already registered and the same options are available as in program SPLIT (section 13). Since AUTOREG automatically creates S-files for all events in filenr.lis, they will all be given an event type.
CONGAP, check completeness of continuous waveform database
This program checks for completeness of continuous data for a given time interval. The program reads the waveform data to see what data are available and checks for gaps, defined by a constant amplitude value (e.g. 0). The input can come either from an input file (congap.par) or the command line.
Parameters in the input file are:
|CONT BASE:||name of database, you can have more than one|
|START DATE:||start time and date of interval to be read (yyyymmddhhmmss)|
|STOP DATE:||stop time and date of interval to be read (yyyymmddhhmmss)|
|INTERVAL:||duration of intervals read at a time in minutes (e.g. 60. for one hour)|
When started from the command line, the same parameters can be given:
congap -start <yyyymmddhhmmss> -stop <yyyymmddhhmmss> -cbase <text> -interval <number>
The output file (congap.out) looks like this:
EDI HHZ 20080101 0000 0.00 3600.00 3600.00 EDI HHN 20080101 0000 0.00 3600.00 3600.00 EDI HHE 20080101 0000 0.00 3600.00 3600.00 EDI HHZ 20080101 0100 0.00 3600.00 3600.00 EDI HHN 20080101 0100 0.00 3600.00 3600.00 EDI HHE 20080101 0100 0.00 3600.00 3600.00 ...
The fields are station and component code, date and time, expected duration and actual time with data. The output file can be used to produce plots showing data completeness (tool for this not included). When the program runs it also produces a summary output at the end, where the last column gives the percantage of data completeness, and the actual and expected times are in seconds:
-------------------------------------------- # stat comp actual expected % -------------------------------------------- 1 EDI HHZ 86400.00 86400.00 100.0 2 EDI HHN 86400.00 86400.00 100.0 3 EDI HHE 86400.00 86400.00 100.0 --------------------------------------------
CONNOI and EVANOI, noise power spectral density
These two programs with the help of GMT allow to produce noise power spectral density (PSD) plots similar to the ones produced by the PQLX software. CONNOI is the tool that reads the continuous database and produces output files that are evaluated by EVANOI. The computation of the noise PSD follows the method described by McNamara and Buland .
To run CONNOI on a SEISAN continuous database BER use for example:
connoi -start 20100501 -stop 20100502 -cbase BER
To run CONNOI on an archive structure BER use for example:
connoi -start 20100501 -stop 20100502 -arc BER
In both examples BER is the database, you can also specify 'def' and the program will take all default continuous databases or archives defined in SEISAN.DEF. The default output filename is connoi.out.
Example of output:
stat comp date and time duration frequency noise PSD ---------------------------------------------------------- BER HHZ 20100501 0000 0.00 3600.00 0.00200 -159.14 BER HHZ 20100501 0000 0.00 3600.00 0.00204 -159.14 BER HHZ 20100501 0000 0.00 3600.00 0.00209 -159.14 ...
The output from CONNOI can then be used as input to EVANOI. You can enter station and component, give a time interval, select a time of day interval, and chose a reference station. EVANOI produces GMT plotting scripts files that are named after the station. Then simply run the script file to get a plot.
You can also output the data in a compact format using the -compact option. This output does not work with EVANOI, but it is fairly easy to read in your own scripts. An example output :
CONNOI: NF= 500 START=2008120101 STOP=2008120103 DURATION= 60.0min, SPACING= 50.% STATN CMP yyyymmdd HHMMSS.FF SPECLEN -2.69897 -2.68955 -2.68014 ... BER HHZ 20100501 0100 0.00 3600.00 -102.94 -102.94 -102.94 ... BER HHN 20100501 0100 0.00 3600.00 -117.85 -117.85 -117.85 ... BER HHE 20100501 0100 0.00 3600.00 -115.81 -115.81 -115.81 ... VASAV BHZ 20100501 0100 0.00 3600.00 -134.16 -134.16 -134.16 ... VASAV BHN 20100501 0100 0.00 3600.00 -131.06 -131.06 -131.06 ... VASAV BHE 20100501 0100 0.00 3600.00 -124.60 -124.60 -124.60 ... ...
By default, CONNOI calculates spectra every 30 minutes, with each spectra calculated over a 60-minute interval. You can change this using the -spectlen and -spectspace options, where -spectlen gives the interval over which to calculate the spectra (in minutes) and -spectspace gives the spacing between spectra with respect to -spectlen (1.0 for no overlap, 0.5 for 50% overlap, etc). For example:
connoi -start 20100501 -stop 20100502 -cbase BER -spectlen 60 -spectspace 1.
will calculate spectra over a 60-minute interval, spaced every 60 minutes (no overlap). Finally, you can calculate the spectra for a single channel of a single station using the -sgram option. This option always uses the -compact output format and sets spectspace to 1.0. For example:
connoi -start 20100501 -stop 20100502 -cbase BER -sgram TOTI BHZ
DATABASE2MSEED, convert database to miniseed
This program can be used to convert the waveform data that is linked to from a parametric database to miniseed format. The user is asked to enter the database name, and start and end time for the operation.
One should do a small test with a copy of parts of the database before runnung it through the complete database.
Peter Voss : Tue Jun 8 13:38:42 UTC 2021