sbi icon indicating copy to clipboard operation
sbi copied to clipboard

Adapt MNLE to new DensityEstimator abstraction

Open janfb opened this issue 1 year ago • 0 comments

Problem

MNLE is a variant of NLE, tailored to cases where x is discrete and continuous. It has its down density estimator, MixedDensityEstimator living here:

https://github.com/sbi-dev/sbi/blob/main/sbi/neural_nets/mnle.py

It would be nice to add MNLE to the new DensityEstimator abstraction, see #966 and #957. Otherwise we would need to handle it differently in the Posterior classes.

Solution

Let MixedDensityEstimator inherit from DensityEstimator and maybe move it to the designated module. The CategoricalNet is also a density (or rather mass) estimator. So it should be treated similarly.

janfb avatar Feb 29 '24 12:02 janfb