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

error in !python3 run_image.py --image=test.png #19

Open
moahaimen opened this issue Aug 4, 2022 · 13 comments
Open

error in !python3 run_image.py --image=test.png #19

moahaimen opened this issue Aug 4, 2022 · 13 comments

Comments

@moahaimen
Copy link

Traceback (most recent call last):
File "run_image.py", line 8, in
from tf_pose.estimator import TfPoseEstimator
File "/content/human-action-classification/tf_pose/init.py", line 5, in
from tf_pose.runner import infer, Estimator, get_estimator
File "/content/human-action-classification/tf_pose/runner.py", line 8, in
from tf_pose.estimator import TfPoseEstimator
File "/content/human-action-classification/tf_pose/estimator.py", line 4, in
import slidingwindow as sw
ModuleNotFoundError: No module named 'slidingwindow'

@xander-m2k
Copy link

pip3 install slidingwindow

@moahaimen
Copy link
Author

i did it now then another error appeared by the way i am using Google Colab

!python3 run_image.py --image=test.png
No module named '_pafprocess'
you need to build c++ library for pafprocess. See : https://github.com/ildoonet/tf-pose-estimation/tree/master/tf_pose/pafprocess

@xander-m2k
Copy link

Come on man, this error is litteraly in the README of this repository... It shows you exactly what to do

@moahaimen
Copy link
Author

@moahaimen

ok thank you,
I am sorry for the stupid questions, believe I am trying to find a solution for my Ph.D. project so forgive me
I am trying to detect object human are holding , using Yolov5 I succeed in that, but my professor wants me now to recognize the human action, is he going to throw it, or other actions
and I am new in this field
so I will appreciate any help from you, is that possible?

@dronefreak
Copy link
Owner

Hi @moahaimen I could perhaps try to help on weekends, but weekdays would not be possible.

@xander-m2k
Copy link

xander-m2k commented Aug 4, 2022

I did my bachelor thesis about human action classification, I used many papers, but this one (https://arxiv.org/pdf/1904.09140.pdf) I used the most. I am not sure I can share my own paper/thesis because I worked with a camera surveillance company.

@xander-m2k
Copy link

xander-m2k commented Aug 4, 2022

using Yolov5 I succeed in that

BTW, I found that Yolov4 was working way better then v5 overall.

@moahaimen
Copy link
Author

I did my bachelor thesis about human action classification, I used many papers, but this one (https://arxiv.org/pdf/1904.09140.pdf) I used the most. I am not sure I can share my own paper/thesis because I worked with a camera surveillance company.

thank you for responding, my work also on CCTV
but i don't need papers I just need to do it by code in python, PyTorch
do you have any examples in code you can help me with
so I can merge Yolo+LSTM so I can detect the object and the human recognition
thank you

@xander-m2k
Copy link

I did my bachelor thesis about human action classification, I used many papers, but this one (https://arxiv.org/pdf/1904.09140.pdf) I used the most. I am not sure I can share my own paper/thesis because I worked with a camera surveillance company.

thank you for responding, my work also on CCTV

but i don't need papers I just need to do it by code in python, PyTorch

do you have any examples in code you can help me with

so I can merge Yolo+LSTM so I can detect the object and the human recognition

thank you

I'm sorry, I cannot share those.

@moahaimen
Copy link
Author

I did my bachelor thesis about human action classification, I used many papers, but this one (https://arxiv.org/pdf/1904.09140.pdf) I used the most. I am not sure I can share my own paper/thesis because I worked with a camera surveillance company.

thank you for responding, my work also on CCTV
but i don't need papers I just need to do it by code in python, PyTorch
do you have any examples in code you can help me with
so I can merge Yolo+LSTM so I can detect the object and the human recognition
thank you

I'm sorry, I cannot share those.

ok thank you dont share it but could you explain in in words so i understand whether there is a hope to do it or not
thank you again

@xander-m2k
Copy link

xander-m2k commented Aug 4, 2022

Not to be rude or anything, but if you have made it as far as a PhD you should be able to research that for yourself right?
Regarding if this works or not, I would not know, I took a different approach from you (I was using pose estimation), so there is no way I could advise you on that.
But if I might say, start small, by just detecting one person with Yolov4 (or 5), optimize that output, use the bounding box image as input of your LSTM model. Then maybe if you finish that you can start working on multiple people tracking.

So my basic approach would be:

  1. Find or create some training data
  2. The YOLO model has already been trained but you can retrain it if you want
  3. Create a large dataset using the YOLO model
  4. Train a LSTM model with that dataset
  5. Try some alternating training values, see if you can get better results

Other than that, research is research, even if I did not succeed, you should still try it, because you might find a better approach. Therefore no one can tell you what might an what might not work, things might just coincedentally work. (Of course using models that make somewhat sense.)

@moahaimen
Copy link
Author

Not to be rude or anything, but if you have made it as far as a PhD you should be able to research that for yourself right? Regarding if this works or not, I would not know, I took a different approach from you (I was using pose estimation), so there is no way I could advise you on that. But if I might say, start small, by just detecting one person with Yolov4 (or 5), optimize that output, use the bounding box image as input of your LSTM model. Then maybe if you finish that you can start working on multiple people tracking.

So my basic approach would be:

  1. Find or create some training data
  2. The YOLO model has already been trained but you can retrain it if you want
  3. Create a large dataset using the YOLO model
  4. Train a LSTM model with that dataset
  5. Try some alternating training values, see if you can get better results

Other than that, research is research, even if I did not succeed, you should still try it, because you might find a better approach. Therefore no one can tell you what might an what might not work, things might just coincedentally work. (Of course using models that make somewhat sense.)

thank you, I did all these steps but Poor Results i got, so The only way I see it is by putting more Datasets of videos for LSTM
and for the PH.D
I can't explain all the project, but what I can say to you I tried till now more than 7 methods to reach better accuracy, and all that takes time,
the only approach I can think would work is taking the angles of the body to see if the athlete is in a position to through the ball
thank you again

@yash2002vardhan
Copy link

while running the pafprocess issues mentioned in the readme.md I am encountering the following error:
No file python.swg found.
So how to resolve this error

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

4 participants