obsinfo.subnetwork package
Contains the main classes from Subnetwork to Station
Subnetwork class
- class obsinfo.subnetwork.Subnetwork(attributes_dict=None, debug=False)
Bases:
objectEquivalent to obspy/StationXML Network
- comments
- Type:
list of str
- extras
- Type:
list of str
- add_extras_to_comments()
Convert info file extras to XML comments
- to_obspy()
Convert subnetwork object to obspy object
- Returns:
- class:~obspy.core.inventory.network.Network): corresponding
obspy Network
- Return type:
(
Network class
- class obsinfo.subnetwork.Network(attributes_dict=None)
Bases:
objectEquivalent to obspy/StationXML Network
- code
- Type:
str
- name
- Type:
str
- start_date
network start date
- Type:
str with date format
- end_date
network end date
- Type:
str with date format
- description
network description
- Type:
str
- comments
- Type:
list of str
- restricted_status
‘open’, ‘closed’, or ‘partial’
- Type:
str
- source_id
network-level data source identifier in URI format
- Type:
str
- identifiers
persistent identifiers as URIs, scheme (prefix) will be extracted
- Type:
list of str
- classmethod to_yaml(representer, data)
- yaml_tag = '!myYamlObjTag'
Station class
- class obsinfo.subnetwork.Station(code, attributes_dict, stations_operators=None, stations_comments=None, leapseconds=None)
Bases:
objectStation. Equivalent to obspy/StationXML Station
Methods convert info files to an instance of this class and convert the object to an obspy object.
- code
FDSN station code (maximum 5 letters)
- Type:
str
- site
Site name
- Type:
str
- start_date
station start date
- Type:
str with date format
- end_date
station end date
- Type:
str with date format
- location_code
the station’s location code (and default Location for its channels)
- Type:
str
- restricted_status
status of station
- Type:
str
- instrumentation (:class:`.Instrumentation` or list of
Instrumentation): instrumentation(s) used at this station
- comments
station-level comments, including comments generated from extras and processing
- Type:
- source_id
StationXML sourceID (URI format)
- Type:
str
- identifiers
(list of str): permanent identifiers (URI format)
- external_references
external references, each one is a dict with keys [‘uri’, ‘description’]
- Type:
list of dict
- water_level
elevation (m) of water surface (useful for lakes)
- Type:
number
- to_obspy()
Convert station object to obspy object
- Returns:
corresponding obspy Station object
- Return type:
(
obspy.core.inventory.station.Station)
Stations class
- class obsinfo.subnetwork.Stations(stations_dict, operators, comments, leapseconds=None)
Bases:
ObsinfoClassListA list of Station objects
Operator class
- class obsinfo.subnetwork.Operator(attributes_dict)
Bases:
objectContact information for the operator of the instrumentation or network
- agency
Reference name of agency
- Type:
str
- contacts
- Type:
Persons
- website
operator website
- Type:
str
- to_obspy()
- classmethod to_yaml(representer, data)
- yaml_tag = '!myYamlObjTag'
Operators class
- class obsinfo.subnetwork.Operators(seq)
Bases:
ObsinfoClassListA list of Operator objects
- classmethod to_yaml(representer, data)
- yaml_tag = '!myYamlSeqTag'
Site class
Processing class
- class obsinfo.subnetwork.Processing(attributes, leapseconds=None)
Bases:
objectNo equivalent class in obspy/StationXML
Saves a list of Processing steps as strings For now, just stores the list. Will be converted to StationXML comments
- processing_list
list of processing steps with attributes, either linear_drift or leapsecond
- Type:
list