Submodules

NamePurpose
ASCIIASCII file formats (includes GeoCSV, SLIST, and variants)
FastIOReplacement low-level I/O functions to avoid thread locking
QuakeEarthquake seismology
RandSeisGenerate SeisBase structures with quasi-random entries
SEEDStandard for the Exchange of Earthquake Data (SEED) file format
SUDSSeismic Unified Data System (SUDS) file format
SeisHDFDedicated support for seismic HDF5 subformats
UWUniversity of Washington data format

Using Submodules

At the Julia prompt, type using SeisBase.NNNN where NNNN is the submodule name; for example, using SeisBase.Quake loads the Quake submodule.

RandSeis

This submodule is used to quickly generate SeisBase objects with quasi-random field contents. Access it with "using SeisBase.RandSeis"

The following are true of all random data objects generated by the RandSeis module:

  • Channels have SEED-compliant IDs, sampling frequencies, and data types.
  • Random junk fills :notes and :misc.
  • Sampling frequency (:fs) is chosen from a set of common values.
  • Channel data are randomly generated.
  • Time gaps are automatically inserted into regularly-sampled data.
SeisBase.RandSeis.randSeisChannelFunction
randSeisChannel()

Generate a random channel of geophysical time-series data as a SeisChannel.

Keywords

KWDefaultTypeMeaning
sfalseBoolforce channel to have seismic data?
cfalseBoolforce channel to have irregular data?
nx0Int64number of samples in channel [1]
fs_min0.0Float64channels will have fs ≥ fs_min
fc0.0Float64rolloff frequency [2]
  1. if nx ≤ 0, the number of samples is determined randomly
  2. specifing fc with c=false returns a geophone instrument response

See also: randSeisData, fctoresp

source
SeisBase.RandSeis.randSeisDataFunction
randSeisData()

Generate 8 to 24 channels of random seismic data as a SeisData object.

randSeisData(N)

Generate N channels of random seismic data as a SeisData object.

Keywords

KWDefaultTypeMeaning
s0.6Float64chance each channel is seismic data
c0.2Float64chance each channel is irregular (fs=0)
nx0Int64number of samples in each channel
fs_min0.0Float64regular channels have fs ≥ fs_min
a0falseBoolrecalculate :resp constants?

Behavior

  • If nx ≤ 0, the number of samples is determined randomly for each channel
  • 100*s is the minimum percentage of channels with guaranteed seismic data
  • 100*c is the maximum percentage of channels with irregularly-sampled data
  • s takes precedence over c; they are not renormalized. Thus, for example:
    • randSeisData(12, c=1.0, s=1.0) works like randSeisData(12, c=0.0, s=1.0)
    • randSeisData(c=1.0) works like randSeisData(s=0.0)
  • For N channels, s*N is rounded up; c*N is rounded down. Thus:
    • randSeisData(10, c=0.28) and randSeisData(10, c=0.2) are equivalent
    • randSeisData(10, s=0.28) and randSeisData(10, s=0.3) are equivalent
  • By default, :resp.a0 = 1.0 for all channels; a0=true calls resp_a0!(S)
    • :resp.p and :resp.z are random; a0=true isn't guaranteed to work

See also: randSeisChannel, resp_a0!

source
SeisBase.RandSeis.randSeisEventFunction
randSeisEvent([, c=0.2, s=0.6])

Generate a SeisEvent structure filled with random header and channel data.

  • 100*c is the percentage of :data channels after the first with irregularly-sampled data (fs = 0.0)
  • 100*s is the percentage of :data channels after the first with guaranteed seismic data.

See also: randSeisChannel, randSeisData, randSeisHdr, randSeisSrc

source

SEED

Submodule for the Standard for the Exchange of Earthquake Data (SEED) file format; includes additional functionality.

Scanning SEED Volumes

SeisBase.SEED.scan_seedFunction
soh = scan_seed(fname::String[, KWs])

Scan seed file fname and report properties in human-readable string array soh.

General Keywords

  • quiet (Bool): true to only return compact summary strings (no stdout)
  • memmap (Bool): true to use memory mapping
  • v (Integer): v > 0 increases scan verbosity

Output Keywords

These are all Booleans; false excludes from scan.

  • npts: Number of samples per channel (default: true)
  • ngaps: Number of time gaps per channel (default: true)
  • nfs: Number of unique fs values per channel (default: true)
  • seg_times: Exact gap times (default: false)
  • fs_times: Exact times of fs changes (default: false)

Note that seg_times and fs_times dump verbose per-channel tabulation to stdout.

Users are encouraged to submit feature request or issues if there's a need to scan for other changes within a SEED volume.

Interaction with Online Requests

scan_seed cannot interact directly with online SEED requests. As a workaround, do $get_data(..., w=true)$ to dump the raw request directly to disk, then scan the file(s) created.

Caution

Rarely, the number of gaps reported is off-by-one from read_data.

source

UW

The UW submodule extends functionality for the University of Washington (UW) file format(s).

The UW data format was created in the 1970s by the Pacific Northwest Seismic Network (PNSN), USA, for event archival. It remained in use through the 1990s. A UW event is described by a pickfile and a corresponding data file, whose filenames were identical except for the last character. The data file is self-contained; the pick file is not required to read raw trace data. However, station locations were stored in an external text file.

Only UW-2 data files are supported by SeisBase. We have only seen UW-1 data files in Exabyte tapes from the 1980s.

SeisBase.UW.uwpfFunction
H, R = uwpf(pf[, v])

Read UW-format seismic pick file pf into SeisHdr object H, with seismic source description (focal mechanism) returned in SeisSrc object R.

uwpf!(W, pf[, v::Integer=KW.v])

Read UW-format seismic pick info from pickfile f into SeisEvent object W. Overwrites W.source and W.hdr with pickfile information. Keyword v controls verbosity.

Caution

Reader has no safety check to guarantee that pf is from the same event.

source