Skip to main content

MVMP: 3D Multi-View MediaPipe

License Framework Face Landmarker

Description

MVMP detects 478 MediaPipe-compatible 3D facial landmarks on textured meshes. It renders the mesh from 5 deterministic zone-based viewpoints (front, left/right sides, upper/lower), detects 2D landmarks with MediaPipe, and back-projects each to the mesh surface via raycasting. An optional Fibonacci-sphere auto-alignment phase orients the face toward +Z before detection.

Supported mesh formats: .obj, .ply, .stl, .gltf, .glb, .off

System Requirements

Platform OpenGL backend Notes
Linux + GPU EGL (auto-detected) Works out of the box
Linux headless (no GPU) OSMesa apt install libosmesa6 (Ubuntu/Debian) · dnf install mesa-libOSMesa (Fedora/RHEL)
macOS CGL (system OpenGL) OpenGL deprecated since macOS 10.14 but still functional
Windows WGL Requires a GPU; pure CPU/headless not supported

Python: 3.11 – 3.12 fully supported. Python 3.13 may work but mediapipe wheels are not yet universally available for that version.

Installation

pip install mvmp

The MediaPipe Face Landmarker model is bundled in the package.

From Source

git clone https://github.com/gfacchi-dev/mvmp.git
cd mvmp
pip install .

Usage

Python API

from mvmp import Facemarker

marker = Facemarker()
result = marker.predict("path/to/mesh.obj")
print(result)  # FacemarkerResult(478 landmarks, 478 vertex indices)

landmarks_3d = result.landmarks_3d              # dict[int, [x, y, z]]
vertex_indices = result.closest_vertices_ids    # dict[int, int]

result.save_json("landmarks.json")

Quiet mode / debug output

marker = Facemarker(verbose=False)

# Save per-zone renders and auto-align report
marker = Facemarker(debug_output_dir="debug/")

Camera distance

# Move cameras closer (0.5×) or farther (2×)
marker = Facemarker(camera_distance_multiplier=0.8)

Disable auto-alignment

# Skip Fibonacci-sphere alignment (mesh assumed to already face +Z)
marker = Facemarker(auto_orient=False)

Command Line

mvmp path/to/mesh.obj -o output/

# Process a folder
mvmp meshes/ -o results/

# With debug renders
mvmp mesh.obj --debug debug_output/

# Closer camera, no auto-align
mvmp mesh.obj --camera-distance 0.8 --no-auto-orient

Arguments:

  • path: Mesh file or directory
  • -o, --output-path: Output directory (default: ./output/)
  • --debug: Save debug renders and auto-align report to this directory
  • --camera-distance: Camera distance multiplier (default: 1.0)
  • --no-auto-orient: Skip Fibonacci-sphere auto-alignment

Output Format

{
  "coordinates": {"0": [x, y, z], ...},
  "closest_vertex_indexes": {"0": 12345, ...}
}

Contributing

  1. Fork the repository and create a feature branch.
  2. Make your changes with clear commit messages.
  3. Open a pull request.

License

MIT License

Contact

Questions or suggestions? Open an issue on GitHub.

Metadata

Release files for mvmp 1.4.2

For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.

Source distribution (sdist)

Source distribution for mvmp 1.4.2
File Size Uploaded
mvmp-1.4.2.tar.gz 3.4 MB Details

Built distribution (wheel)

Table of built distributions (wheels) for mvmp 1.4.2
File Interpreter ABI Platform
mvmp-1.4.2-py3-none-any.whl Python 3 none any Details

Total release size: 6.7 MB

Release files / mvmp-1.4.2.tar.gz

Download URL mvmp-1.4.2.tar.gz
Size 3.4 MB
Tags Source
SHA-256 checksum
How to use checksums
cb9236f11cde61bd0ff0cb160a14948545d9a000bc479444c4e3033e496da439
BLAKE2b-256 checksum
How to use checksums
2f3e64a57063c3f35f69fee2f20cf31136d4d42cc1c67557d51d98ff0126fff0
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on May 15, 2026.

Transparency log

Release files / mvmp-1.4.2-py3-none-any.whl

Download URL mvmp-1.4.2-py3-none-any.whl
Size 3.4 MB
Tags Python 3
SHA-256 checksum
How to use checksums
667bb767224a9557d64455381d1dc52371455b1d14dd9c75e79032e5d37ef599
BLAKE2b-256 checksum
How to use checksums
2195c14edcc578d4946e3e386cfd227d704c8419bc681270a4591858b6816e95
Upload date
Uploaded using Trusted Publishing?
What is trusted publishing?
Yes
Uploaded via twine/6.1.0 CPython/3.13.12

Provenance

Provenance describes where a file came from. On PyPI, provenance is shared via attestations, which provide a verifiable record of the build or publishing details. View details, limitations and caveats.

PyPI Publish Attestation

PyPI verified that this artifact, at this checksum, originated from the publisher listed below.

Signed by GitHub Actions, verified by PyPI on May 15, 2026.

Transparency log

Release history Release notifications | RSS feed

This release

1.4.2 This release

2 release files

1.4.0

2 release files

1.3.3

2 release files

1.3.2

2 release files

1.3.1

2 release files

1.3.0

2 release files

1.1.1

2 release files

1.1.0

2 release files

1.0.0

2 release files

0.2.13

2 release files

0.2.12

2 release files

0.2.11

2 release files

0.2.10

2 release files

Anthropic, PBC Visionary sponsor Bloomberg Visionary sponsor Hudson River Trading Visionary sponsor Meta Visionary sponsor NVIDIA Visionary sponsor Microsoft Sustainability sponsor Depot Continuous Integration AWS Cloud computing and Security Sponsor Datadog Monitoring Fastly CDN Google Download Analytics Sentry Error logging StatusPage Status page