obspy.io.xseed.parser.Parser

class Parser(data=None, debug=False, strict=False, compact=False)[source]

Bases: builtins.object

The XML-SEED parser class parses dataless or full SEED volumes.

See also

The SEED file format description can be found at https://www.fdsn.org/seed_manual/SEEDManual_V2.4.pdf .

The XML-SEED format was proposed in [Tsuboi2004].

Attributes

__dict__
__doc__ str(object=’‘) -> str
__module__ str(object=’‘) -> str
__weakref__ list of weak references to the object (if defined)

Public Methods

getCoordinates
getInventory
getPAZ
getRESP
getSEED
getXSEED
get_coordinates Return Coordinates (from blockette 52)
get_inventory Function returning a dictionary about whats actually in the Parser
get_paz Return PAZ.
get_resp Returns a RESP representation of the current Parser object.
get_seed Returns a SEED representation of the current Parser object.
get_xseed Returns a XSEED representation of the current Parser object.
read General parser method for XML-SEED and Dataless SEED files.
rotateToZNE DEPRECATED: ‘rotateToZNE’ has been renamed to
rotate_to_zne Rotates the three components of a Stream to ZNE.
writeRESP
writeSEED
writeXSEED
write_resp Writes for each channel a RESP file within a given folder.
write_seed Writes a dataless SEED file with given name.
write_xseed Writes a XML-SEED file with given name.

Private Methods

Warning

Private methods are mainly for internal/developer use and their API might change without notice.

_check_blockettes Checks if all blockettes necessary for creating a SEED String are
_compare_blockettes Compares two blockettes.
_create_blockettes_11_and_12 Creates blockettes 11 and 12 for SEED writing and XSEED version 1.1
_create_cut_and_flush_record Takes all blockettes of a record and return a list of finished records.
_delete_blockettes_11_and_12 Deletes blockette 11 and 12.
_get_abbreviation Helper function returning the abbreviation for the given identifier
_get_resp_string Takes a file like object and a list of blockettes containing all
_parse_merged_data This method takes any merged SEED record and writes its blockettes
_parse_seed Parses through a whole SEED volume.
_parse_xml_blockette Takes the lxml tree of any blockette and returns a blockette object.
_parse_xseed Parse a XML-SEED string.
_repr_pretty_
_select Selects all blockettes related to given SEED id and datetime.
_update_internal_seed_structure Takes everything in the self.temp dictionary and writes it into the volume, abbreviations and stations attributes of the class.
_update_temporary_stations Loops over all stations, finds the corresponding blockettes and changes

Special Methods

__dir__ default dir() implementation
__format__ default object formatter
__init__ Initializes the SEED parser.
__new__ Create and return a new object.
__reduce__ helper for pickle
__reduce_ex__ helper for pickle
__sizeof__ size of object in memory, in bytes
__str__
__subclasshook__ Abstract classes can override this to customize issubclass().