[Not Tested] Added Batch training and patterns shuffling.