optimized model. running tests
model fixed, added parameter optimization