A computer implementation of a bayesian analysis of image reconstruction