update code

This commit is contained in:
Iridoudou
2021-08-07 08:03:40 +08:00
parent 0152f1909f
commit 9f6274fc19
8 changed files with 160 additions and 65 deletions

14
fit/tools/map.py Normal file
View File

@ -0,0 +1,14 @@
import numpy as np
def mapping(Jtr,cfg):
name=cfg.DATASET.NAME
if not name=='HumanAct12':
mapped_joint=cfg.DATASET.DATA_MAP.UTD_MHAD
Jtr_mapped=np.zeros([Jtr.shape[0],len(mapped_joint),Jtr.shape[2]])
for i in range(Jtr.shape[0]):
for j in range(len(mapped_joint)):
for k in range(Jtr.shape[2]):
Jtr_mapped[i][j][k]=Jtr[i][mapped_joint[j]][k]
return Jtr_mapped
return Jtr