nessai.utils
General utilities for nessai.
Submodules
Package Contents
Classes
|
Class to encode numpy arrays and other non-serialisable objects. |
Functions
|
Return a Pytorch distribution that is normally distributed in n dims |
|
Return a torch distribution that is uniform in the number of dims |
|
Compute the number bins for a histogram using numpy.histogram_bin_edges |
|
Apply the Bonferroni correction for multiple tests. |
|
Compute the two-sided KS test for discrete insertion indices for a given |
|
Check if an object is JSON serialisable. |
|
Safely dump data to a .pickle file. |
|
Save live points to a file using JSON. |
|
Setup the logger. |
|
Configure parameters for edge detection |
|
Detect edges in input distributions based on the density. |
|
Determine the values of the prior min and max in the rescaled |
|
Rescale from -1 to 1 to xmin to xmax |
|
Rescale from 0 to 1 to xmin to xmax |
|
Logit function that also returns log Jacobian determinant. |
|
Rescale a value to -1 to 1 |
|
Rescale a value to 0 to 1 |
|
Sigmoid function that also returns log Jacobian determinant. |
|
Compute the radius that contains a fraction of the total probability in an n-dimensional unit Gaussian. |
|
Wrapper for numpy.random.randn that deals with extra input parameters |
|
Draw N points uniformly within an n-sphere of radius r |
|
Draw N points uniformly from n-1 sphere of radius r using Marsaglia's |
|
Draw N points from a truncated gaussian with a given a radius |
|
Draw from a uniform distribution on [0, 1]. |
|
Compute the distance to the nearest neighbour of each sample |
|
Compute the rolling mean with a given window size. |
|
Replace (in place) an entry in a list with a given element. |
|
Configure the number of threads available. |
Attributes
|