sources
The module majorly mimics source classes from pyrocko.gf.seismosizer.
They might ship additional information on the misfit as it would be derived from
an inversion.
siria.sources.SiriaIDSSTF, siria.sources.SiriaIDSPatch and siria.sources.SiriaIDSSource are standalone and provide standardized loading of results compile with IDS.
- class SiriaSourceWithMagnitude(**kwargs)[source]
Simple point source characterized by location and magnitude
- misfit
float, optional, default:0.0Misfit value of the source.
- probability
float, optional, default:0.0Probability of the occurence of the source.
- class SiriaDCSource(**kwargs)[source]
Double couple point source
- misfit
float, optional, default:0.0Misfit value of the source.
- probability
float, optional, default:0.0Probability of the occurence of the source.
- class SiriaMTSource(**kwargs)[source]
Full moment tensor (MT) point source
- strike1
float, optionalStrike of the primary nodal plane.
- dip1
float, optionalDip of the primary nodal plane.
- rake1
float, optionalRake of the primary nodal plane.
- strike2
float, optionalStrike of the secondary nodal plane.
- dip2
float, optionalDip of the secondary nodal plane.
- rake2
float, optionalRake of the secondary nodal plane.
- misfit
float, optional, default:0.0Misfit value of the source.
- probability
float, optional, default:0.0Probability of the occurence of the source.
- base_key()[source]
Get key to decide about source discretization / GF stack sharing.
When two source models differ only in amplitude and origin time, the discretization and the GF stacking can be done only once for a unit amplitude and a zero origin time and the amplitude and origin times of the seismograms can be applied during post-processing of the synthetic seismogram.
For any derived parameterized source model, this method is called to decide if discretization and stacking of the source should be shared. When two source models return an equal vector of values discretization is shared.
- class SiriaRectangularSource(**kwargs)[source]
Rectangular source model (Heimann, 2011)
Simplified constant slip rectangular fault model.
- misfit
float, optional, default:0.0Misfit value of the source.
- probability
float, optional, default:0.0Probability of the occurence of the source.
- class SiriaIDSSource(patches=None, stf=None, moment=None, magnitude=None, misfit_log=None, **kwargs)[source]
Container for IDS finite fault model results (all subfaults/patches)
- name
str, optional, default:''Name of the source/corresponding event
- patches
listofSiriaIDSPatchobjects, optionalList of all sub faults/fault patches. All patches need to have the same starttime and sampling interval of their source time function (if given).
- nucleation_x
float, optionalHorizontal position of rupture nucleation in normalized fault plane coordinates (-1 = left edge, +1 = right edge).
- nucleation_y
float, optionalDown-dip position of rupture nucleation in normalized fault plane coordinates (-1 = upper edge, +1 = lower edge).
- centroid_x
float, optionalHorizontal position of rupture centroid in normalized fault plane coordinates (-1 = left edge, +1 = right edge).
- centroid_y
float, optionalDown-dip position of rupture centroid in normalized fault plane coordinates (-1 = upper edge, +1 = lower edge).
- nx
int, optionalNumber of patches along strike.
- ny
int, optionalNumber of patches down dip.
- velocity
float, optional, default:3500.0Average speed of rupture front [m/s].
- misfit_log
SiriaIDSLog, optionalCompressed misfit and logging information of the IDS run.
- probability
float, optional, default:0.0Probability of the occurence of the source.
- curved
bool, default:FalseIf True, fault patches do not need to be aligned within a rectangular source plane. Location, geometry and depth might bemisleading and erroerous then.
- property misfit
Final misfit value (normalized residual variance) of the source.
- class SiriaPseudoDynamicRupture(**kwargs)[source]
Eikonal quasi dynamic rupture model (Dahm et al., 2020)
- misfit
float, optional, default:0.0Misfit value of the source.
- probability
float, optional, default:0.0Probability of the occurence of the source.
- class SiriaIDSPatch(stf=None, moment=None, magnitude=None, **kwargs)[source]
Container for IDS subfault / patch results
- time
pyrocko.util.get_time_float (
pyrocko.guts.Timestamp), optionalRupture front arrival/rupture origin time
- magnitude
float, optionalMoment magnitude Mw as in [Hanks and Kanamori, 1979].
- moment
float, optionalSeismic moment M0 in [Nm].
- stf
SiriaIDSSTF, optionalSource time function (moment release) of the patch in [Nm/s].
- slip
float, optionalLength of the slip vector in [m].
- strike
float, default:0.0Strike direction in [deg], measured clockwise from north.
- dip
float, default:90.0Dip angle in [deg], measured downward from horizontal.
- rake
float, default:0.0Rake angle in [deg], measured counter-clockwise from right-horizontal in on-plane view.
- length
float, default:0.0Length of rectangular source area [m].
- width
float, default:0.0Width of rectangular source area [m].
- x_coordinate
float, optionalCoordinate along strike relative to the source anchor in [m].
- y_coordinate
float, optionalCoordinate down dip relative to the source anchor in [m].
- anchor
str(pyrocko.guts.StringChoice), optional, default:'center'Anchor point for positioning the plane, can be: top, center orbottom and also top_left, top_right, bottom_left,bottom_right, center_left and center_right.
- property slip_function
BETA version Scale final slip using the cumulative moment function
- class SiriaIDSSTF(**kwargs)[source]
Source time function (moment rate) of an IDSSource (or IDSPatch)
- deltat
float, default:1.0Sampling interval in [s] of the source time function.
- t_min
float, default:0.0Time of first stf sample relative to the origin time of the source in [s].
- amplitudes
numpy.ndarray (
pyrocko.guts_array.Array), default:array([0.])Source time function (moment rate) in [Nm/s]. Describes the moment release.
- property n_samples
Number of amplitude samples
- property times
Time of the amplitudes samples based on t_min and n_samples
- property cumulative_moment_function
Convert moment rate amplitudes to cumulative moment (time)
- Returns
cumulative seismic moment in [Nm] per time interval between t_min and t_min + deltat * (n_samples - 1)
- Return type
numpy.ndarray, shape(n_samples,)
- property moment
Convert moment rate amplitudes to cumulative total seismic moment
- Returns
final total seismic moment in [Nm]
- Return type
- property magnitude
Convert moment rate amplitudes to moment magnitude Mw
- Returns
moment magnitude Mw
- Return type
- class SourceHeader(source_class=None, **kwargs)[source]
Gather for all guts property help strings of a source class
- help_string
str, optional, default:''Help string for the source class
- set_help_string(source_class)[source]
Gather the property helps for a source class in self.help_string
- Parameters
source_class (
siria.sources.SiriaSourceWithMagnitudeorsiria.sources.SiriaDCSourceorsiria.sources.SiriaMTSourceorsiria.sources.SiriaRectangularSourceorsiria.sources.SiriaPseudoDynamicRuptureorsiria.sources.SiriaIDSSource) – source class object which help functions are gathered in the help string
- dump_sources(sources, dump_header=True, header=None, **kwargs)[source]
Dump source list with preceding header to source ensemble yaml file
- Parameters
sources (list of
siria.sources.SiriaSourceWithMagnitudeorsiria.sources.SiriaDCSourceorsiria.sources.SiriaMTSourceorsiria.sources.SiriaRectangularSourceorsiria.sources.SiriaPseudoDynamicRuptureorsiria.sources.SiriaIDSSource) – list of sources to be dumpeddump_header (optional, boolean) – If a header (
siria.sources.SourceHeader) is dumped preceding the sources (True) or not (False). If header is not given, it gets automatically generated based on the first element of the sources list.header (optional,
siria.sources.SourceHeader) – If given, this header is used instead of an automatically generated one.
keyword arguments for
pyrocko.guts.dump_all()as filename
- dump_sources_xml(sources, dump_header=True, header=None, **kwargs)[source]
Dump source list with preceding header to source ensemble xml file
- Parameters
sources (list of
siria.sources.SiriaSourceWithMagnitudeorsiria.sources.SiriaDCSourceorsiria.sources.SiriaMTSourceorsiria.sources.SiriaRectangularSourceorsiria.sources.SiriaPseudoDynamicRuptureorsiria.sources.SiriaIDSSource) – list of sources to be dumpeddump_header (optional, boolean) – If a header (
siria.sources.SourceHeader) is dumped preceding the sources (True) or not (False). If header is not given, it gets automatically generated based on the first element of the sources list.header (optional,
siria.sources.SourceHeader) – If given, this header is used instead of an automatically generated one.
keyword arguments for
pyrocko.guts.dump_all()as filename
- load_sources(load_header=False, **kwargs)[source]
Load source ensemble yaml file with optional preceding header object
- Parameters
load_header (optional, boolean) – If a header (
siria.sources.SourceHeader) exists, return it (True) or not (False)
keyword arguments for
pyrocko.guts.load_all()as filename- Returns
the source header with the help string (optional) and a list of sources
- Return type
siria.sources.SourceHeader(optional) and list ofsiria.sources.SiriaSourceWithMagnitudeorsiria.sources.SiriaDCSourceorsiria.sources.SiriaMTSourceorsiria.sources.SiriaRectangularSourceorsiria.sources.SiriaPseudoDynamicRuptureorsiria.sources.SiriaIDSSource
- load_sources_xml(load_header=False, **kwargs)[source]
Load source ensemble xml file with optional preceding header object
- Parameters
load_header (optional, boolean) – If a header (
siria.sources.SourceHeader) exists, return it (True) or not (False)
keyword arguments for
pyrocko.guts.load_all_xml()as filename- Returns
the source header with the help string (optional) and a list of sources
- Return type
siria.sources.SourceHeader(optional) and list ofSiriaSourceWithMagnitudeorSiriaDCSourceorSiriaMTSourceorSiriaRectangularSourceorSiriaPseudoDynamicRuptureorSiriaIDSSource