As outlined in more detail in issue #38 the flows in clusterMAF were incorrectly weighted in __call__ and not weighted in log_prob. These led to incorrect sampling distributions and erroneous $D_{\rm KL}$ values respectively. This PR fixes #38 by now weighting the flows in both of these contexts in proportion to the sample weights in the corresponding clusters.
Additional minor changes:
Minor version bump
Casting of some inputs to tf.float32 when required to avoid type comparison errors
Set n_init to 10 explicitly to stop deprecation warning from scikit
Copying of some inputs to avoid unintended side effects
Check no samples are outside prior ranges if set, discard and warn if any are
As outlined in more detail in issue #38 the flows in
clusterMAF
were incorrectly weighted in__call__
and not weighted inlog_prob
. These led to incorrect sampling distributions and erroneous $D_{\rm KL}$ values respectively. This PR fixes #38 by now weighting the flows in both of these contexts in proportion to the sample weights in the corresponding clusters.Additional minor changes: