Giter Club home page Giter Club logo

brfv5-browser's People

Contributors

marcelklammer avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

brfv5-browser's Issues

Changing coloring-libs colors based on input.

Hey, I would like to know, if it is possible , to propagate a hex color code, from the html, to the coloring-libs.js functions, so that i can change the colors on the lips, that are being drawn from handleTrackingResults()

Latency Issues

Hi,

I am using brfv4 but having some latency issues. Is there a way to configure brdv4 to track only 20 or so points as this is all I need>
also it would be great to have user definable points to track...as for animation, I only need a third of the landmark points tracked...this would increase speed and reduce lag to my websocket...
If I purchased brfv5, could I arrange to include the extra optical flow points? It's omission in brv4 is the only reason I won't upgrade.
David Knight

Can i test brfv5 in codepen?

The question is if there any opportunity to test brfv5 in codepen? I usually make some sketches there and show my team before we decide use it or not.

How to run with parcel

Hi,

I can run the project successfully with "live-server" but I don't know how to run with "parcel". It throws errors while loading the "loadBRFv5Model":
Uncaught Error: Invalid reserved bit at H (brfv5_js_tk290120_v5.1.3_trial.js:10) at T (brfv5_js_tk290120_v5.1.3_trial.js:10) at Object.z [as process] (brfv5_js_tk290120_v5.1.3_trial.js:10) at XMLHttpRequest.xhrBinary.onload (brfv5_js_tk290120_v5.1.3_trial.js:10)

magic numbers when mapping to 3d?

I'm looking through the threejs__brfv5_mapping.js file and wondering if you could explain exactly how and why the translation and rotation values are calculated the way they are. Things seem to work, but I'd like a better understanding of the math that is happening there.

Specifically, how is the z value chosen? It's written as

  let modelZ = 2725

  if(t3d.camera.isPerspectiveCamera) {
    modelZ = (2725 / 480) * (canvasHeight / t3d.sceneScale)
  }

I assume the 480 comes from the camera height, but what about the 2725?

Same thing with the face scale?

    let scale =   face.scale * si * 0.0133

Where does the 0.0133 come from?

Is there a better or simpler way to map the face xy and rotation into a three.js coordinate space?

brfv5-ios

Hi:
Thank you very much for your hard work, When will brfv5-ios be released?

Face tracking model?

Hello Sir,

I'm glad to see this excellent repo you have done incredible work here. The face tracking implementation is really fast and smooth. I would like to know what model you are using for face tracking?

Usage of eval and CSP

On commercial library file eval is being used like this:
eval(Module["UTF8ToString"]($0))
This single line forces us to include 'unsafe-eval' on our content security policy, would it be possible to find an alternative way to load that code so we can avoid using unsafe directives?
Thanks

Firefox memory leak in webworker example

When running the minimal__webworker__track_one_face.html example in Firefox, the webworker process gradually consumes more and more memory in the background. Eventually, the tracking becomes incredibly slow as too many resources have been consumed.

Here's a snapshot of my Mac's activity monitor after running the example for a few minutes, showing 2.38 GB memory consumption:
activity monitor

The other single-threaded examples tend to maintain ~300 MB memory usage. I also don't experience this issue in Chrome. I'm thinking this may be a bug in Firefox itself, but I'm posting here in case there is a simple implementation fix.

How can I use this with webpack?

I added this project to my project's node_modules using npm, and when I try to import the file I get this error

Uncaught Error: Invalid reserved bit
    at H (brfv5_js_tk121020_v5.2.0_trial.js?6820:formatted:320)
    at T (brfv5_js_tk121020_v5.2.0_trial.js?6820:formatted:652)
    at Object.z [as process] (brfv5_js_tk121020_v5.2.0_trial.js?6820:formatted:659)
    at XMLHttpRequest.xhrBinary.onload (brfv5_js_tk121020_v5.2.0_trial.js?6820:formatted:1341)

Tracking a single frame (image)

Hello,

We are using this solution for webcam video tracking. Currently, we have an extra need, processing an image using BRFv5 to get the 68 points.
First, we transform the image to 640x480 pixels and we make sure that the face is centred and with good size. But:

  • The face is not detected many times
  • When the face is detected, we process the image BRFManager.update() 10 times with different 68 points coordinates values.

Which configuration should we use?

I share an image as an example of face not detected.

image

// 640 x 480 
const BRF = await BRFv5.createInstance({ width, height, uniqueFrame: true });
const canvas = document.createElement('canvas');
canvas.width = width;
canvas.height = height;
context.drawImage(imageElement, 0, 0, width, height);
const imageData = context.getImageData(0, 0, width, height);

for (let index = 0; index < 10; index += 1) {
        BRF.Manager.update(imageData);
}

const faces = BRF.Manager.getFaces();

const isFaceDetected =
        faces.length > 0 &&
        (faces[0].state === BRF.Instance.BRFv5State.FACE_TRACKING_START ||
          faces[0].state === BRF.Instance.BRFv5State.FACE_TRACKING);

if (isFaceDetected) {
     return resolve(faces[0].vertices);
}
const error = new Error('No face detected');
error.code = 999;
return reject(error);

How to detect bangs?

Hello.

I used your API, but it is difficult to detect bangs.
Is there any way to detect bangs.
Should I pay for the API to a upgraded version?

Thanks.

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.