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

How to carry out migration training #57

Open
3600067524 opened this issue Apr 19, 2022 · 10 comments
Open

How to carry out migration training #57

3600067524 opened this issue Apr 19, 2022 · 10 comments

Comments

@3600067524
Copy link

Hi, thank you very much for your contribution.
I have a question about how to use the pre training model(sold2_wireframe.tar) of wireframe dataset provided in Readme document to migrate and learn on a small self-made street view image dataset. I hope you can provide me with some suggestions.

@rpautrat
Copy link
Member

Hi, sure, you can follow the process explained in #19 to generate a ground truth for your dataset, and train your model using the pre-trained weights that have been released. You can for this create a folder pretrained_sold2 in your EXP_PATH (defined in sold2/config/project_config.py) and put the sold2_wireframe.tar in it, then run this command:

python -m sold2.experiment --mode train --dataset_config <your custom config> --model_config sold2/config/train_full_pipeline.yaml --exp_name sold2_street_view --pretrained --pretrained_path pretrained_sold2 --checkpoint_name sold2_wireframe.tar

@3600067524
Copy link
Author

Thank you for your replying

@3600067524
Copy link
Author

Hi!I tried to run step2&step3 on my own dataset according to the above tips, and generated H5 files.
image
Then I trained on my dataset according to the command line (python -m sold2.experiment --mode train --dataset_config holicity_dataset.yaml --model_config train_full_pipeline.yaml --exp_name sold2_street_view --pretrained True --pretrained_path pretrained_sold2 --checkpoint_name sold2_wireframe.tar) of migration learning above. The following errors occurred. What is the reason
IMG_2270(20220503-083748)
In the program, how the following quantities are generated is not found
IMG_2271(20220503-084544)

@rpautrat
Copy link
Member

rpautrat commented May 3, 2022

Hi, the 'return_type' field in the config should be changed to 'paired_desc' to get pairs of images in the dataloader, as explained in step 5 of the Readme.

@3600067524
Copy link
Author

Thank you for your timely reply, but I'm sorry to bother you again. After modifying that variable, the previous error will still appear and has not changed.
image
I use the code of holicity dataset to generate the pseudo ground truth value and the ground truth value of my dataset. This error will appear when running the command line you provided above for training, and it has not been changed.
IMG_2270(20220503-083748)
I wonder if there are any other reasons

@rpautrat
Copy link
Member

rpautrat commented May 3, 2022

Can you print the keys of the dictionary 'data'? This could give a hint about what is happening.

@3600067524
Copy link
Author

data is
IMG_2274(20220503-231738)
IMG_2271(20220503-084544)

It's strange that there is no corresponding keyword, and the two output keywords are not related. What's the reason for this

@3600067524
Copy link
Author

Hi ! Can you give some tips to the above questions,thank you

@rpautrat
Copy link
Member

rpautrat commented May 6, 2022

What is the value of 'gt_source_train' and 'gt_source_test' in your config file? Did you update them with the path to your generated h5 file?

@rpautrat
Copy link
Member

Has your initial problem been solved in the end?

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

2 participants