Inference and learning in Bayesian networks using overlapping swarm intelligence