mt_metadata.timeseries.tools.from_many_mt_files
Created on Thu Oct 7 16:31:55 2021
@author: jpeacock
Classes
A class to convert multiple MT xml files into a stationXML (MTML) |
Module Contents
- class mt_metadata.timeseries.tools.from_many_mt_files.MT2StationXML(xml_path=None)
Bases:
mt_metadata.timeseries.stationxml.XMLInventoryMTExperimentA class to convert multiple MT xml files into a stationXML (MTML)
This is for a use case of A. Kelbert who places each level of metadata into a single XML file. This class collects all those files and puts them into the proper order.
She has the files named as follows
survey.xml –> Survey metadata mt_metadata.timeseries.Survey filters.xml –> All filters station.xml –> Station metadata mt_metadata.timeseries.Station station.run.xml –> Run metadata mt_metadata.timeseries.Run station.run.channel.xml –> Channel metadata mt_metadata.timeseries.Channel
- property xml_path
- has_xml_path()
- static is_a_filter_xml(fn)
- static is_a_survey_xml(fn)
- static is_a_station_xml(fn)
- static is_a_run_xml(fn)
- static is_a_channel_xml(fn)
- get_xml_files()
Get all mtml xml files for a given station.
- make_df()
Make a pandas data frame for easier querying
- Returns:
DESCRIPTION
- Return type:
TYPE
- property stations
- property survey
- property filters
- sort_by_station(stations=None)
sort the file into station, runs and channels
- Returns:
DESCRIPTION
- Return type:
TYPE
- static read_xml_file(xml_file)
read an xml file an return an xml element
- Parameters:
xml_file (TYPE) – DESCRIPTION
- Returns:
DESCRIPTION
- Return type:
TYPE
- make_experiment(stations=None)
Create an MTML experiment from the a directory of xml files :return: DESCRIPTION :rtype: TYPE
- get_mt_channel(ch_fn, filters_fn)
have a look at an mt channel