Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
Show all changes
79 commits
Select commit Hold shift + click to select a range
d59750a
Add placeholder for Python bindings
w1th0utnam3 Feb 18, 2025
0e91d24
transferred current state
Fek04 Feb 24, 2025
3ec7629
reconstruct_surface aabb parameters
Fek04 Feb 24, 2025
d754f69
reconstruct_surface SpatialDecomposition parameters
Fek04 Feb 24, 2025
f99a80c
single and double precision reconstruct_surface by exposing two methods
Fek04 Feb 25, 2025
348bb01
conda environment file
Fek04 Feb 25, 2025
96fe381
Working on post processing pipeline
Fek04 Feb 25, 2025
3278c81
Post processing in working but unpolished state
Fek04 Feb 27, 2025
aa0f0ab
Exposed reconstruct surface method now infers float precision based o…
Fek04 Feb 27, 2025
7e02a12
Code cleanup
Fek04 Feb 27, 2025
78d4849
Split pyfunctions into their own files
Fek04 Feb 27, 2025
ae21022
Binding of TriMesh and UniformGrid
Fek04 Feb 28, 2025
3d6ac41
SurfaceReconstruction binding
Fek04 Feb 28, 2025
bf67f5a
Dynamic marching cubes cleanup method
Fek04 Feb 28, 2025
396f51e
Dynamic post processing method
Fek04 Feb 28, 2025
85bffe5
Updated docstrings
Fek04 Feb 28, 2025
00f9cfc
More parameters for post processing
Fek04 Feb 28, 2025
bc1dfe3
Removed some copies
Fek04 Mar 6, 2025
b5b2469
Reconstruct surface now as other methods exposed
Fek04 Mar 6, 2025
bc5643f
Decimation
Fek04 Mar 6, 2025
5e5012b
Laplacian smoothing inplace
Fek04 Mar 6, 2025
feda163
MeshWithData struct
Fek04 Mar 7, 2025
ff22fbd
Smoothed normals computation
Fek04 Mar 7, 2025
6d1a6ac
Smoothed normals f64
Fek04 Mar 18, 2025
46dce23
PyMeshWithData struct improvements
Fek04 Mar 18, 2025
0403f90
MeshWithData dynamic python function to push attributes
Fek04 Mar 22, 2025
97cdcfe
PySphInterpolator classes
Fek04 Mar 22, 2025
30ff21f
Normal laplacian smoothing
Fek04 Mar 22, 2025
d70584e
Reconstruction pipeline mostly ported to python
Fek04 Mar 23, 2025
11dda11
TriMesh to MixedTriQuadMesh conversion possible
Fek04 Mar 24, 2025
f3fac1c
Code restructure
Fek04 Mar 24, 2025
afedbc8
Rudimentary Sphinx integration
Fek04 Mar 24, 2025
fde881b
Slight documentation improvements
Fek04 Mar 25, 2025
573ee7d
Workflow to create wheels
Fek04 Mar 25, 2025
cf5f7d4
Started to compare pipeline with binary
Fek04 Mar 25, 2025
e235405
Implemented take methods where possible
Fek04 Mar 27, 2025
dc31f89
Updated python environment file
Fek04 Mar 27, 2025
7184432
Pipeline tests working
Fek04 Mar 27, 2025
f86165e
Wrote reconstruction pipeline in rust
Fek04 Mar 27, 2025
898cb47
MeshWithData improvements
Fek04 Mar 28, 2025
7cfab46
Constructor methods
Fek04 Mar 28, 2025
e366283
Attributes are now written to the ouput file + Better mesh distance t…
Fek04 Mar 29, 2025
6e42ada
Made relevant methods callable with both Mesh and MeshWithData objects
Fek04 Mar 29, 2025
a158d14
All Aabb Methods exposed
Fek04 Mar 31, 2025
55d51ad
SphInterpolator methods
Fek04 Mar 31, 2025
fef5694
Removed Py tag from exposed classes
Fek04 Apr 3, 2025
c66c22b
bgeo file format meshio extension
Fek04 Apr 3, 2025
4189124
Stub file generation using the crate `pyo3-stub-gen`
Fek04 Apr 3, 2025
ebc8c9c
Pipeline can now read and interpolate existing attributes
Fek04 Apr 5, 2025
1433f7f
Pipeline now additionally returns surfacereconstruction object
Fek04 Apr 6, 2025
69ec1a4
Documentation update
Fek04 Apr 6, 2025
f68f7ad
Documentation workflow
Fek04 Apr 7, 2025
36b0c72
Readme update
Fek04 Apr 7, 2025
4393381
Readme embedded in sphinx documentation
Fek04 Apr 7, 2025
de74ce3
Relative splashsurf lib import
Fek04 Apr 9, 2025
f4f877c
Github workflow for calling tests
Fek04 Apr 13, 2025
03fb0fb
MeshWithData attributes to pydict methods
Fek04 Apr 14, 2025
07a4583
Write to file method
Fek04 Apr 14, 2025
7629c6a
Convert Tris to Quads Method now compatible with MeshWithData objects
Fek04 Apr 14, 2025
d6241c0
Readme update
Fek04 Apr 14, 2025
01ffbe7
Combine actions in CI
Fek04 Apr 14, 2025
3b2d15b
Made meshio support optional
Fek04 Apr 14, 2025
a0f7fd0
Slight Documentation update
Fek04 Apr 14, 2025
0f07840
Rebased on main
Fek04 Apr 14, 2025
71aeecd
Docs + Metadata improvements
Fek04 Apr 15, 2025
fc53a80
Meshio optional dependency explained in Readme
Fek04 Apr 16, 2025
0c43862
Update readme
w1th0utnam3 Jun 5, 2025
810291b
Update default parameters
w1th0utnam3 Jun 5, 2025
cd57c85
Update some comments
w1th0utnam3 Jun 5, 2025
86d8f70
Update pyproject.toml
w1th0utnam3 Jun 5, 2025
ae53609
Update CI workflow for bindings
w1th0utnam3 Jun 5, 2025
848e677
Add push trigger to Python workflow
w1th0utnam3 Jun 6, 2025
80cbf19
Add license
w1th0utnam3 Jun 6, 2025
91d38dd
Update dependencies
w1th0utnam3 Jun 6, 2025
1b1a5eb
Fix
w1th0utnam3 Jun 6, 2025
3e6a4d4
Fix typo
w1th0utnam3 Jun 6, 2025
afcacc0
Run cargo fmt
w1th0utnam3 Jun 6, 2025
1741d0e
Some code cleanup
w1th0utnam3 Jun 6, 2025
16682b8
Run check fmt in python project
w1th0utnam3 Jun 6, 2025
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
274 changes: 274 additions & 0 deletions .github/workflows/pysplashsurf_CI.yml
Original file line number Diff line number Diff line change
@@ -0,0 +1,274 @@
# This file is autogenerated by maturin v1.8.2
# To update, run
#
# maturin generate-ci github
#
name: PySplashsurf CI

