implemented training stage, but to fix bounding effect