A client-only TypeScript port of the Google GNM v3 head model and the reference Blender editor. It evaluates identity, expression, pose correctives, and four-joint skinning in the browser, then renders the generated head with Three.js.
Requirements: Node.js 20 or newer.
npm install
npm run devOpen the URL printed by Vite (normally http://localhost:5173). There is no
application server or API: Vite only serves static local files during
development.
npm test
npm run build
npm run previewThe production output is in dist/ and can be served by any static file host.
The initial load downloads and decompresses the official 53 MB
gnm_head.npz. The browser retains larger uncompressed basis tensors in GPU
memory, so a desktop browser with WebGL enabled is recommended.
Official assets are stored in public/gnm/ and retain Google's Apache-2.0
license and attribution. To download and regenerate them:
python3 -m pip install numpy h5py
npm run assets:prepareThe preparation step converts the two Keras HDF5 semantic decoders to a compact NPZ consumed directly by TensorFlow.js. No Python dependency is required to run or build the web app after the assets have been prepared.
- Full 253-component identity and 383-component expression state
- Seeded semantic identity and 20-class expression sampling
- Identity/expression blending and bilateral eye-expression mirroring
- Neck, head, and independent eye pose controls
- Official topology, per-corner UVs, texture, and anatomical materials
- Browser-saved named presets and Blender-compatible JSON import/export
GNM has documented representation limitations inherited from its training data. Review the upstream project before using demographic controls in a product or study.