Skip to content

UniFace: A Unified Face Analysis Library for Python | Detection, alignment, landmarks, face-mesh, recognition, parsing, gaze, attributes and anti-spoofing under one API.

feat: Add Python 3.14 support (#95)

Marc-Antoine BERTIN8db05779913e
diff --git a/.github/workflows/ci.yml b/.github/workflows/ci.yml
index 2c6c2b9..7143d02 100644
--- a/.github/workflows/ci.yml
+++ b/.github/workflows/ci.yml
@@ -37,6 +37,8 @@ jobs:
python-version: "3.10"
- os: ubuntu-latest
python-version: "3.13"
+ - os: ubuntu-latest
+ python-version: "3.14"
- os: macos-latest
python-version: "3.13"
- os: windows-latest
diff --git a/pyproject.toml b/pyproject.toml
index 26f0181..d4f2bff 100644
--- a/pyproject.toml
+++ b/pyproject.toml
@@ -9,7 +9,7 @@ maintainers = [
{ name = "Yakhyokhuja Valikhujaev", email = "[email protected]" },
]
-requires-python = ">=3.10,<3.14"
+requires-python = ">=3.10,<3.15"
keywords = [
"face-detection",
"face-recognition",
@@ -38,6 +38,7 @@ classifiers = [
"Programming Language :: Python :: 3.11",
"Programming Language :: Python :: 3.12",
"Programming Language :: Python :: 3.13",
+ "Programming Language :: Python :: 3.14",
]
dependencies = [
diff --git a/uniface/face_utils.py b/uniface/face_utils.py
index be08775..f22babd 100644
--- a/uniface/face_utils.py
+++ b/uniface/face_utils.py
@@ -71,8 +71,7 @@ def estimate_norm(
alignment[:, 0] += diff_x
# Compute the transformation matrix
- transform = SimilarityTransform()
- transform.estimate(landmark, alignment)
+ transform = SimilarityTransform.from_estimate(landmark, alignment)
matrix = transform.params[0:2, :]
inverse_matrix = np.linalg.inv(transform.params)[0:2, :]