NAME
tfskill - module to perform automatic trace / sample edit-
ting based on time - frequency spectral attributes.
SYNOPSIS
tfskill [ -Nntap ] [ -Ootap ] [ -Fftap ] [ -Sstap ] [ -Ggtap
] [ -Kktap ] [ -Xxtap ] [ -Pptap ] [ -sist ] [ -eiend ] [
-vvel ] [ -nsnstr ] [ -nenetr ] [ -rsnrst ] [ -renred ] [
-nwinnred ] [ -tstepitime ] [ -multmult ] [ -hw1nred ] [
-hw2nred ] [ -qc ] [ -ratio ] [ -range ] [ -zone ] [ -ntra-
cesnrmean ] [ -nsigmanstddev ] [ -V ] [ -? -h -help ]
DESCRIPTION
tfskill was built to ease the chore of trace quality control
on very large data volumes. Where other automatic editting
routines work on data statistics based in the time or the
frequency domain, tfskill works in the time - frequency
domain. It is very good at identifying seismic data charac-
ter anomalies [instrumentation noise, seismic interference
from another boat shooting for instance] which cannot be
isolated by other approaches [skill, glitches, clean,
trstat].
When executed in -qc mode [required to create the stats
file] , a user defined selection of samples from every
input trace are transformed to time - frequency space using
a short time Fourier transform [same algorithm as used in
stft]. Each frequency subband is examined with the one
exhibiting the greatest range of spectral amplitude being
used to provide statistics. Calculated for that subband are
the mean spectral amplitude, a range value [max spectral
amplitude minus the mean] and the ratio of the range to the
mean. These statistics along with the subband used and
record and trace identifiers are output to a trace statis-
tics file [see -S below]. A global statistics file [see -G
below] is also output containing the mean and standard devi-
ation measure for the mean, range and ratio entries in the
above statistics file.
The information in the trace statistics file may be
displayed graphically [using FreeFormat -Axy | xgraph -nl
-P ]. A limiting function can be picked from this display in
the form of a flat file [see -F below] containing a single
trace, minimum, maximum value per line. This file along
with the above statistics file can then be supplied to the
routine for the production run where traces whose statistics
do not conform to the range supplied will be zeroed and
flagged dead [see discussion below].
An equivalent, and significantly faster approach to deriving
the above limiting function is to make use of the XSD output
option [see -X below]. This option creates a four record
USP dataset which may be viewed in XSD and contains
displays of the above four statistical outputs [mean, range,
ratio, subband]. The advantages this method has over the
xgraph approach above are speed, information content and
the ability to pick the limiting function right there in
XSD which can then be supplied to the routine as an XSD
pickfile in place of the above limiting function flat file.
When making the limiting picks order is important. The
minimum pick [closest to sample 1] must be made first and
the maximum pick [the lowermost seqment] must be made last.
When constructing the above XSD dataset a histogram for
each display is constructed. The value associated with the
maximum bin is determined by the relationship between the
mean and standard deviation for each dataset. Traces whose
value fall in the uppermost bin are recorded to the printout
file oftentimes yielding a list of traces that may have some
systematic error throughout the dataset [i.e. amplifier
noise].
When run in production mode [ no -qc on the command line]
the routine outputs a trace kill statistics file [see -K
below] which documents the record and trace indices of the
killed traces along with their statistical parameters. A
recommended quality control measure is to plot this file to
determine that you have not in fact gone overboard and
killed way too many traces. If you are running in -zone
mode this file will indicate all traces that have been exam-
ined but will not necessarily show you the traces that have
had some samples killed. The only way to assess this is to
do a visual QC of data as the project is moving along. When
running in -zone mode any trace whose chosen parameter from
the trace statistics file exceedes the threshold defined by
-nsigma and -ntraces will undergo a time frequency transform
[using a step size of unity], the subband indicated in the
trace statistics file will be examined and if the spectral
amplitude for the window center sample exceedes the thres-
hold that sample will be killed will be zeroed. If the
presence of zones of hard zeroes is going to be a problem
for subsequent processing a slicetrp operation [or a func-
tional equivalent] may be required.
tfskill gets both its data and its parameters from command
line arguments. These arguments specify the input and out-
put dataset names, the design window start time, end time
and start velocity, the trace and record range to operate
over, the time-frequency transform window size in samples
and the window center stepsize in samples, trace header
mnemonics for record and trace indexing to be reported to
the statistics file, the attached limiting function flat-
file or optionally an attached limiting function XSD pick-
file, the XSD dataset, the quality control statistics file,
a trace kill statistics file, a quality control flag, a
range flag, a ratio flag and verbose printout, if desired.
Command line arguments
-N ntap [default: stdin]
Enter the input data set name or file immediately after
typing -N unless the input is from a pipe in which case
the -N entry must be omitted. This input file should
include the complete path name if the file resides in a
different directory. Example -N/b/vsp/dummy tells the
program to look for file 'dummy' in directory '/b/vsp'.
-O otap [default: stdout]
Enter the output data set name or file immediately
after typing -O. This output file is not required when
piping the output to another process. The output data
set also requires the full path name (see above). Not
required or used if -qc is present on the command line.
In quality control mode the program output consists of
the statistics file [-S] and the XSD dataset [-X].
-S stap [default: tfskill_stats]
Enter the trace statistics file name. In this file
will be recorded for each trace of the input volume a
record index, a trace index, the mean, range and ratio
statistics discussed above and the subband used to
derive these statistics for that trace. This file is
required in both the qc and production modes. When
running in quality control mode you may run this step
in an XIKP net distributed over as many cpu's as you
like. Make certain however that all individual tfskill
nodes point at a single statistics file as the code has
been constructed to write to and run from a single
file. When you are in processing mode [no -qc on the
command line] you cannot be distributed across cpu's as
there is no way to distribute the ASCII statistics file
appropriately. In this mode the program requires vir-
tually no cpu and runs extremely quickly making multi-
cpu execution needless.
-G gtap [default: tfskill_stats]
Enter the global statistics file name. In this file
will be recorded for each of the statistical measures
in the above stats file [mean, range, ratio] its global
mean and standard deviation. This information will be
used during the processing pass to allow modification
of the zone kill threshold [see -zone below]
-F ftap [default: not used]
Enter the limiting function flatfile name. One of
either this file or the combination of -P and -X
below are required when in production mode [ no -qc on
the command line]. The limiting function is a flat
file of a single index, min, max entry per line where
index refers to the index used as a trace identifier
within a record, min is the minimum attribute value to
be allowed and max is the maximum attribute value to be
allowed. The range of values may be obtained from the
plot of the above statistics file for whichever attri-
bute provides the discrimination required to handle
your data problem. Traces whose attributes lay outside
the range specified in this file have their sample
values set to zero and a 30000 entered in the trace
header entry StaCor.
-P ptap [default: not used]
Enter the XSD pickfile file name containing the limit-
ing function picked from the XSD display [-X below].
This file must contain two and only two pick segments.
The first pick segment is the minimum limit and the
second is the maximum limit. Also required when using
this option is the XSD display file [see -X below].
The trace data displayed in the XSD dataset below
range from a minimum value in sample one to a maximum
value at the last sample of the trace. Either these
files or the limiting function flatfile [see -F above]
are required when in production mode [ no -qc on the
command line]. Traces whose attributes lay outside the
range specified in this file have their sample values
set to zero and a 30000 entered in the trace header
entry StaCor.
-X xtap [default: tfskill_xsd]
Enter the XSD display file name to contain the sta-
tistical information as a four record USP dataset.
The records contain displays of mean, range, ratio and
subband information. Each record is created by binning
the amplitudes of the statistical measure to be
displayed into the same number of samples as the input
dataset with the minimum bin being sample one and the
maximum bin being the last sample of the trace. If the
standard deviation of an attribute is greater than the
mean then bins will range from the minimum value at
sample one to a single standard deviation at the max-
imum sample. If however the standard deviation is less
than the mean the last bin will be positioned at 4
standard deviations from the mean. Any sample exceeding
the last bin value will be counted in the last bin. The
sample values in the resulting dataset are the number
of occurances in each bin. The minimum value [in sam-
ple one] and sample interval for each display are con-
tained in the trace header entries Horz07 and Horz08
respectively.
-K ktap [default: tfskill_kills]
Enter the file name of the output trace kill statistics
file. In this file will be recorded for each trace
killed in the input dataset the RecNum, TrcNum, user
defined record index, user defined trace index, the
mean, range and ratio statistics discussed above and
the subband used to derive these statistics for that
trace. This file is neither used nor required when
running in quality control mode. You should view this
file in the same fashion as with the statistics file
[see -S above] to quality control the distribution of
traces killed. Examination of this file is strongly
recommended as you may have toasted your dataset and
not find out until much later in your processing flow
when odd fold starts turning up. The total number of
traces killed is recorded in the program printout file.
-s ist [default: 0]
Enter the start time of the design window.
-e iend [default: end of trace]
Enter the end time of the design window.
-v vel [default: 10000000.0]
Enter a velocity with which to vary the design window
start time.
-ns nstr [default: 1]
Enter the start sequential trace number.
-ne netr [default: last trace in record]
Enter the end sequential trace number.
-rs nrst [default:1]
Enter start sequential record number.
-re nred [default: last record in record]
Enter end sequential record number.
-nwin nwin [default: 32]
Enter the number of samples in the short time Fourier
transform sampling window. This parameter has a large
effect on execution time as the greater the value the
more frequency subbands will be generated. The default
value of 32 time samples generates 16 frequency sub-
bands evenly distributed between zero Hz and the
Nyquist frequency. In practice to date there has been
no need to vary this parameter. Values less than 32
are not allowed.
-tstep itime [default: 1]
Enter the step size in samples to use when moving the
time-frequency transform window down the trace. The
default is to center the sampling window over every
sample of the dataset in turn thereby transforming the
entire trace. It has been found that the stepsize can
be increased significantly and still allow for effec-
tive processing of the targeted noise events. Use of
this parameter can greatly reduce run times for the
required qc pass of this routine. Using a tstep of 10
for instance will reduce the run time by a factor of
10.
-mult mult [default: 1.0]
Enter the multiplier to use in determining the range of
the XSD dataset histogram. If you find that it is
difficult to pick a limiting function as a large per-
centage of your data points are clustered at the last
sample you can stretch out the histogram by a user
defined factor using this entry. An entry of 2.0 will
cause the amplitude of the last bin to be 2 times as
great.
-hw1 RecWrd [default: LinInd]
Enter the trace header mnemonic to be used as a record
index in the statistics file [see -S above].
-hw2 TrcWrd [default: DphInd]
Enter the trace header mnemonic to be used as a trace
index in the statistics file [see -S above].
-qc Enter the command line argument '-qc' to cause tfskill
to operate in quality control mode. In this mode no
output seismic dataset is generated. A trace statis-
tics file and XSD display dataset are generated which
may be used to pick global editting parameters. Infor-
mation concerning global maxima and minima are also
recorded in the program printout file.
-range [default: use spectral mean amplitude]
Enter the command line argument '-range' if you have
chosen to use the spectral range category from the
statistics file [see -S above] as a discriminator for
trace editting.
-ratio [default: use spectral mean amplitude]
Enter the command line argument '-ratio' if you have
chosen to use the ratio of range to mean spectral
amplitude from the statistics file [see -S above] as a
discriminator for trace editting.
-zone [default: kill anomalous trace]
Enter the command line argument '-zone' if you wish to
zero out only zones within a trace that exceed your
picked anaomalous criteria. Here it is often useful to
make very liberal picks in your control function. That
is pick a set of control segments that include quite a
bit of the upper portion of your data. In this fashion
more data will be examined than just the traces that
you think are anomalous. If you find that you want to
kill more data another useful variable set is the
-ntraces and -nsigma entries [below]. You can even
make -nsigma negative to really lower the threshold of
rejection below the mean of your trace spectra.
-ntraces ntrcs [default: 5]
Enter the number of adjacent traces [before the current
trace] over which to keep a running average of the mean
spectral density.
-nsigma nstddev [default: 4.0]
Enter the number of standard deviations to allow the
spectral estimate to vary away from the running average
mean spectral amplitude before killing the window
center sample. If you want to go below the mean be
sure to use a negative nsigma.
-V Enter the command line argument '-V' to get additional
printout.
-? -h or -help
Enter the command line argument '-?', -h or -help to
get online help. The program terminates after the help
screen is printed.
Description
tfskill runs in two passes, the first being a qc pass. As
such it is possible to hone in on a particular problem area
of your data using appropriate window design and sample
decimation during the qc pass that will not be required or
used during the production pass. The resulting statistics
file will be accessed during the second pass along with your
limiting function file in order to process your data. No
T-F calculation is performed during the execution pass, all
trace kill decisions are made based on the limiting function
and the stats file entry for any given trace. If the -zone
option is chosen only those traces which fail the criteria
comparison will be T-F transformed. During this transform
process any zone that fails an additional test based on
-nsigma standard deviations away from the running sum mean
of the chosen statistic [mean, range, ratio] will have the
central sample of the window zeroed. In this way the global
pickfile limits simply indicate to the routine which traces
to examine in detail. The trace transform information
itself dictates which samples on the trace are killed.
For example, say you have a dataset that has noisy traces
deep with characteristics close to the direct arrivals. In
this case leaving both in will make it hard to gain any lev-
erage on the deeper noise events. You could make use of the
[-s, -e and -v] parameters above during the qc pass to exam-
ine data from below the first breaks and generate the stats
file.
tfskill -N data -qc -s 680 -v 1500 -tstep 10 -S stats -G
globalstats -X xsdfile
During the production pass simply pass all the data as the
trace kill decision will be made based on the above statis-
tics file and the limiting function information supplied at
this time. Remember, here complete traces are killed.
tfskill -N data -O dataout -S stats -P picks -X xsdfile -K
kills -G globalstats
During the production pass to use flag for a sample kill
within a trace [-zone] use:
tfskill -N data -O dataout -S stats -P picks -X xsdfile -K
kills -G globalstats -nsigma 4.0 -ntraces 5.0 -zone
BUGS
Only a single attribute may be used at a time.
SEE ALSO
skill(1) clean(1) glitches(1) stft(1) rwspec(1)
AUTHOR
Paul G.A. Garossino, ATTC, Socon 422-3932
Julia C. Garossino, Jenks East Elementary
COPYRIGHT
copyright 2001, Amoco Production Company
All Rights Reserved
an affiliate of BP America Inc.
Man(1) output converted with
man2html