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

trouble with Video() with webcam #40

Open
mangeshkangule opened this issue Feb 28, 2022 · 1 comment
Open

trouble with Video() with webcam #40

mangeshkangule opened this issue Feb 28, 2022 · 1 comment

Comments

@mangeshkangule
Copy link

Hi @JustinShenk, I am trying to use fer with a webcam but getting an error when using a web cam instead of video file with Video()

`vid = cv2.VideoCapture(0)

while True:
ret, frame = vid.read()
face_detector = FER(mtcnn=True)
input_video = Video(vid)
processing_data = input_video.analyze(face_detector, display=False)`

The following error occurs at the input_video= Video()

TypeError: stat: path should be string, bytes, os.PathLike or integer, not VideoCapture

@JustinShenk
Copy link
Owner

The Video class takes the path to a file as an input. I think what you are looking for can be found in demo.py with python demo.py webcam. If you would like another feature please open a ticket for it.

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