Giter Site home page Giter Site logo

wanghsinche / name-pls.js Goto Github PK

View Code? Open in Web Editor NEW
4.0 2.0 0.0 4.82 MB

A face-recognition solution written in NodeJS

Home Page: https://name-pls.com

License: BSD 2-Clause "Simplified" License

JavaScript 0.39% TypeScript 20.41% CSS 1.25% Shell 0.35% Jupyter Notebook 77.60%
face-recognition nodejs onnxruntime nextjs

name-pls.js's Introduction

Name-PLS.JS

node TypeScript onnx InsightFace

A ONNX Runtime backed Face-Recognition implementation for Node.js. You can easily replace the pre-train ONNX format file with your SOTA model to inter other IMAGE machine learning problems, include but not limited to face verification, recognition and object detection.

Name-PLS.JS

An online demo can be found at name-pls.com

2022-01-18-14-10-14-name-pls

Using InsightFace, sklearn and ONNX to extract feature and classify.

Thanks for Next.js and daisyui's awasome UI Lib.

Getting Started

First, run the development server:

# install dependencies
yarn add

# run the dev server, make sure your free memory is enough
yarn dev

Open http://localhost:3000 with your browser to see the result.

Besides, you can directly call the api/recog to recognize your image. In fact, it doesn't require a preprocessing.

To use your customized pre-train model, you can easily convert it into ONNX format and put it in services/recog/model. Be cautioned, you should modify the preprocessing method to make your input match your model.

The bayesian classifier was trained with Japanese actress face. To add more actress in the feature db, you can try the notebooks in /notebook folder.

How does it work

workflow

TO DO

  • Face detect and align module relies on faceapi.js, which is built on Tensorflow.js and causes high memory usage. It'd be better to replace this module with onnx runtime module.
  • The Node Canvas module has external c++ libray dependecies, which is unfriendly to deploy them on cloud platform such as vercel or aws lambda. Replacing it with Jimp to process image would be more compatible.
  • The feature extraction pre-trained model is still low precision (about 70%).

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.