fosanalysis
A framework to evaluate distributed fiber optic sensor data
Loading...
Searching...
No Matches
fosanalysis.preprocessing.masking.ModifiedZscoreDetection Class Reference

Class for the modified z-score approach for spike detection. More...

Inheritance diagram for fosanalysis.preprocessing.masking.ModifiedZscoreDetection:

Protected Member Functions

np.array _get_z_score (self, np.array z)
 Calculates the modified z-score of the given strain array.
 
- Protected Member Functions inherited from fosanalysis.preprocessing.masking.ZSOD
np.array _get_outlier_mask (self, np.array z_score)
 Mask entries as SRA, whose z-scores exceed threshold.
 
tuple _run_1d (self, np.array x, np.array z, np.array SRA_array, *args, **kwargs)
 Estimate which entries are strain reading anomalies in 1D.
 
tuple _run_2d (self, np.array x, np.array y, np.array z, np.array SRA_array, *args, **kwargs)
 Estimate which entries are strain reading anomalies in 2D.
 
- Protected Member Functions inherited from fosanalysis.preprocessing.masking.AnomalyMasker
tuple _map_2d (self, np.array x, np.array y, np.array z, np.array SRA_array, str timespace=None, *args, **kwargs)
 Estimate, which entries are strain reading anomalies, in 2D.
 

Additional Inherited Members

- Public Member Functions inherited from fosanalysis.preprocessing.masking.ZSOD
 __init__ (self, float threshold=3.5, str timespace="1d_space", *args, **kwargs)
 Construct an instance of the class.
 
- Public Member Functions inherited from fosanalysis.preprocessing.masking.AnomalyMasker
np.array run (self, np.array x, np.array y, np.array z, bool make_copy=True, str timespace=None, bool identify_only=False, *args, **kwargs)
 Mask strain reading anomalies with NaNs.
 
- Public Member Functions inherited from fosanalysis.utils.base.Task
 __init__ (self, *args, **kwargs)
 
- Public Member Functions inherited from fosanalysis.utils.base.Base
 __init__ (self, *args, **kwargs)
 Construct the object and warn about unused/unknown arguments.
 
- Public Attributes inherited from fosanalysis.preprocessing.masking.ZSOD
 threshold = threshold
 Relative height threshold above which a pixel is flagged as SRA.
 

Detailed Description

Class for the modified z-score approach for spike detection.

This method uses the median and the median absolute deviation rather than the mean and standard deviation. The multiplier 0.6745 is the 0.75th quantile of the standard normal distribution. Disadvantage: Peaks can also detect as strain reading anomaly. See [4].

Definition at line 663 of file masking.py.

Member Function Documentation

◆ _get_z_score()

np.array fosanalysis.preprocessing.masking.ModifiedZscoreDetection._get_z_score ( self,
np.array z )
protected

Calculates the modified z-score of the given strain array.

Parameters
zArray containing strain data.
Returns
Returns an array modified z-score.

Reimplemented from fosanalysis.preprocessing.masking.ZSOD.

Definition at line 672 of file masking.py.


The documentation for this class was generated from the following file: