updated optimizer and manager.