some changes on gbrbm and trainer