Improved flushing of SimpleProgressCallback.
Include cleanup.
Now the train method returns a boolean. If alpha becomes NaN or infinity, return false.
t doesn't need to be a class attribute.