fit generalization bugs fixed