mttime.core.configure.Configure¶
-
class
Configure
(path_to_file=None, df=None, **kwargs)[source]¶ Bases:
object
Configure object for
Inversion
Sets up the moment tensor inverse routine.
**kwargs
can be provided either inpath_to_file
or during class instantiation.df
anddepth
are required if not reading from a file.**kwargs
will override the values inpath_to_file
and any missing keyword arguments will be set to their default values.- Parameters
path_to_file (str) – path to input file containing headers and station information. Input file should be located in the project root directory.
df (
DataFrame
) – station table, required ifpath_to_file=None
.datetime (str, optional) – event origin time.
longitude (float, optional) – event longitude.
latitude (float, optional) – event latitude.
depth (float, int, list) – source depths to invert, required if
path_to_file=None
path_to_data (str) – path to data files, relative to root directory. Defaults is
"."
.path_to_green (str) – path to Green’s function files, relative to root directory. Default is
"."
.green (str) – Green’s function format, options are
"herrmann"
or"tensor"
. Default is"herrmann"
.components (str) – waveform components, options are
"Z"
for vertical component, or"ZRT"
for three-component data in vertical, radial and transverse components, and"ZNE"
for vertical, north and east. Default is"ZRT"
.degree (int) – degrees of freedom allowed in the inversion, options are
5
for deviatoric or6
for full. Default is5
.weight (str) – data weights, options are
"none"
,"distance"
or"variance"
for no weights, inverse distance, or inverse variance, respectively. Default is"none"
.plot (int, bool) – If
True
will plot the solution and waveform fits. Default isFalse
.correlate (int, bool) – Flag to cross-correlate data and Green’s functions for best time shift (in time points). Default is
False
.
Methods
Function to write inversion configuration to a file