Bayesian ensemble learning of generative models