change init Th to [0, 0, 5]

This commit is contained in:
Frankie 2023-02-24 18:04:07 +08:00 committed by GitHub
parent d7e19e0bc0
commit b794c16d90
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -288,12 +288,15 @@ class SPIN:
p, _ = cv2.Rodrigues(rotmat[i])
poses[0, 3*i:3*i+3] = p[:, 0]
results['poses'] = poses
body_params = {
'Rh': poses[:, :3],
'poses': poses[:, 3:],
'shapes': results['shapes'],
}
results = body_params
if use_rh_th:
body_params = {
'Rh': poses[:, :3].copy(),
'poses': poses[:, 3:],
'shapes': results['shapes'],
'Th': np.zeros((1, 3))
}
body_params['Th'][0, 2] = 5
results = body_params
return results
def __call__(self, body_model, img, bbox, kpts, camera, ret_vertices=True):
@ -351,4 +354,4 @@ def init_with_spin(body_model, spin_model, img, bbox, kpts, camera):
return results
if __name__ == '__main__':
pass
pass