PYME.Analysis.cramerRao module

tools for estimating the Fisher information matrix and Cramer-Rao lower bound


Calculate the Cramer-Rao bound for a given Fisher information matrix


FI : array

an NparamsxNparams Fisher information matrix


an array of lower bounds on variances (NB the CRLB is given as a variance, rather than std. deviation).


CRB is the diagonal elements of the inverse of the Fisher information matrix

PYME.Analysis.cramerRao.CalcFisherInfoModel(params, param_delta, modelFunc, modelargs=())

Calculate the Cramer-Rao bound under Poisson noise for a given model function (at a given point), using a numerical derivative.


params : array / list

The parameters

param_delta : array / list

The amount to add to the parameters when calculating the numerical gradient

modelFunc : function

A function describing the model. The output should be calibrated in photo-electrons

modelargs : iterable

A list of additional arguments to pass to the model function


The NparamsxNparams Fisher information matrix

PYME.Analysis.cramerRao.CalcFisherInform2D(lam, voxelsize=[1, 1])

Calculate the Fisher Information of a 2D model


lam : ndarray

model mean value in photoelectrons before Poisson noise process

voxelsize : iterable

pixel dimensions of model in nm


a 2x2 Fisher information matrix

PYME.Analysis.cramerRao.CalcFisherInformZ(lam, maxK=500, voxelsize=[1, 1, 1])
PYME.Analysis.cramerRao.CalcFisherInformZn(lam, maxK=500, voxelsize=[1, 1, 1])
PYME.Analysis.cramerRao.CalcFisherInformZn2(lam, maxK=500, voxelsize=[1, 1, 1])
PYME.Analysis.cramerRao.FIkz(lam, k, voxelsize)
PYME.Analysis.cramerRao.lp_poisson(lam, k)

log of poisson likelihood fcn

PYME.Analysis.cramerRao.lp_poisson_n(lam, k)

log of poisson likelihood fcn

PYME.Analysis.cramerRao.p_poisson(lam, k)

poisson likelihood fcn - calculated from log lhood for numerical stability