dynamically change learning algorythm