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
5 changes: 3 additions & 2 deletions CHANGES.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,15 +2,16 @@

## v3.9.0
- VM: set the matplotlib backend to tkagg
- Updated versions (when building the packages):
- CIL: 4f6e3cfb0648d08071974eba35c1369a892d4924
- Updated Versions:
- CIL: v25.0.0
- STIR: 6.3.0
- SIRF: 3.9.0
- ITK: 5.4.4
- parallelproj: 1.10.2
- boost: 1.88.0
- CMake:
- Use [new `FindPython` module](https://cmake.org/cmake/help/latest/module/FindPython.html). You might need to help it find the correct Python path, e.g. by setting `Python_ROOT_DIR`.
- Use `IPP_ROOT` instead of `IPP_LIBRARY` (for `BUILD_CIL`)
- Suppress compilation warnings for Gadgetron for future compatibility (as Gadgetron converts them to errors)
- Support the `Gadgetron_EXTRA_CMAKE_ARGS` option

Expand Down
15 changes: 10 additions & 5 deletions README.md
Original file line number Diff line number Diff line change
Expand Up @@ -355,13 +355,18 @@ Notice that other packages may look for a blas implementation issuing CMake's [`

### Building CCPi CIL

It is possible to build the [CCPi Core Imaging Library CIL](https://www.ccpi.ac.uk/CIL) as part of the SuperBuild. The functionality of `CIL` can be expanded by plugins. Currently available: [`CCPi-Regularisation`](https://github.com/vais-ral/CCPi-Regularisation-Toolkit), [`TomoPhantom`](https://github.com/dkazanc/TomoPhantom) [ASTRA-toolbox](https://github.com/astra-toolbox/astra-toolbox) and [`TIGRE`](https://github.com/CERN/TIGRE)).
The [CCPi Core Imaging Library (CIL)](https://www.ccpi.ac.uk/CIL) is included in the SuperBuild. The functionality of `CIL` can be expanded by plugins. Currently included by default are:

There is one mandatory flag and 2 optional:
<!-- TODO: mention BUILD_ASTRA etc CMake flags, and check that they remove from requirements.yml -->

- `BUILD_CIL=ON`, will build `CIL` and all the following plugins: `CCPi-Regularisation` and `TomoPhantom`; default `OFF`
- Optional `IPP_LIBRARY=<location of IPP shared libraries>` and `IPP_INCLUDE=<location of IPP includes>` if you want to build CIL with [IPP](https://www.intel.com/content/www/us/en/developer/tools/oneapi/ipp.html#gs.dnfk5r) support for optimised [FBP/FDK](https://github.com/TomographicImaging/CIL#dependency) .
- Optional `BUILD_ASTRA=ON`, if you want to use CIL for CT reconstruction with the ASTRA-toolbox engine. Default `OFF`
- [`CCPi-Regularisation`](https://github.com/TomographicImaging/CCPi-Regularisation-Toolkit)
- [`TomoPhantom`](https://github.com/dkazanc/TomoPhantom)
- [IPP](https://www.intel.com/content/www/us/en/developer/tools/oneapi/ipp.html#gs.dnfk5r) support for optimised [FBP/FDK](https://github.com/TomographicImaging/CIL#dependency)
- (requires CUDA) [ASTRA-toolbox](https://github.com/astra-toolbox/astra-toolbox) for CT reconstruction

Optional dependencies include:

- (requires CUDA) [`TIGRE`](https://github.com/CERN/TIGRE)

### Passing CMake arguments to specific projects

Expand Down
4 changes: 3 additions & 1 deletion SuperBuild.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -311,7 +311,9 @@ if ("${PYTHON_STRATEGY}" STREQUAL "CONDA")
set (BUILD_CIL OFF)
endif()
if (BUILD_CIL)
list(APPEND ${PRIMARY_PROJECT_NAME}_DEPENDENCIES CIL CCPi-Regularisation-Toolkit TomoPhantom)
list(APPEND ${PRIMARY_PROJECT_NAME}_DEPENDENCIES CIL CCPi-Regularisation-Toolkit)
# TODO: once TomoPhantom adds numpy>=2 support:
# list(APPEND ${PRIMARY_PROJECT_NAME}_DEPENDENCIES CIL CCPi-Regularisation-Toolkit TomoPhantom)
endif()
if (BUILD_ASTRA)
list(APPEND ${PRIMARY_PROJECT_NAME}_DEPENDENCIES astra-python-wrapper)
Expand Down
23 changes: 5 additions & 18 deletions SuperBuild/External_CIL.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -42,13 +42,8 @@ if(NOT ( DEFINED "USE_SYSTEM_${externalProjName}" AND "${USE_SYSTEM_${externalPr
# Sets ${proj}_URL_MODIFIED and ${proj}_TAG_MODIFIED
SetGitTagAndRepo("${proj}")

# Pass IPP_INCLUDE And IPP_LIBRARY if they exist

if (IPP_LIBRARY)
set(DIPP_LIBRARY "-DIPP_LIBRARY:STRING=${IPP_LIBRARY}")
endif()
if (IPP_INCLUDE)
set(DIPP_INCLUDE "-DIPP_INCLUDE:STRING=${IPP_INCLUDE}")
if (IPP_ROOT)
set(DIPP_ROOT "-Ccmake.define.IPP_ROOT=${IPP_ROOT}")
endif()

# conda build should never get here
Expand All @@ -73,17 +68,9 @@ if(NOT ( DEFINED "USE_SYSTEM_${externalProjName}" AND "${USE_SYSTEM_${externalPr
# external projects
PATCH_COMMAND ${Python_EXECUTABLE} ${CMAKE_SOURCE_DIR}/patches/cil-patch.py ${${proj}_SOURCE_DIR}/Wrappers/Python/cil/utilities/dataexample.py
UPDATE_COMMAND ""
CONFIGURE_COMMAND ${CMAKE_COMMAND} -E env CIL_VERSION=${${proj}_TAG}
${CMAKE_COMMAND} -G "${CMAKE_GENERATOR}" -S ${${proj}_SOURCE_DIR}
-DCMAKE_INSTALL_PREFIX:PATH=${${proj}_INSTALL_DIR}
-DCMAKE_BUILD_TYPE:STRING=${CMAKE_BUILD_TYPE}
${PYTHONLIBS_CMAKE_ARGS}
-DPYTHON_DEST_DIR:PATH=${PYTHON_DEST}
-DCIL_VERSION:STRING=${${proj}_TAG}
${DIPP_INCLUDE}
${DIPP_LIBRARY}
BUILD_COMMAND ${CMAKE_COMMAND} --build . --config ${_config}
INSTALL_COMMAND ${CMAKE_COMMAND} --build . --config ${_config} --target install
CONFIGURE_COMMAND ""
BUILD_COMMAND ""
INSTALL_COMMAND ${CMAKE_COMMAND} -E env ${Python_EXECUTABLE} -m pip install ${${proj}_SOURCE_DIR} ${DIPP_ROOT} -Ccmake.build-type=${config} -Ccmake.args="-G ${CMAKE_GENERATOR}"
&& ${CMAKE_COMMAND} -E copy_directory ${${proj}_SOURCE_DIR}/Wrappers/Python/data ${SUPERBUILD_INSTALL_DIR}/share/cil/
DEPENDS ${${proj}_DEPENDENCIES}
)
Expand Down
2 changes: 2 additions & 0 deletions docker/docker-compose.gpu.yml
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ services:
BASE_CONTAINER: synerbi/jupyter:scipy-gpu
BUILD_GPU: 1
Gadgetron_USE_CUDA: "ON"
BUILD_CIL: "ON"
sirf:
deploy: {resources: {reservations: {devices: [{driver: nvidia, count: all, capabilities: [gpu]}]}}}
image: synerbi/sirf:latest-gpu
Expand All @@ -35,4 +36,5 @@ services:
BASE_CONTAINER: synerbi/jupyter:scipy-gpu
BUILD_GPU: 1
Gadgetron_USE_CUDA: "ON"
BUILD_CIL: "ON"
cache_from: [synerbi/jupyter:sirf-build-gpu]
6 changes: 3 additions & 3 deletions docker/requirements.yml
Original file line number Diff line number Diff line change
Expand Up @@ -32,9 +32,9 @@ dependencies:
- cil-data >=21.3.0 # cil
- ipp >=2021.10 # cil
- tqdm # cil
- numba # cil
# - tigre # cil (GPU)
# - astra-toolbox # cil (GPU)
- numba # cil
## - tigre # cil (GPU) # TODO: remove second # prefix once tigre is build for numpy>=2
# - astra-toolbox 2 cuda* # cil (GPU)
- pip:
- git+https://github.com/ismrmrd/ismrmrd-python-tools.git@master#egg=ismrmrd-python-tools
# TODO: labextension @jupyter-widgets/jupyterlab-manager (jupyterlab_widgets ipywidgets ipympl)
Expand Down
5 changes: 2 additions & 3 deletions version_config.cmake
Original file line number Diff line number Diff line change
Expand Up @@ -143,7 +143,7 @@ set(DEFAULT_STIR_TAG rel_6.3.0)

## SIRF
set(DEFAULT_SIRF_URL https://github.com/SyneRBI/SIRF)
set(DEFAULT_SIRF_TAG v3.9.0)
set(DEFAULT_SIRF_TAG "0ba22c9b5d8b6c2f008e0b1e1846c059703a88c3") # 2025-11-03

## pet-rd-tools
set(DEFAULT_pet_rd_tools_URL https://github.com/UCL/pet-rd-tools)
Expand All @@ -161,9 +161,8 @@ set(DEFAULT_JSON_URL https://github.com/nlohmann/json)
set(DEFAULT_JSON_TAG v3.11.3)

# CCPi CIL
# minimum supported version of CIL supported is > 22.1.0 or from commit a6062410028c9872c5b355be40b96ed1497fed2a
set(DEFAULT_CIL_URL https://github.com/TomographicImaging/CIL)
set(DEFAULT_CIL_TAG 4f6e3cfb0648d08071974eba35c1369a892d4924) # 23/08/24
set(DEFAULT_CIL_TAG "numpy-2")

set(DEFAULT_CCPi-Regularisation-Toolkit_URL https://github.com/TomographicImaging/CCPi-Regularisation-Toolkit)
set(DEFAULT_CCPi-Regularisation-Toolkit_TAG "v24.0.1")
Expand Down
Loading