first commit, only tensorGM method