Skip to content

Commit 4fac214

Browse files
authored
Merge pull request #2 from psavery/paraview_upgrade
Upgrade Tomviz Dependencies
2 parents dd39cc4 + 2af713c commit 4fac214

90 files changed

Lines changed: 484 additions & 749 deletions

File tree

Some content is hidden

Large Commits have some content hidden by default. Use the searchbox below for content that may be hidden.

.azure-pipelines.yml

Lines changed: 0 additions & 112 deletions
This file was deleted.
Lines changed: 104 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,104 @@
1+
name: build and test
2+
3+
on:
4+
push:
5+
branches: [ master ]
6+
pull_request:
7+
branches: [ master ]
8+
9+
jobs:
10+
test:
11+
name: ${{ matrix.config.name }} (Python ${{ matrix.python-version}})
12+
runs-on: ${{ matrix.config.os }}
13+
strategy:
14+
fail-fast: false
15+
matrix:
16+
python-version: [3.11, 3.12, 3.13]
17+
paraview-version: [v6.0.1]
18+
config:
19+
- {
20+
name: Linux,
21+
os: ubuntu-latest
22+
}
23+
24+
defaults:
25+
run:
26+
# Using a login shell is necessary to persist the conda environment
27+
shell: bash -l {0}
28+
29+
steps:
30+
- name: Set up Miniconda
31+
uses: conda-incubator/setup-miniconda@v3
32+
with:
33+
channels: conda-forge
34+
conda-remove-defaults: "true"
35+
auto-update-conda: true
36+
conda-solver: libmamba
37+
python-version: ${{ matrix.python-version }}
38+
activate-environment: tomviz
39+
40+
- name: Checkout Tomviz
41+
uses: actions/checkout@v5
42+
with:
43+
submodules: recursive
44+
path: tomviz
45+
46+
- name: Install Build Requirements
47+
# I can't get the defaults channel fully removed, so we have to
48+
# --override-channels here.
49+
run: |
50+
conda install -y --override-channels -c conda-forge --file tomviz/.github/workflows/build_requirements.txt
51+
# Record the whole build environment for caching
52+
conda env export > build_env.yml
53+
echo "build_env.yml file contents is:"
54+
cat build_env.yml
55+
56+
- name: Checkout ParaView
57+
run: git clone -b ${{ matrix.paraview-version }} --recursive https://gitlab.kitware.com/paraview/paraview
58+
59+
# If nothing in the build environment changes, restore a cache of the
60+
# ParaView build so we can skip rebuilding it and save a lot of time.
61+
- name: Restore ParaView Build Cache
62+
id: cache-paraview-restore
63+
uses: actions/cache/restore@v4
64+
with:
65+
path: paraview-build
66+
key: ${{ matrix.paraview-version }}-paraview-${{ hashFiles('build_env.yml') }}
67+
68+
- name: Build ParaView
69+
if: steps.cache-paraview-restore.outputs.cache-hit != 'true'
70+
run: bash tomviz/.github/workflows/scripts/build_paraview.sh
71+
72+
- name: Save ParaView Build Cache
73+
if: steps.cache-paraview-restore.outputs.cache-hit != 'true'
74+
id: cache-paraview-save
75+
uses: actions/cache/save@v4
76+
with:
77+
path: paraview-build
78+
key: ${{ steps.cache-paraview-restore.outputs.cache-primary-key }}
79+
80+
- name: Build Tomviz
81+
run: bash tomviz/.github/workflows/scripts/build_tomviz.sh
82+
83+
- name: Install Runtime Requirements
84+
# I can't get the defaults channel fully removed, so we have to
85+
# --override-channels here.
86+
run: conda install -y --override-channels -c conda-forge --file tomviz/.github/workflows/runtime_requirements.txt
87+
88+
- name: Install Test Requirements
89+
run: |
90+
conda install -y --override-channels -c conda-forge --file tomviz/tests/python/requirements-dev.txt
91+
pip install --no-build-isolation --no-deps -U tomviz/tomviz/python
92+
pip install --no-build-isolation --no-deps -U tomviz/acquisition
93+
94+
- name: Run Tests
95+
run: |
96+
cd tomviz-build
97+
TOMVIZ_TEST_PYTHON_EXECUTABLE=$(which python3) ctest --output-on-failure
98+
99+
- name: Upload CTest Log (On Failure Only)
100+
if: ${{ failure() }}
101+
uses: actions/upload-artifact@v4
102+
with:
103+
name: TomvizCTestLog.log
104+
path: tomviz-build/Testing/Temporary/LastTest.log
Lines changed: 20 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,20 @@
1+
qt6-main>=6.9.3
2+
cxx-compiler
3+
cmake
4+
ninja
5+
pkg-config
6+
git-lfs
7+
tbb-devel
8+
libprotobuf
9+
cgns
10+
libboost-headers
11+
libzip
12+
libcurl
13+
icu
14+
libharu
15+
# This is needed for building the tests
16+
gtest
17+
# Next three are Linux only
18+
libgl-devel
19+
libegl-devel
20+
libglvnd-devel
Lines changed: 16 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,16 @@
1+
# General runtime dependencies
2+
numpy
3+
scipy
4+
marshmallow
5+
jsonpatch
6+
jsonpointer
7+
pyfftw
8+
pygments
9+
pystackreg
10+
# These are PyXRF workflow dependencies
11+
h5py
12+
pyxrf
13+
xrf-tomo
14+
xraylib
15+
scikit-beam
16+
tomopy
Lines changed: 21 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,21 @@
1+
#!/usr/bin/env bash
2+
3+
mkdir -p paraview-build && cd paraview-build
4+
cmake -G"Ninja" -DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo \
5+
-DCMAKE_INSTALL_LIBDIR:STRING=lib \
6+
-DCMAKE_FIND_FRAMEWORK:STRING=LAST \
7+
-DBUILD_TESTING:BOOL=OFF \
8+
-DPython3_FIND_STRATEGY:STRING=LOCATION \
9+
-DPARAVIEW_ENABLE_CATALYST:BOOL=OFF \
10+
-DPARAVIEW_USE_PYTHON:BOOL=ON \
11+
-DPARAVIEW_ENABLE_WEB:BOOL=OFF \
12+
-DPARAVIEW_ENABLE_EMBEDDED_DOCUMENTATION:BOOL=OFF\
13+
-DPARAVIEW_USE_QTHELP:BOOL=OFF \
14+
-DPARAVIEW_PLUGINS_DEFAULT:BOOL=OFF \
15+
-DPARAVIEW_USE_VISKORES:BOOL=OFF \
16+
-DVTK_SMP_IMPLEMENTATION_TYPE:STRING=TBB \
17+
-DVTK_PYTHON_VERSION:STRING=3 \
18+
-DVTK_PYTHON_FULL_THREADSAFE:BOOL=ON \
19+
-DVTK_NO_PYTHON_THREADS:BOOL=OFF \
20+
../paraview
21+
ninja
Lines changed: 10 additions & 0 deletions
Original file line numberDiff line numberDiff line change
@@ -0,0 +1,10 @@
1+
#!/usr/bin/env bash
2+
3+
mkdir -p tomviz-build && cd tomviz-build
4+
cmake -G"Ninja" -DCMAKE_BUILD_TYPE:STRING=RelWithDebInfo \
5+
-DCMAKE_INSTALL_LIBDIR:STRING=lib \
6+
-DParaView_DIR:PATH=../paraview-build \
7+
-DENABLE_TESTING:BOOL=ON \
8+
-DPython3_FIND_STRATEGY:STRING=LOCATION \
9+
../tomviz
10+
ninja

0 commit comments

Comments
 (0)