Need some clarity on samples drawn in Bayesian inversion problem

Hi @Shihab_Khan

I can confirm that what @olaf.klein wrote is true entirely. As he correctly pointed out, there is only a slight difference when using N_{\mathrm{gr}} data groups: In this case, the structures .PriorPredSample and .PostPredSample are structure arrays with N_{\mathrm{gr}} structures corresponding to the predictive distributions.

While reviewing this, I realized that the naming of .PriorPredSample and .PostPredSample fields (i.e., Prior and PriorPred, Post and PostPred) is not ideal. In the next version of the module, these names will therefore be updated. For .PriorPredSample I suggest the field names .Sample and .ModelEvaluations to replace .PriorPred and .Prior, respectively.

The workaround proposed @olaf.klein to get a discrepancy sample indeed works for the standard additive Gaussian discrepancy scenario. To avoid the need for workarounds in the future, I will include a new field .Discrepany inside .PostPredSampleand .PriorPredSample that contains the discrepancy and will be updated in future versions to also correctly treat non-additive discrepancy cases. The manual will also be updated for the next version to include a proper table discussing the fields of the .PostProc structure in the reference list section.

I hope this helps and let me know if you have any further questions.

2 Likes