Skip to content
Closed
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
24 changes: 24 additions & 0 deletions .github/workflows/python-package.yml
Original file line number Diff line number Diff line change
Expand Up @@ -31,6 +31,8 @@ jobs:
compiler: clang-19
- name: macos-clang
os: macos-latest
- name: windows-msvc
os: windows-latest

runs-on: ${{ matrix.os }}
container: ${{ matrix.container }}
Expand Down Expand Up @@ -58,17 +60,39 @@ jobs:
python-version: ${{ matrix.python-version }}

- name: Install Python dependencies
if: matrix.os != 'windows-latest'
run: |
python3 -m pip install --upgrade pip --break-system-packages
python3 -m pip install pytest scikit-learn pandas matplotlib --break-system-packages

- name: Install Python dependencies
if: matrix.os == 'windows-latest'
run: |
python -m pip install --upgrade pip
python -m pip install pytest scikit-learn pandas matplotlib

- name: Compile CLUEstering modules
if: matrix.os != 'windows-latest'
working-directory: ${{ github.workspace }}
run: |
cmake -S . -B build -DBUILD_PYTHON=ON -DCMAKE_BUILD_TYPE=Release
cmake --build build --parallel

- name: Compile CLUEstering modules
if: matrix.os == 'windows-latest'
working-directory: ${{ github.workspace }}
run: |
cmake -S . -B build -DBUILD_PYTHON=ON -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE="$env:VCPKG_INSTALLATION_PATH/scripts/buildsystems/vcpkg.cmake" -DVCPKG_TARGET_TRIPLET=x64-windows
cmake --build build --parallel --config Release

- name: Run tests of the Python library
if: matrix.os != 'windows-latest'
working-directory: ${{github.workspace}}/tests
run: |
python3 -m pytest ./*.py

- name: Run tests of the Python library
if: matrix.os == 'windows-latest'
working-directory: ${{github.workspace}}/tests
run: |
python -m pytest *.py
13 changes: 12 additions & 1 deletion .github/workflows/test-cpp-interface.yml
Original file line number Diff line number Diff line change
Expand Up @@ -46,6 +46,8 @@ jobs:
compiler: clang-19
- name: macos-clang
os: macos-latest
- name: windows
os: windows-latest

runs-on: ${{ matrix.os }}
container: ${{ matrix.container }}
Expand Down Expand Up @@ -74,7 +76,7 @@ jobs:
submodules: true

- name: Compile and run tests
if: matrix.container != 'almalinux:9'
if: matrix.container != 'almalinux:9' && matrix.os != 'windows-latest'
working-directory: ${{ github.workspace }}/tests
run: |
cmake -B build -DCMAKE_BUILD_TYPE=Release
Expand All @@ -89,3 +91,12 @@ jobs:
cmake -B build -DCMAKE_BUILD_TYPE=Release
cmake --build build --parallel
ctest --test-dir build --output-on-failure

- name: Compile and run tests
if: matrix.os == 'windows-latest'
working-directory: ${{ github.workspace }}/tests
run: |
# cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE="$env:VCPKG_INSTALLATION_PATH/scripts/buildsystems/vcpkg.cmake" -DVCPKG_TARGET_TRIPLET=x64-windows
cmake -B build -DCMAKE_BUILD_TYPE=Release -DCMAKE_TOOLCHAIN_FILE="$env:VCPKG_ROOT/scripts/buildsystems/vcpkg.cmake" -DVCPKG_TARGET_TRIPLET=x64-windows
cmake --build build --parallel --config Release
ctest --test-dir build --output-on-failure --build-config Release
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@
[![Documentation](https://img.shields.io/badge/docs-latest-blue)](https://cms-patatrack.github.io/CLUEstering/)
[![codecov](https://codecov.io/gh/cms-patatrack/CLUEstering/graph/badge.svg?token=JV53J6IUJ3)](https://codecov.io/gh/cms-patatrack/CLUEstering)
![PyPI](https://img.shields.io/pypi/v/CLUEstering)
[![Platforms](https://img.shields.io/badge/platform-linux%20%7C%20mac-blue.svg)](https://github.com/cms-patatrack/CLUEstering)
[![Platforms](https://img.shields.io/badge/platform-linux%20%7C%20mac%20%7C%20windows-blue.svg)](https://github.com/cms-patatrack/CLUEstering)
[![License](https://img.shields.io/badge/license-MPL--2.0-blue.svg)](https://www.mozilla.org/en-US/MPL/2.0/)

<p align="center">
Expand Down
5 changes: 4 additions & 1 deletion tests/CMakeLists.txt
Original file line number Diff line number Diff line change
Expand Up @@ -18,7 +18,10 @@ set(CMAKE_CXX_FLAGS_RELEASE
" -O2 -funroll-loops -funsafe-math-optimizations -ftree-vectorize -march=native"
)

find_package(Boost 1.75.0 REQUIRED COMPONENTS atomic)
set(Boost_USE_STATIC_LIBS OFF)
set(Boost_USE_MULTITHREADED ON)

find_package(Boost REQUIRED COMPONENTS atomic)

include(FetchContent)

Expand Down
13 changes: 11 additions & 2 deletions vcpkg.json
Original file line number Diff line number Diff line change
Expand Up @@ -3,6 +3,15 @@
"version-string": "2.9.0",
"description": "Header-only density-based weighted clustering using alpaka",
"homepage": "https://github.com/cms-patatrack/CLUEstering",
"dependencies": ["alpaka"],
"dev-dependencies": ["doctest", "benchmark", "fmt"]
"dependencies": ["alpaka","boost"],
"features": {
"tests": {
"description": "Build tests",
"dependencies": ["doctest", "fmt"]
},
"benchmarks": {
"description": "Build benchmarks",
"dependencies": ["benchmark"]
}
}
}
Loading