justadudewhohacks / justadudewhohacks/opencv4nodejs

Facemark example not running

Open
#414 18 comments 0 reactions 0 assignees View on GitHub
Dominant language
C++
Stars
5.1k
Forks
826
PR merge metrics
No merged PRs in 30d

Description

Hi !

When I tried to launch the example "facemark", I get the following error :

```
facemark.setFaceDetector(frame => {
^

TypeError: facemark.setFaceDetector is not a function
at Object. (/home/loophole/EventBots/vision/opencv4nodejs/examples/facemark.js:27:10)
at Module._compile (module.js:624:30)
at Object.Module._extensions..js (module.js:635:10)
at Module.load (module.js:545:32)
at tryModuleLoad (module.js:508:12)
at Function.Module._load (module.js:500:3)
at Function.Module.runMain (module.js:665:10)
at startup (bootstrap_node.js:201:16)
at bootstrap_node.js:626:3
```

When I comment this line, I get another one :

```
const faces = facemark.getFaces(gray);
^

TypeError: facemark.getFaces is not a function
at Object. (/home/loophole/EventBots/vision/opencv4nodejs/examples/facemark.js:35:24)
at Module._compile (module.js:624:30)
at Object.Module._extensions..js (module.js:635:10)
at Module.load (module.js:545:32)
at tryModuleLoad (module.js:508:12)
at Function.Module._load (module.js:500:3)
at Function.Module.runMain (module.js:665:10)
at startup (bootstrap_node.js:201:16)
at bootstrap_node.js:626:3
```

Am I missing something ?

Contributor guide

Open the contributing guide

Research direction

Start with examples/facemark.js, especially lines 27 and 35, and reproduce the reported TypeErrors when running the facemark example. Check the exposed facemark API and the calls to setFaceDetector and getFaces; done means the example runs without these errors.

Written by the indexing model from the issue text.

Assessment

Tech stack
javascript, nodejs, opencv
Domain
computer-vision
Issue type
Bug
Difficulty
3/5
Estimated time
1-2 days
Activity status
Stale
Clarity
Needs clarification
Newbie friendliness
35/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.