Update trainer.java