takeyamayuki / nonmouse Goto Github PK
View Code? Open in Web Editor NEWa webcam-based virtual gesture mouse that is easy to use with hands on the desk.
Home Page: https://zenn.dev/ninzin/articles/94b05fdb9edf53
License: Apache License 2.0
a webcam-based virtual gesture mouse that is easy to use with hands on the desk.
Home Page: https://zenn.dev/ninzin/articles/94b05fdb9edf53
License: Apache License 2.0
cfps = int(cap.get(cv2.CAP_PROP_FPS))
でcfpsが1になって
if cfps < 30: cap.set(cv2.CAP_PROP_FRAME_WIDTH, cap_width) cap.set(cv2.CAP_PROP_FRAME_HEIGHT, cap_height) cfps = int(cap.get(cv2.CAP_PROP_FPS))
を通してもcfpsが1になり、
ran = int(cfps/10)
でranが0になってしまい、ZeroDivisionErrorでクラッシュします。
環境は以下の通りです
PC: MacBook Pro 2020 Intel
OS: macOS Monterey
カメラ: Mac内蔵Webカメラ
Pythonバージョン: 3.9.7
Hello the mouse only works on left two thirds of the screen. I gues it has something to do with screen size, my lapto has 1920x1080. Can I reconfigure it somewhere?
When I run pip install nonmouse
as mentioned in the readme, I get the following error: Perhaps the mediapipe version can be updated?
ERROR: Could not find a version that satisfies the requirement mediapipe==0.8.10.1 (from nonmouse) (from versions: 0.9.0.1, 0.9.1.0, 0.9.2.1, 0.9.3.0, 0.10.0, 0.10.1, 0.10.2, 0.10.3, 0.10.5, 0.10.7, 0.10.8)
ERROR: No matching distribution found for mediapipe==0.8.10.1
Thank you for this package.
requirements.txtの通りにインストールすると、pyobjcによるエラーが発生する。そのときは、以下のように、pyobjcのダウングレードをすること
moses-palmer/pynput#420
Sorry for not posting a lot of debug info here, but I am trying to test this and only can get it working for my mounted webcam. Anytime I try to use a usb web cam the device does not appear to work properly for the program.
I will try to pull down the project soon and see if I can get some more info as to what or why they are not working.
Hello. When installing requirements on Linux I get this error:
Collecting pyobjc-core==7.3
Downloading pyobjc-core-7.3.tar.gz (684 kB)
━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━━ 684.2/684.2 KB 5.4 MB/s eta 0:00:00
Preparing metadata (setup.py) ... error
error: subprocess-exited-with-error
× python setup.py egg_info did not run successfully.
│ exit code: 1
╰─> [2 lines of output]
running egg_info
error: PyObjC requires macOS to build
[end of output]
note: This error originates from a subprocess, and is likely not a problem with pip.
error: metadata-generation-failed
× Encountered error while generating package metadata.
╰─> See above for output.
Lines 117 to 121 in 1e7f7bc
cfps = int(cap.get(cv2.CAP_PROP_FPS))で取得するカメラのFPSが5Hzになってしまい、カーソルが小刻みに揺れてしまう。
これは恐らく、cv2の問題だと思われる。
Lines 115 to 155 in 4603acc
たとえば、カメラを斜めに取り付けると、カメラに映る指は縦方向に圧縮されたものになり、当然移動量もその分小さくなる。
現在の自分の環境だと手に向けてまっすぐ取り付けられているので問題はないが、初めて使う人にとってはこのアプリケーションを使う上での大きな壁となる。
「解決策」
まず、基準となる指の関節座標を用意しておく。
その基準となる座標群と現在の座標群を比較して手の傾き具合を求める。
それによって、dx,dy変える
App wont start, any ideas why?
A declarative, efficient, and flexible JavaScript library for building user interfaces.
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google ❤️ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.