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

Inference on custom dataset #9

Closed
shamilnabiyev opened this issue Mar 22, 2023 · 2 comments
Closed

Inference on custom dataset #9

shamilnabiyev opened this issue Mar 22, 2023 · 2 comments

Comments

@shamilnabiyev
Copy link

Hi @zhiyuanyou Thanks for publishing such an amazing tool. I'm wondering, if it's possible to use pre-trained models (without fine-tuning) for object counting on custom dataset. May I ask you to give some hints for creating a simple demo script for such use cases?

@zhiyuanyou
Copy link
Owner

zhiyuanyou commented Mar 22, 2023

If you want to infer, you could mainly utilize the eval() function in ./tools/train_val.py by the following steps:
(1) Remove the codes about "density" in ./datasets/custom_dataset.py.
(2) Remove the codes about "density", "MAE", and "RMSE" in eval() function of ./tools/train_val.py.
(3) Create your own dataset about inference, i.e., create a json file like example (but with no need of "density").
(4) Revise config.yaml to use your own dataset, and run python ./tools/train_val.py -e.

@shamilnabiyev
Copy link
Author

Thank you for your suggestion

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