on:
push:
workflow_dispatch:
release:
types: [published]

permissions:
contents: read

jobs:
check_format:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Check formatting of PySplashsurf
run: cargo fmt -- --check
working-directory: pysplashsurf

generate-stub:
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v3
- uses: moonrepo/setup-rust@v1
- run: |
cargo run --bin stub_gen
working-directory: pysplashsurf
- name: Upload stub as artifact
uses: actions/upload-artifact@v4
with:
name: pysplashsurf.pyi
path: pysplashsurf/pysplashsurf/

linux:
needs: generate-stub
runs-on: ${{ matrix.platform.runner }}
strategy:
matrix:
platform:
- runner: ubuntu-24.04
target: x86_64
- runner: ubuntu-24.04
target: x86
- runner: ubuntu-24.04
target: aarch64
- runner: ubuntu-24.04
target: armv7
steps:
- uses: actions/checkout@v4
- name: Download stub artifact
uses: actions/download-artifact@v4
with:
name: pysplashsurf.pyi
path: pysplashsurf/pysplashsurf/
- uses: actions/setup-python@v5
with:
python-version: 3.x
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.platform.target }}
args: --release --out dist -m pysplashsurf/Cargo.toml
# sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
manylinux: auto
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: wheels-linux-${{ matrix.platform.target }}
path: dist

windows:
needs: generate-stub
runs-on: ${{ matrix.platform.runner }}
strategy:
matrix:
platform:
- runner: windows-latest
target: x64
- runner: windows-latest
target: x86
steps:
- uses: actions/checkout@v4
- name: Download stub artifact
uses: actions/download-artifact@v4
with:
name: pysplashsurf.pyi
path: pysplashsurf/pysplashsurf/
- uses: actions/setup-python@v5
with:
python-version: 3.x
architecture: ${{ matrix.platform.target }}
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.platform.target }}
args: --release --out dist -m pysplashsurf\Cargo.toml
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: wheels-windows-${{ matrix.platform.target }}
path: dist

