reboost.math package¶
Submodules¶
reboost.math.functions module¶
- reboost.math.functions.piecewise_linear_activeness(distances, fccd, tl)¶
Piecewise linear HPGe activeness model.
Based on:
\[\begin{split}f(d) = \begin{cases} 0 & \text{if } d < t, \\ \frac{x-l}{f - l} & \text{if } t \leq d < f, \\ 1 & \text{otherwise.} \end{cases}\end{split}\]Where: - d: Distance to surface, - l: Depth of transition layer start - f: Full charge collection depth (FCCD).
In addition, any distance of np.nan (for example if the calculation was not performed for some steps) is assigned an activeness of one.
- Parameters:
distances (VectorOfVectors | Array) – the distance from each step to the detector surface. Can be either a numpy or awkward array, or a LGDO VectorOfVectors or Array. The computation is performed for each element and the shape preserved in the output.
fccd (float) – the value of the FCCD
tl (float) – the start of the transition layer.
- Returns:
a
VectorOfVectorsorArrayof the activeness- Return type:
reboost.math.stats module¶
- reboost.math.stats.gaussian_sample(mu, sigma, *, seed=999)¶
Generate samples from a gaussian.
Based on:
\[y_i \sim \mathcal{N}(\mu_i,\sigma_i)\]where $y_i$ is the output, $x_i$ the input (mu) and $sigma$ is the standard deviation for each point.
- Parameters:
mu (_SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | bool | int | float | complex | str | bytes | _NestedSequence[bool | int | float | complex | str | bytes]) – the mean positions to sample from, should be a flat (ArrayLike) object.
sigma (_SupportsArray[dtype[Any]] | _NestedSequence[_SupportsArray[dtype[Any]]] | bool | int | float | complex | str | bytes | _NestedSequence[bool | int | float | complex | str | bytes]) – the standard deviation for each input value, can also be a single float.
seed (int) – the random seed.
- Returns:
sampled values.
- Return type: