rename row and col to dim