openquake.hmtk.seismicity.smoothing.kernels package

Submodules

openquake.hmtk.seismicity.smoothing.kernels.base module

Module openquake.hmtk.seismicity.smoothing.kernels.base implements the abstract base class for the smoothing kernels

class openquake.hmtk.seismicity.smoothing.kernels.base.BaseSmoothingKernel[source]

Bases: object

Abstract Base Class to smooth a grid according the sets of regular smoothing kernels

abstract smooth_data(data, config)[source]

Applies the smoothing Kernel

Parameters
  • data (numpy.ndarray) – Earthquake grid counts in the form [Longitude, Latitude, Depth, Count] where Longitude, Latitude and Depth correspond to the mid-points of each cell!

  • config (dict) – Algorithm configuration parameters

openquake.hmtk.seismicity.smoothing.kernels.isotropic_gaussian module

Module openquake.hmtk.seismicity.smoothing.kernels.isotropic_gaussian imports openquake.hmtk.seismicity.smoothing.kernels.isotropic_gaussian.IsotropicGaussian the simple isotropic Gaussian smoothing kernel as described by Frankel (1995)

Frankel, A. (1995) Mapping Seismic Hazard in the Central and Eastern United States. Seismological Research Letters. 66(4) 8 - 21

class openquake.hmtk.seismicity.smoothing.kernels.isotropic_gaussian.IsotropicGaussian[source]

Bases: openquake.hmtk.seismicity.smoothing.kernels.base.BaseSmoothingKernel

Applies a simple isotropic Gaussian smoothing using an Isotropic Gaussian Kernel - taken from Frankel (1995) approach

smooth_data(data, config, is_3d=False)[source]

Applies the smoothing kernel to the data

Parameters
  • data (np.ndarray) –

    Raw earthquake count in the form [Longitude, Latitude, Depth,

    Count]

  • config (dict) – Configuration parameters must contain: * BandWidth: The bandwidth of the kernel (in km) (float) * Length_Limit: Maximum number of standard deviations

Returns

  • smoothed_value: np.ndarray vector of smoothed values

  • Total (summed) rate of the original values

  • Total (summed) rate of the smoothed values

Module contents