add transform cpt and fix bugs