Add the train method as an abstract method in BaseModel.java