Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
35 changes: 19 additions & 16 deletions .github/workflows/tests.yml
Original file line number Diff line number Diff line change
Expand Up @@ -11,22 +11,25 @@ jobs:
strategy:
fail-fast: false
matrix:
os: [ubuntu-22.04, windows-2022, macos-14]
python-version: ['3.9', '3.10', '3.11', '3.12']
os: [ubuntu-latest, windows-latest, macos-latest]
python-version: ["3.9", "3.10", "3.11", "3.12", "3.13", "3.14"]
exclude:
- os: macos-14
python-version: '3.9' #macos-14 & py39 not supported by setup-python@v5
python-version: "3.9" #macos-14 & py39 not supported by setup-python@v5
steps:
- uses: actions/checkout@v4
with:
submodules: True
- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}
- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install tox tox-gh-actions
- name: Test with tox
run: tox
- uses: actions/checkout@v5
with:
submodules: True

- name: Set up Python ${{ matrix.python-version }}
uses: actions/setup-python@v5
with:
python-version: ${{ matrix.python-version }}

- name: Install dependencies
run: |
python -m pip install --upgrade pip
python -m pip install tox tox-gh-actions

- name: Test with tox
run: tox
14 changes: 6 additions & 8 deletions .github/workflows/wheels.yml
Original file line number Diff line number Diff line change
Expand Up @@ -7,32 +7,30 @@ on:
tags: ["*"]
pull_request:
branches: ["*"]


jobs:
build_wheels:
name: Build wheels on ${{ matrix.os }}
runs-on: ${{ matrix.os }}
strategy:
matrix:
os: [ubuntu-latest, windows-latest, macos-13, macos-latest]
os: [ubuntu-latest, windows-latest, macos-latest]
fail-fast: false

steps:
- uses: actions/checkout@v4
- uses: actions/checkout@v5
with:
submodules: True

# Used to host cibuildwheel
- uses: actions/setup-python@v5
with:
python-version: "3.13"

- name: Install cibuildwheel
run: python -m pip install cibuildwheel==2.22.0

- name: Build wheels
run: python -m cibuildwheel --output-dir wheelhouse
uses: pypa/cibuildwheel@v3.2.0
with:
output-dir: wheelhouse

- uses: actions/upload-artifact@v4
with:
Expand Down
8 changes: 4 additions & 4 deletions include/pca.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -79,14 +79,14 @@ static inline PCAResult<real_t> pca_from_pointcloud(const PointCloud<real_t>& cl
Eigen::SelfAdjointEigenSolver<Eigen::Matrix<real_t, 3, 3>> es(cov);

// Sort the values and vectors in order of increasing eigenvalue
const auto ev = es.eigenvalues();
const auto& ev = es.eigenvalues();

// Clamp eigen values
Vec3<real_t> val = {(std::max(ev(0), real_t(0.))), (std::max(ev(1), real_t(0.))), (std::max(ev(2), real_t(0.)))};
Vec3<real_t> val = {(std::max(ev(2), real_t(0.))), (std::max(ev(1), real_t(0.))), (std::max(ev(0), real_t(0.)))};

Vec3<real_t> v0 = es.eigenvectors().col(0);
Vec3<real_t> v0 = es.eigenvectors().col(2);
Vec3<real_t> v1 = es.eigenvectors().col(1);
Vec3<real_t> v2 = es.eigenvectors().col(2);
Vec3<real_t> v2 = es.eigenvectors().col(0);

// To standardize the orientation of eigenvectors, we choose to enforce all eigenvectors
// to be expressed in the Z+ half-space.
Expand Down
13 changes: 7 additions & 6 deletions pyproject.toml
Original file line number Diff line number Diff line change
@@ -1,17 +1,17 @@
[build-system]
requires = [
"scikit-build-core >=0.4.3",
"nanobind == 2.1.0",
"nanobind == 2.9.2",
"typing_extensions;python_version < '3.11'",
]
build-backend = "scikit_build_core.build"

[project]
name = "pgeof"
version = "0.3.3"
version = "0.3.4"
readme = "README.md"
description = "Compute the geometric features associated with each point's neighborhood:"
requires-python = ">=3.8,<3.14"
description = "Compute the geometric features associated with each point's neighborhood"
requires-python = ">=3.8,<3.15"
license = { file = "LICENSE" }
authors = [
{ name = "Loic Landrieu", email = "loic.landrieu@enpc.fr" },
Expand Down Expand Up @@ -39,7 +39,7 @@ build-dir = "build/{wheel_tag}"
cmake.build-type = "Release"

# make sdist a lot lighter by removing some useless files from third_party
# ⚠️ be sure to keep copyrights and license file
# ⚠️ be sure to keep copyrights and license file
sdist.exclude = [
"third_party/eigen/bench",
"third_party/eigen/demos",
Expand Down Expand Up @@ -91,6 +91,7 @@ python =
3.11: py311
3.12: py312
3.13: py313
3.14: py314

[testenv]
deps =
Expand All @@ -107,7 +108,7 @@ commands = pytest -s --basetemp="{envtmpdir}" {posargs:tests/bench_knn.py tests/
"""

[tool.cibuildwheel]
build = "cp3{8,9,10,11,12,13}-*"
build = "cp3{8,9,10,11,12,13,14}-*"
archs = ["auto64"] # limits to 64bits builds
skip = "cp38-macosx_arm64"

Expand Down
2 changes: 1 addition & 1 deletion third_party/eigen
Submodule eigen updated from 314739 to 549bf8
6 changes: 3 additions & 3 deletions uv.lock

Some generated files are not rendered by default. Learn more about how customized files appear on GitHub.