This project demonstrates how to use Sapiens, a foundation model for human tasks (segmentation, depth, and normal estimation) in a Node.js environment.
- Clone the repository:
git clone https://github.com/huggingface/transformers.js-examples.git
- Change directory to the
sapiens-node
project:cd transformers.js-examples/sapiens-node
- Install the dependencies:
npm install
- Run the example:
node index.js
The following images illustrate the input image, its corresponding depth map, and the normal map generated by the model:
Input Image | Depth Map | Normal Map |
---|---|---|