unfinished training algorithm for boltzman