Utilities¶
General utilities
pytomo.utilities
- pytomo.utilities.get_temporary_str() → str¶
To use to name temporary files or folders
- pytomo.utilities.minimum_nspc(tlen: float, freq2: float) → int¶
Find the minimum nspc for accurate computation given freq2.
- Parameters
tlen – length of synthetics in seconds
freq2 – the maximum filtering frequency in Hz
- Returns
- the minimum number of frequency point for computation
of accurate synthetics
- Return type
int
- pytomo.utilities.minimum_tlen(windows) → float¶
Find the minimum tlen that includes the longest time window.
- Parameters
windows (list of Window) – time windows
- Returns
the minimum length for synthetics in seconds
- Return type
float
- pytomo.utilities.white_noise(std, size) → numpy.ndarray¶
Compute random gaussian noise