Skip to content

Commit

Permalink
add regression
Browse files Browse the repository at this point in the history
  • Loading branch information
jeffffffli committed Nov 21, 2022
1 parent 3ed7a76 commit ea9b753
Show file tree
Hide file tree
Showing 10 changed files with 974 additions and 15 deletions.
81 changes: 81 additions & 0 deletions configs/256x192_adam_lr1e-3-hrw48_reg_cam_2x_w_pw3d_3dhp.yaml
Original file line number Diff line number Diff line change
@@ -0,0 +1,81 @@
DATASET:
DATASET: 'mix2_smpl_cam'
SET_LIST:
- ROOT: './data/h36m/'
TEST_SET: 'Sample_20_test_Human36M_smpl'
TRAIN_SET: 'Sample_trainmin_train_Human36M_smpl_leaf_twist'
- ROOT: './data/coco/'
TRAIN_SET: 'train2017'
- ROOT: './data/3dhp/'
TRAIN_SET: 'train_v2'
- ROOT: './data/pw3d/'
TRAIN_SET: '3DPW_train_new'
PROTOCOL: 2
FLIP: True
ROT_FACTOR: 30
SCALE_FACTOR: 0.3
NUM_JOINTS_HALF_BODY: 8
PROB_HALF_BODY: -1
COLOR_FACTOR: 0.2
OCCLUSION: True
MODEL:
TYPE: 'HRNetSMPLCamReg'
HR_PRETRAINED: './pose_hrnet_w48_256x192.pth'
PRETRAINED: ''
# TRY_LOAD: ''
TRY_LOAD: ''
RESUME: ''
FOCAL_LENGTH: 1000
IMAGE_SIZE:
- 256
- 256
HEATMAP_SIZE:
- 64
- 64
NUM_JOINTS: 29
HRNET_TYPE: 48
EXTRA:
SIGMA: 2
BACKBONE: 'resnet'
CROP: 'padding'
AUGMENT: 'none'
PRESET: 'simple_smpl_3d_cam'
DEPTH_DIM: 64
POST:
NORM_TYPE: 'softmax'
BBOX_3D_SHAPE:
- 2200
- 2200
- 2200
LOSS:
TYPE: 'LaplaceLossDimSMPLCam'
ELEMENTS:
BETA_WEIGHT: 1
BETA_REG_WEIGHT: 0
PHI_REG_WEIGHT: 0.0001
LEAF_REG_WEIGHT: 0
TWIST_WEIGHT: 0.01
THETA_WEIGHT: 0.01
UVD24_WEIGHT: 1
XYZ24_WEIGHT: 0
XYZ_SMPL24_WEIGHT: 0
XYZ_SMPL17_WEIGHT: 0
VERTICE_WEIGHT: 0
USE_LAPLACE: True
TEST:
HEATMAP2COORD: 'coord'
TRAIN:
WORLD_SIZE: 4
BATCH_SIZE: 36
BEGIN_EPOCH: 0
END_EPOCH: 200
OPTIMIZER: 'adam'
LR: 0.001
LR_FACTOR: 0.1
LR_STEP:
- 60
- 80
DPG_MILESTONE: 140
DPG_STEP:
- 160
- 190
Original file line number Diff line number Diff line change
@@ -0,0 +1,79 @@
DATASET:
DATASET: 'mix2_smpl_cam'
SET_LIST:
- ROOT: './data/h36m/'
TEST_SET: 'Sample_20_test_Human36M_smpl'
TRAIN_SET: 'Sample_trainmin_train_Human36M_smpl_leaf_twist'
- ROOT: './data/coco/'
TRAIN_SET: 'train2017'
- ROOT: './data/3dhp/'
TRAIN_SET: 'train_v2'
PROTOCOL: 2
FLIP: True
ROT_FACTOR: 30
SCALE_FACTOR: 0.3
NUM_JOINTS_HALF_BODY: 8
PROB_HALF_BODY: -1
COLOR_FACTOR: 0.2
OCCLUSION: True
MODEL:
TYPE: 'Simple3DPoseBaseSMPLCamReg'
PRETRAINED: ''
TRY_LOAD: 'simple_res50_256x192.pth'
FOCAL_LENGTH: 1000
IMAGE_SIZE:
- 256
- 256
HEATMAP_SIZE:
- 64
- 64
NUM_JOINTS: 29
NUM_DECONV_FILTERS:
- 256
- 256
- 256
NUM_LAYERS: 50
EXTRA:
SIGMA: 2
BACKBONE: 'resnet'
CROP: 'padding'
AUGMENT: 'none'
PRESET: 'simple_smpl_3d_cam'
DEPTH_DIM: 64
POST:
NORM_TYPE: 'softmax'
BBOX_3D_SHAPE:
- 2200
- 2200
- 2200
LOSS:
TYPE: 'LaplaceLossDimSMPLCam'
ELEMENTS:
BETA_WEIGHT: 1
BETA_REG_WEIGHT: 0
PHI_REG_WEIGHT: 0.0001
LEAF_REG_WEIGHT: 0
TWIST_WEIGHT: 0.01
THETA_WEIGHT: 0.01
UVD24_WEIGHT: 1
XYZ24_WEIGHT: 0
XYZ_SMPL24_WEIGHT: 0
XYZ_SMPL17_WEIGHT: 0
VERTICE_WEIGHT: 0
TEST:
HEATMAP2COORD: 'coord'
TRAIN:
WORLD_SIZE: 8
BATCH_SIZE: 32
BEGIN_EPOCH: 0
END_EPOCH: 200
OPTIMIZER: 'adam'
LR: 0.001
LR_FACTOR: 0.1
LR_STEP:
- 90
- 120
DPG_MILESTONE: 140
DPG_STEP:
- 160
- 190
2 changes: 1 addition & 1 deletion hybrik/models/HRNetWithCam.py
Original file line number Diff line number Diff line change
Expand Up @@ -356,7 +356,7 @@ def forward(self, x, flip_test=False, **kwargs):
cam_root=camera_root,
transl=transl,
pred_camera=pred_camera,
sigma=sigma,
pred_sigma=sigma,
scores=1 - sigma,
# uvd_heatmap=torch.stack([hm_x0, hm_y0, hm_z0], dim=2),
# uvd_heatmap=heatmaps,
Expand Down
Loading

0 comments on commit ea9b753

Please sign in to comment.