Add reTrain function, amend model construction method