macos:
needs: generate-stub
runs-on: ${{ matrix.platform.runner }}
strategy:
matrix:
platform:
- runner: macos-13
target: x86_64
- runner: macos-14
target: aarch64
steps:
- uses: actions/checkout@v4
- name: Download stub artifact
uses: actions/download-artifact@v4
with:
name: pysplashsurf.pyi
path: pysplashsurf/pysplashsurf/
- uses: actions/setup-python@v5
with:
python-version: 3.x
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: ${{ matrix.platform.target }}
args: --release --out dist -m pysplashsurf/Cargo.toml
sccache: ${{ !startsWith(github.ref, 'refs/tags/') }}
- name: Upload wheels
uses: actions/upload-artifact@v4
with:
name: wheels-macos-${{ matrix.platform.target }}
path: dist

sdist:
needs: generate-stub
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- name: Download stub artifact
uses: actions/download-artifact@v4
with:
name: pysplashsurf.pyi
path: pysplashsurf/pysplashsurf/
- name: Build sdist
uses: PyO3/maturin-action@v1
with:
command: sdist
args: --out dist -m pysplashsurf/Cargo.toml
- name: Upload sdist
uses: actions/upload-artifact@v4
with:
name: wheels-sdist
path: dist

release:
name: Release
runs-on: ubuntu-latest
if: ${{ startsWith(github.ref, 'refs/tags/v') || github.event_name == 'workflow_dispatch' }}
needs: [linux, windows, macos, sdist]
permissions:
# Use to sign the release artifacts
id-token: write
# Used to upload release artifacts
contents: write
# Used to generate artifact attestation
attestations: write
steps:
- uses: actions/download-artifact@v4
#- name: Generate artifact attestation
# uses: actions/attest-build-provenance@v1
# with:
# subject-path: 'wheels-*/*'
- name: Publish to PyPI
#if: ${{ startsWith(github.ref, 'refs/tags/') }}
uses: PyO3/maturin-action@v1
env:
MATURIN_PYPI_TOKEN: ${{ secrets.PYPI_API_TOKEN }}
with:
command: upload
args: --non-interactive --skip-existing wheels-*/*

build_wheel:
runs-on: ubuntu-latest
outputs:
filename: ${{ steps.get_filename.outputs.file_name }}
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: 3.x
- name: Build wheels
uses: PyO3/maturin-action@v1
with:
target: x86_64
args: --release --out dist -m pysplashsurf/Cargo.toml
manylinux: auto
- name: Get wheel name
id: get_filename
run: |
FILE_NAME=$(ls dist)
echo "file_name=$FILE_NAME" >> $GITHUB_OUTPUT
- name: Upload wheel
uses: actions/upload-artifact@v4
with:
name: doc_tests_wheel
path: dist

docs:
needs: build_wheel
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: 3.x
- name: Download wheel
uses: actions/download-artifact@v4
with:
name: doc_tests_wheel
path: dist/
- name: Append output to file
run: |
echo "./dist/${{ needs.build_wheel.outputs.filename }}" >> pysplashsurf/pysplashsurf/docs/requirements.txt
- uses: ammaraskar/[email protected]
with:
docs-folder: "pysplashsurf/pysplashsurf/docs/"
- uses: actions/upload-artifact@v4
with:
name: DocumentationHTML
path: pysplashsurf/pysplashsurf/docs/build/html/

tests:
needs: build_wheel
defaults:
run:
shell: bash -l {0}
runs-on: ubuntu-latest
steps:
- uses: actions/checkout@v4
- uses: actions/setup-python@v5
with:
python-version: 3.x
- uses: mamba-org/setup-micromamba@v2
with:
environment-file: pysplashsurf/python_environment.yaml
init-shell: >-
bash
- run: |
conda info
conda list
- name: Download wheel
uses: actions/download-artifact@v4
with:
name: doc_tests_wheel
path: dist/
- run: pip install dist/${{ needs.build_wheel.outputs.filename }}
- name: Install splashsurf CLI
run: cargo install splashsurf
- name: Run pytest
uses: pavelzw/pytest-action@v2
with:
verbose: true
emoji: false
job-summary: true
click-to-expand: true
report-title: 'Pytest Report'
12 changes: 12 additions & 0 deletions pysplashsurf/.gitignore
Original file line number Diff line number Diff line change
@@ -0,0 +1,12 @@
dist/
*.egg-info/
target/
**/__pycache__/
*.so
test.vtk
test_bin.vtk
env/
envs/

# Sphinx
pysplashsurf/docs/build/
Loading
Loading