Stochastic annealing of an Hopfield model