API Overview
ObsPy’s functionality is provided through the following packages.
General Packages
This section lists the core package that ties everything together as well as other general packages and packages that don’t fit it any of the other categories.
obspy.core - Core classes of ObsPy |
|
obspy.geodetics - Various geodetic utilities for ObsPy |
|
obspy.imaging - Plotting routines for ObsPy This module provides routines for plotting and displaying often used in seismology. It can currently plot waveform data, generate spectrograms and draw beachballs. The module obspy.imaging depends on the plotting module matplotlib. |
|
obspy.realtime - Real time support for ObsPy |
|
obspy.signal - Signal processing routines for ObsPy Capabilities include filtering, triggering, rotation, instrument correction and coordinate transformations. |
|
obspy.taup - Ray theoretical travel times and paths |
Scripts
All command-line scripts shipping with ObsPy.
Get the Flinn-Engdahl region name from longitude and latitude. |
|
A command-line program that runs all ObsPy tests. |
|
Restore REFTEK data from raw binary data dumps. |
|
Print stream information for waveform data in local files. |
|
Build a quality control HTML page. |
|
Scan a directory to determine the data availability. |
|
Simple script to plot waveforms in one or more files. |
|
MoPaD command line utility. |
|
A command-line tool to analyze Mini-SEED records. |
|
A command-line program that converts Dataless SEED into XML-SEED files. |
|
A command-line program that converts XML-SEED into Dataless SEED files. |
|
A command-line program that converts Dataless SEED into RESP files. |
Database or Web Service Access Clients
All ObsPy clients enabling remote and local access to data.
obspy.clients.earthworm - Earthworm Wave Server client for ObsPy. |
|
obspy.clients.fdsn - FDSN web service client for ObsPy The obspy.clients.fdsn package contains a client to access web servers that implement the FDSN web service definitions. |
|
obspy.clients.filesystem - Local filesystem (SDS or TSINDEX) client for ObsPy This package provides read support for some local directory structures. |
|
obspy.clients.iris - EarthScope (former IRIS) web service client for ObsPy The obspy.clients.iris package contains a client for the DMC Web services provided by EarthScope (former IRIS) (https://service.iris.edu/irisws/). |
|
obspy.clients.neic - CWB query module for ObsPy The obspy.clients.neic package contains a client for the NEIC CWB Query server. A public server is at 137.227.224.97 (cwbpub.cr.usgs.gov) on port 2061. |
|
obspy.clients.nrl - Nominal Response Library client for ObsPy |
|
obspy.clients.seedlink - SeedLink client for ObsPy |
|
obspy.clients.syngine - EarthScope/IRIS Syngine client for ObsPy |
Waveform Import/Export Plug-ins
Warning
In most cases these modules do not need to be called directly. They
register via the central ObsPy
read()
function - call this instead.
Usage Example:
import obspy
# Format will be detected automatically.
st = obspy.read("/path/to/file")
# Many formats can also be written out - just use the module name.
st.write("/path/to/outfile", format="mseed")
obspy.io.ah - AH (Ad Hoc) read support for ObsPy This module provides read support for the AH (Ad Hoc) waveform format introduced by the Lamont-Doherty Geological Observatory. |
|
obspy.io.alsep - Apollo seismic data support for ObsPy |
|
obspy.io.ascii - SLIST and TSPAIR support for ObsPy |
|
obspy.io.css - CSS read support for ObsPy This module provides read support for CSS waveform data. |
|
obspy.io.cybershake - CyberShake read support for ObsPy This module provides read support for the CyberShake waveform data format. |
|
obspy.io.dmc - INGV DMX file format reader for ObsPy |
|
obspy.io.gcf - Guralp Compressed Format, GCF, read and write support for ObsPy This module provides read and write support for GCF waveform data and header info acording to GCF Reference SWA-RFC-GCFR Issue F, December 2021 |
|
obspy.io.gse2 - GSE2/GSE1 and GSE2 bulletin support for ObsPy This module provides read and write support for GSE2 CM6 compressed as well as GSE1 CM6/INT waveform data and header info. Most methods are based on the C library GSE_UTI of Stefan Stange, which is interfaced via Python ctypes. |
|
obspy.io.kinemetrics - Evt format support for ObsPy |
|
obspy.io.mseed - MiniSEED read and write support for ObsPy This module provides read and write support for the MiniSEED (and the data part of full SEED) waveform data format and some other convenient methods to handle MiniSEED files. It utilizes libmseed, a C library by Chad Trabant. |
|
obspy.io.mseed3 - miniseed3 read and write support for ObsPy :2: (WARNING/2) Title underline too short. obspy.io.mseed3 - miniseed3 read and write support for ObsPy =================================================== This module provides read and write support for miniseed3-files as defined by the FDSN (http://docs.fdsn.org/projects/miniseed3/en/latest/). |
|
obspy.io.nied.knet - K-NET/KiK-net read support for ObsPy Reading of the K-NET and KiK-net ASCII format as defined on http://www.kyoshin.bosai.go.jp. |
|
obspy.io.pdas - PDAS file read support for ObsPy |
|
obspy.io.reftek - REFTEK130 read support for ObsPy |
|
obspy.io.rg16 - Receiver Gather v1.6 read support for ObsPy |
|
obspy.io.sac - SAC read and write support for ObsPy This module provides read and write support for ASCII and binary SAC-files as defined by EarthScope (https://ds.iris.edu/files/sac-manual/). |
|
obspy.io.seisan - SEISAN read support for ObsPy |
|
obspy.io.seg2 - SEG-2 read support for ObsPy |
|
obspy.io.segy - SEG Y and SU read and write support for ObsPy |
|
obspy.io.sh - Q and ASC read and write, EVT read support (Seismic Handler) |
|
obspy.io.wav - WAV (audio) read and write support for ObsPy |
|
obspy.io.win - WIN read support for ObsPy This module provides read support for WIN waveform data. This format is written by different dataloggers, including Hakusan LS-7000XT Datamark dataloggers. There are two subformats, A0 and A1. To our knowledge, A0 is the only one supported with the current code. A0 conforms to the data format of the WIN system developed by Earthquake Research Institute (ERI), the University of Tokyo. |
|
obspy.io.y - Nanometrics Y file read support for ObsPy |
Event Data Import/Export Plug-ins
Warning
In most cases these modules do not need to be called directly. They
register via the central ObsPy
read_events()
function - call this instead.
Usage Example:
import obspy
# Format will be detected automatically.
cat = obspy.read_events("/path/to/file")
# Many formats can also be written out - just use the module name.
cat.write("/path/to/outfile", format="quakeml")
obspy.io.cmtsolution - CMTSOLUTION file format support for ObsPy |
|
obspy.io.cnv - CNV file format support for ObsPy |
|
obspy.io.csv - CSV, CSZ and EVENTTXT read/write support for earthquake catalogs |
|
obspy.io.focmec - FOCMEC file format support for ObsPy |
|
obspy.io.gse2 - GSE2/GSE1 and GSE2 bulletin support for ObsPy This module provides read and write support for GSE2 CM6 compressed as well as GSE1 CM6/INT waveform data and header info. Most methods are based on the C library GSE_UTI of Stefan Stange, which is interfaced via Python ctypes. |
|
obspy.io.hypodd - HypoDD read support for ObsPy |
|
obspy.io.iaspei - Read support for IASPEI formats |
|
obspy.io.json - JSON write support for ObsPy |
|
obspy.io.kml - Keyhole Markup Language (KML) write support for ObsPy This module provides write support for the Keyhole Markup Language (KML) format. |
|
obspy.io.ndk - NDK file support for ObsPy |
|
obspy.io.nied.fnet - F-net moment tensor file read support for ObsPy F-net moment tensor file format support for ObsPy. |
|
obspy.io.nied.knet - K-NET/KiK-net read support for ObsPy Reading of the K-NET and KiK-net ASCII format as defined on http://www.kyoshin.bosai.go.jp. |
|
obspy.io.nlloc - NonLinLoc file format support for ObsPy |
|
obspy.io.nordic - Nordic file format support for ObsPy |
|
obspy.io.pde - NEIC PDE Bulletin read support for ObsPy |
|
obspy.io.quakeml - QuakeML read and write support for ObsPy |
|
obspy.io.scardec - SCARDEC file format support for ObsPy |
|
obspy.io.seiscomp - SeisComP XML inventory and event file support for ObsPy :2: (WARNING/2) Title underline too short. obspy.io.seiscomp - SeisComP XML inventory and event file support for ObsPy ======================================================================== |
|
obspy.io.shapefile - ESRI shapefile write support for ObsPy This module provides write support for the ESRI shapefile format. |
|
obspy.io.zmap - ZMAP read and write support for ObsPy |
Inventory Data Import/Export Plug-ins
Warning
In most cases these modules do not need to be called directly. They
register via the central ObsPy
read_inventory()
function -
call this instead.
Usage Example:
import obspy
# Format will be detected automatically.
inv = obspy.read_inventory("/path/to/file")
# Many formats can also be written out - just use the module name.
inv.write("/path/to/outfile", format="stationxml")
obspy.io.css - CSS read support for ObsPy This module provides read support for CSS waveform data. |
|
obspy.io.kml - Keyhole Markup Language (KML) write support for ObsPy This module provides write support for the Keyhole Markup Language (KML) format. |
|
obspy.io.sac.sacpz - SACPZ write support for ObsPy |
|
obspy.io.seiscomp - SeisComP XML inventory and event file support for ObsPy :2: (WARNING/2) Title underline too short. obspy.io.seiscomp - SeisComP XML inventory and event file support for ObsPy ======================================================================== |
|
obspy.io.shapefile - ESRI shapefile write support for ObsPy This module provides write support for the ESRI shapefile format. |
|
obspy.io.stationtxt - FDSNWS station text file read and write support for ObsPy |
|
obspy.io.stationxml - StationXML read and write support for ObsPy |
|
obspy.io.xseed - (X)SEED and RESP support for ObsPy XML-SEED was introduced by Tsuboi, Tromp and Komatitsch (2004), it is a XML representation of Dataless SEED. This module contains converters from Dataless SEED to XML-SEED and vice versa as well as a converter from Dataless SEED to RESP files. The xseed module is tested against the complete ORFEUS Dataless SEED archive, the EarthScope/IRIS (US) Dataless SEED archive and against ArcLink response requests. |