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

Pretrained model for prediction #17

Closed
surtantheta opened this issue Nov 21, 2021 · 3 comments
Closed

Pretrained model for prediction #17

surtantheta opened this issue Nov 21, 2021 · 3 comments

Comments

@surtantheta
Copy link

surtantheta commented Nov 21, 2021

Can you kindly elaborate on how we can use the fine-tuned checkpoints for the prediction of new data in concode task?
Say this is my prediction data:
{"code": "public integer sum(Integer arg0,Integer arg1) {return result;}", "nl": "Add two integers. concode_field_sep int sum concode_field_sep int result"}
If I understand correctly then concode is supposed to complete these functions. However, I am not sure how to generate prediction on this sample data.
I tried replacing the test file containing original test data with this sample test data and then ran this command
python run_exp.py --model_tag codet5_small --task concode --sub_task none
This command starts with training, then evaluating and finally testing. However, I am interested in only prediction. Isn't there any way to directly generate predictions from fine-tuned model on concode ?
Kindly let me know if I am doing something wrong.

@yuewang-cuhk
Copy link
Contributor

Hi, if you only want to use the pretrained models for testing, you can simply remove the --do_train --do_eval in here and pass the pretrained model path via adding --load_model_path your/pretrained/model/path.

@surtantheta
Copy link
Author

Thanks a lot for your reply. Can you also provide a link to your pretrained concode model. Is it the same as that of fine-tuned model checkpoints that you have provided in your repo?

@yuewang-cuhk
Copy link
Contributor

We have released all fine-tuned CodeT5-base checkpoints at here:)

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