API Reference

Classes

AbstractArray()

Abstract class for Matrix and Vector.

Action([base])

Allows for delayed method calls

Ensemble([raw, bg, bg_ratio, path])

Generates perturbated matrices to estimate uncertainty

EnsembleNormalizer(*, extractor[, …])

Normalizes NLD nad γSF extracted from the ensemble

Extractor([ensemble, trapezoid, path])

Extracts nld and γSF from an Ensemble or a Matrix

FirstGeneration()

First generation method from Guttormsen et al.

Matrix([values, Eg, Ex, std, path, shape, state])

Stores 2d array with energy axes (a matrix).

Model(name[, _Model__isfrozen])

Dataclass for Model

NormalizationParameters(name[, …])

Storage for normalization parameters + some convenience functions

NormalizerGSF(*[, normalizer_nld, nld, …])

Normalize γSF to a given` <Γγ> (Gg)

NormalizerNLD(*[, nld, discrete, path, …])

Normalizes NLD to empirical data

NormalizerSimultan(*[, gsf, nld, …])

Simultaneous normalization of nld and gsf.

Response(path)

Interpolates response read from file for current setup

ResultsNormalized(name[, _Model__isfrozen, …])

Class to store the results of the Oslo Method

SpinFunctions(Ex, J, model, pars)

Calculates spin distributions, spin cuts (…)

Unfolder([num_iter, response])

Performs Guttormsen unfolding

Vector([values, E, path, std, units])

Stores 1d array with energy axes (a vector)

Functions

div0(a, b)

division function designed to ignore / 0, i.e.

example_raw(name)

Load example raw data.

fill_negative(matrix, window_size)

Fill negative channels with positive counts from neighbouring channels

gauss_smoothing(double[, double[, double[, …)

Function which smooths an array of counts by a Gaussian of full-width-half-maximum FWHM.

gauss_smoothing_matrix_1D(matrix_in, …[, axis])

Smooth a matrix with a Gaussian

gaussian(double[, double mu, double sigma)

Returns a normalized Gaussian supported on Emids.

index(double[, double element)

Finds the index of the closest element in the array

list_examples()

List examples

load_levels_discrete(path, energy)

Load discrete levels without smoothing

load_levels_smooth(path, energy[, resolution])

Load discrete levels with smoothing

nld_T_product(double[, double[, double[, …)

Computes first generation matrix from nld and gSF

normalize_rows(array)

Normalize each row to unity

rebin_1D(double[, double[, double[)

Rebin an array of counts from binning mids_in to binning mids_out

rebin_2D(double[, , double[, double[, int axis=0)

Rebin a matrix of counts from binning mids_in to binning mids_out

to_plot_axis(axis)

Maps axis to 0, 1 or 2 according to which axis is specified

Variables

Todo

More beautiful way of excluding imported classes/variables.