training before matrix