Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Issues with in model training #37

Open
sinapy opened this issue Sep 22, 2024 · 0 comments
Open

Issues with in model training #37

sinapy opened this issue Sep 22, 2024 · 0 comments

Comments

@sinapy
Copy link

sinapy commented Sep 22, 2024

Hey, I've tried to train the model and I faced some confusion:

1. Download AMASS: Store in a folder "amass_raw"". You can train the model for SMPL/SMPL+H or SMPL+X.
From what I understood, I need to install all of these below and put the folders under "amass_raw"

'vald': ['HumanEva', 'MPI_HDM05', 'SFU', 'MPI_mosh'],
'test': ['Transitions_mocap', 'SSM_synced'],
'train': ['CMU', 'MPI_Limits', 'TotalCapture', 'Eyes_Japan_Dataset', 'KIT', 'BioMotionLab_NTroje' ,'BMLhandball' ,
              'BMLmovi', 'EKUT', 'TCD_handMocap',
              'ACCAD']

And the folder structure would look something like this:
image

I wish the step had clarified this beforehand

Also it takes a very long time to download all of them, specially that the website only allowed me to download one at a time.

Some of the names has also changed, so I've renamed them to the list above

image

and BioMotionLab_NTroje is BMLrub

2.1 Sample poses from AMASS:

python data/sample_poses.py --sampled_pose_dir <path_for_samples_amass_poses> --amass_dir <amass_dataset_dir>

I didn't understand what is path_for_samples_amass_poses, and also what's it's difference with amass_dataset_dir
In my code I put both path_for_samples_amass_poses and amass_dataset_dir set to ./amass_raw and it worked with some changes to the code
so the final command for me was

conda run python data/sample_poses.py --sampled_pose_dir ./amass_raw/ --amass_dir ./amass_raw/

The other thing that I think should have been said in this step is changing the mode for sample_poses.py. I think for training, I need to run sample_poses.py for the train dataset as well

prepare_vposer_datasets(posendf_data_dir, amass_splits, amass_dir, mode='test')

Because if not, I wouldn't have the .npz files of the first layer folders like I did for SSM_synced.
image

Are the above necessary or should I use the existing .npz files under the second layer folders?
image

One bug fix is that, for sample_poses.py, you probably don't want to sample the generated .npz files

def prepare_vposer_datasets(vposer_dataset_dir, amass_splits, amass_dir, mode='train'):
keep_rate = 0.3
amass_datas = sorted(amass_splits[mode])
for amass_data in amass_datas:
ds_dir = os.path.join(amass_dir,amass_data)
seqs = sorted(os.listdir(ds_dir))
if not os.path.exists(os.path.join(vposer_dataset_dir, amass_data)):
os.makedirs(os.path.join(vposer_dataset_dir, amass_data))
for seq in seqs:
pose_body = []
root_orient = []
if 'LICENSE' in seq:
continue
out_path = os.path.join(vposer_dataset_dir, amass_data, seq + '.npz')

In the above code, even the below files would be considered for sampling and it will raise an error
image

so I think you should add this line before line 30:

if '.npz' in seq:
    continue
@sinapy sinapy changed the title Issues with the code in model training Issues with in model training Sep 22, 2024
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant