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

Detect expressions in frames #15

Open
Bea98 opened this issue Dec 10, 2019 · 0 comments
Open

Detect expressions in frames #15

Bea98 opened this issue Dec 10, 2019 · 0 comments

Comments

@Bea98
Copy link

Bea98 commented Dec 10, 2019

Hi! I'm trying to evaluate the face expressions from a video without run it on the html. So I first started to divide the video into frames and now I'm trying to evaluate the expressions on ecah frame and just give the output of that.
So this is my frame extarction function:
function extractFramesFromVideo(){
let interval = 1 / 25;
let currentTime = 0;
while(currentTime < video.duration) {
context.drawImage(video, 0, 0, w, h);
var img = new Image();
img.src = canvas.toDataURL();
console.log(img);
let base64ImageData = canvas.toDataURL();
frames.push(base64ImageData);
console.log(currentTime)
currentTime += interval;
}
tried to use your function of faceapi.buffertoImage() but it tells me that a blob is expected. Could you give ma any tips on how to detect expressions on the images?

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

1 participant