Skip to content

StationXML Management

The daemon automatically generates and maintains a StationXML file (station.xml). This file is the “passport” for your seismic data, containing the metadata required to convert raw ADC counts into physical ground motion (velocity, displacement, or acceleration).

  1. Instrument Deconvolution: Allows software like ObsPy to “undo” the effects of the geophone, amplifier, and ADC.
  2. FDSN Compliance: Metadata is formatted to the international standard for seismic data exchange.

Every time the daemon starts, it calculates a SHA-256 fingerprint of your hardware settings (gain, sensitivity, sample rate, etc.). This is stored in station.xml.sha256.

  • Included in Fingerprint: network, station, sampling_rate, adc_gain, vref, and all channel-specific physical constants.
  • Excluded: Job settings like trigger thresholds or notification URLs (as these don’t affect the raw data values).

An Epoch is a period where the instrument response remains constant. If you swap a geophone or change the analog gain, you must signal the start of a new epoch.

  1. Change Detected: You modify a hardware setting (e.g., analog_gain) in config.yml.
  2. Validation: The daemon compares the new settings against the stored fingerprint.
  3. The start_date Check:
    • If start_date is unchanged: The daemon raises a StationXMLEpochError and refuses to start. This prevents corrupting your existing metadata.
    • If start_date is updated: The daemon closes the current epoch in station.xml (setting the EndDate) and appends a new epoch starting at your new date.

The daemon calculates the total system sensitivity by combining three distinct hardware stages.

Physics: Pole-Zero (LAPLACE) Computed using natural_frequency and damping.

Calculates the conversion from Ground Motion (m/s) to Voltage (V).

The final <InstrumentSensitivity> value is the product of all three stages. For a standard GD-4.5 setup, this is typically in the range of ~620,307,472,640 counts/(m/s).


You can easily remove the instrument effect to get real-world velocity:

from obspy import read, read_inventory
st = read("data/archive/2026/XX/RPI3/EHZ.D/...")
inv = read_inventory("station.xml")
# Convert raw counts to Velocity (m/s)
st.remove_response(inventory=inv, output="VEL")