lzane / Fingers-Detection-using-OpenCV-and-Python

A simple Fingers Detection (or Gesture Recognition) using OpenCV and Python with background substraction 简单手势识别
https://www.lzane.com
MIT License
437 stars 176 forks source link

cannot running as demo #7

Closed Dragonwarri0r closed 5 years ago

Dragonwarri0r commented 6 years ago

when i press b to get background and n to start,it can running a little time but gradually my hand integrate into backgroud(black).

struggling-man commented 6 years ago

I have the same situation. can you help me!

lzane commented 6 years ago

Have you try to set different parameters? This CV approach is easy light-affected. It's a very old project so I nearly forget the detail.

Anyway, I will try it on my computer when I can reach one.

Good Luck~

lzane commented 6 years ago

Hey, I have noticed that the issue was caused by the new version of OpenCV api's modification.

Please checkout https://docs.opencv.org/3.4/d7/d7b/classcv_1_1BackgroundSubtractorMOG2.html#a682adde901148d85450435e6cc0de4a1

I wrote my code with OpenCV2, sorry for not testing the other contributor's pull request.

I will push a new version of code in a few minutes.

lzane commented 6 years ago

@Dragonwarri0r @struggling-man Plz pull the new version.

Hope it works for you guys. :)

taojinglong commented 5 years ago

When we use the latest version of opencv,line 96 in the new.py should be changed to this

lzane commented 5 years ago

@taojinglong you are right.

As the document show, that's because of the breaking change of the findContours api.

Since the project I write is in OpenCV 3, I Don't have plan to change it from the source code.

But I will find time to add the notice to the README

Doc:

lzane commented 5 years ago

Close this issue since it's solved.

vedant10 commented 4 years ago

How to display the number of fingers in number. Eg 1 or 2 or 10