Skip to main content

Pure Python implementation of CLNF (Constrained Local Neural Fields) facial landmark detector

Project description

pyclnf

Pure Python implementation of OpenFace's CLNF (Constrained Local Neural Fields) facial landmark detector.

Installation

pip install pyclnf

Usage

from pyclnf import CLNF

clnf = CLNF()
landmarks, pose = clnf.fit(image)  # 68 facial landmarks + head pose

For video, use clnf.fit() on consecutive frames—it automatically tracks faces across frames.

What it does

  • Detects 68 facial landmarks
  • Estimates 3D head pose (pitch, yaw, roll)
  • Uses OpenFace's trained CEN patch experts
  • Built-in face detection via pymtcnn

Citation

If you use this in research, please cite:

Wilson IV, J., Rosenberg, J., Gray, M. L., & Razavi, C. R. (2025). A split-face computer vision/machine learning assessment of facial paralysis using facial action units. Facial Plastic Surgery & Aesthetic Medicine. https://doi.org/10.1177/26893614251394382

License

CC BY-NC 4.0 — free for non-commercial use with attribution.

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

pyclnf-0.2.1.tar.gz (5.9 MB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

pyclnf-0.2.1-py3-none-any.whl (11.5 MB view details)

Uploaded Python 3

File details

Details for the file pyclnf-0.2.1.tar.gz.

File metadata

  • Download URL: pyclnf-0.2.1.tar.gz
  • Upload date:
  • Size: 5.9 MB
  • Tags: Source
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyclnf-0.2.1.tar.gz
Algorithm Hash digest
SHA256 ef026e1338b0badbab6f0c9127edc0ecfc670b2b50fb74db3e286b7fe04004d1
MD5 dfcf91e2097a4d50464c2a947c3a889a
BLAKE2b-256 6c7553ff4b5cc54f9e372a1cbd16eaa5043d3d343d9d5630b93d46a035ff953b

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyclnf-0.2.1.tar.gz:

Publisher: publish.yml on johnwilsoniv/pyclnf

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

File details

Details for the file pyclnf-0.2.1-py3-none-any.whl.

File metadata

  • Download URL: pyclnf-0.2.1-py3-none-any.whl
  • Upload date:
  • Size: 11.5 MB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? Yes
  • Uploaded via: twine/6.1.0 CPython/3.13.7

File hashes

Hashes for pyclnf-0.2.1-py3-none-any.whl
Algorithm Hash digest
SHA256 77fde4e151fabfbc30ec2d3b52cdb30f650279becc6ceaa0f077543d887d1b0a
MD5 2f073c908e42c465e314b7566bfa021a
BLAKE2b-256 7967cfb2ff4ed1b3ca72827b5b07f5a8126b5f5070f70e11ff032b36a8cde6de

See more details on using hashes here.

Provenance

The following attestation bundles were made for pyclnf-0.2.1-py3-none-any.whl:

Publisher: publish.yml on johnwilsoniv/pyclnf

Attestations: Values shown here reflect the state when the release was signed and may no longer be current.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page