Skip to content

Prediction code #1

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

Open
developer888891 opened this issue Dec 26, 2018 · 1 comment
Open

Prediction code #1

developer888891 opened this issue Dec 26, 2018 · 1 comment

Comments

@developer888891
Copy link

Hi, thanks for the repo! I'm working on hand gesture recognition currently(Especially on JESTER dataset), I saw your work on it, but I didn't find any prediction code in it. Can you please share a hand gesture prediction code for webcam?

Thank You!

@OValery16
Copy link
Owner

Hi @developer888891,

For the prediction code, you just need to run the train.py with the arg "eval_only"

example: python train.py --eval_only True --resume True --config configs/config.json -g 0

For the webcam, my advice would be to use opencv and capture the different frames. For example, with this code https://opencv-python-tutroals.readthedocs.io/en/latest/py_tutorials/py_gui/py_video_display/py_video_display.html

Later you plug the image in the data loader "VideoFolder" (you can modify it a bit to get the frame directly from the webcam, it is not complicated), and after you run the prediction step with "validate(val_loader, model, criterion, train_data.classes_dict)"

If you like you like this project, feel free to leave a star. (it is my only reward ^^)

Olivier

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