Skip to content

v6.4.0

Latest

Choose a tag to compare

@KrisThielemans KrisThielemans released this 27 May 16:32
· 4 commits to master since this release

Summary of changes in STIR release 6.4

Overall summary

This version is 100% backwards compatible with STIR 6.3, aside from bug fixes.

This is a release with an important TOF bug fix, considerable improvements in the Python interface, support for libparallelproj 2, speed-up in CUDA code and normalisation code, and example/documentation improvements (including an example script to process Siemens Quadra data from e7tools output). Of course, there is also the usual code-cleanup.

Main code contributions were by Kris Thielemans (UCL), Zekai Li (UMCG), Denis Prokopenko (KCL), Nicole Jurjew (UCL), Markus Jehl (Positrigo), Dimitra Kyriakopoulou (Academy of Athens). Thanks also to Christian Hinge (U Copenhagen) for additional testing of Quadra reconstructions.
Overall overview and release management was by Kris Thielemans (UCL).

Patch release info

Summary for end users (also to be read by developers)

Bug fixes

  • An important bug fix for the "ray tracing matrix" (or actually any "matrix") projector for TOF PET. Previously, oblique segments had
    problems, see # 1537.
    # 1675. Extra tests were
    introduced in # 1674.
  • ArcCorrection should now work correctly for TOF data (although we don't use it).
    PR #1712.
  • Fixed a small memory leak in scatter estimation caused by multiple calls to ProjDataInfo::clone() combined with dynamic_cast. The
    object is now cloned once and ownership is transferred safely after type checking.
    PR #1673
  • Vision 600 and Quadra default Scanner definitions now have a view-offset such that STIR reconstructed images match e7tools output.
    PR #1675.

New functionality

General

  • The STIR wrapper to Parallelproj now has restrict_to_cylindrical_FOV variable/keyword (defaulting to true), identical to what is used in
    the ray-tracing matrix.
    PR #1261.

Python

  • The Python interface has been improved, especially related to "downcasting" of return values of most hierarchies, including
    ProjDataInfo, images, ExamData, priors/penalties, objective functions.
    PR #1712.

  • STIR is now installed as a Python module, but this should be backwards compatible (aside from the renames of some examples). The stirextra module is now a submodule, so use stir.extra instead (although the former will work, but with a warning). Some of the more useful examples, including Vision_files_preprocess.py, are now installed as part of the module, to make them easy to call. You can now for instance do

    python -m stir.projdata_visualisation -h
    

    and in Python

    import stir
    from stir.projdata_visualisation import launch_GUI
    launch_GUI('proj_data_filename')
    

    See PR #1713 for more details.

  • Example script Quadra_files_preprocess.py to convert e7tools output for the Siemens Biograph Quadra to STIR compatible files (based on Vision_files_preprocess.py).
    PR #1675.

  • Extra arguments to Vision_files_preprocess.py
    PR #1682.

  • Extra Python example coordinates_vs_bins.py.
    PR #1712.

  • Extra Python example in NeuroLF_reconstruction_example/ showing complete reconstruction chain for NeuroLF data, and some interactive plots using matplotlib.widgets.
    PR #1711.

Utilities

  • Add --disable-geometric-model option to find_ML_normfactors3D.

Changed functionality

  • When using a (ray tracing) matrix as projector, previously the matrix stored elements for the whole LOR, while many elements would be zero. We now only store the non-zero ones, resulting in a speed-up for the Siemens Vision Quadra of about a factor 1.7. Memory usage is also reduced.
    # 1674.
  • OpenMP parallelisation was added to the function to create a 2d histogram of hits per crystal from a proj data object,
    make_fan_sum_data.
    PR #1667.
  • Several optimisations were contributed as part of the SyneRBI AI-RBI hackathon:
    • Compatibility with libparallelproj 2.0 and usage of CUDA managed pointers via CuVec for internal variables in our parallelproj interface and CudaGibbsPenalty. This results in a ~20% speed-up, but also code simplification.
      PR #1689.
    • Extra constructors for array, image and projdata classes that allow std::move for input arrays.
      PR #1693 and PR #1694.

Changes to documentation

  • more info on the coordinate conventions in the STIR-developers-overview.
  • Brief section on Python in the STIR-UsersGuide.

Build system

  • Several libraries were merged into one library (called stir_buildblock, but this might change in the future). This avoids
    circular dependencies between libraries, and should therefore avoid linking problems in external projects. It could also make it possible
    to enable shared libraries (not recommended yet).
    This change should be transparent to the developer of external projects, as long as the ${STIR_LIBRARIES} CMake variable is used,
    as previously already recommended (see the STIR-UsersGuide). However, developers that extend STIR via the STIR_LOCAL mechanism might have to change their STIR library dependencies (see the PR for details).
    PR #1658
  • Use the CMake HDF5::HDF5 target to specify dependencies on, as opposed to HDF5_CXX_LIBRARIES etc. This should be more future proof and avoids problems with the STIR conda-forge build. (This can be switched of with the CMake option USE_HDF5_TARGET=OFF.)
    PR #1665
  • For builds with CERN ROOT, the minimum C++ standard is now automatically set to the one used to build ROOT. Starting from ROOT
    v6.32, the CMake variable ROOT_CXX_STANDARD specifies the C++ standard used to build ROOT, so STIR now uses this as (minimum) C++ version. (From ROOT 6.34, CMake will automatically ensure that ROOT dependencies (such as STIR) use the same C++ standard).
    Note that for ROOT versions below v6.32, the C++ standard is not exposed. In this case, STIR's FindROOT.cmake sets
    ROOT_CXX_STANDARD = 17, matching pre-built releases and conda packages. For custom builds of ROOT below v6.32 that use a more recent C++ standard, the STIR user must specify the appropriate C++ standard manually during configuration by specifying CMAKE_CXX_STANDARD.
    PR #1700

Known problems

See our issue tracker.

What is new for developers (aside from what should be obvious from the above):

New functionality

  • Added a Python script to convert e7tools generated Siemens Biograph Vision 600 sinograms to STIR compatible format. PR
    #1675

Changed functionality

  • Simplified the ProjDataInfoGenericNoArcCorr class hierarchy by merging `ProjDataInfoGeneric into it and deriving it from
    ProjDataInfoCylindricalNoArcCorr. See Issue #1307 for rationale.
    WARNING: this change might have unexpected consequences for developers: when checking for the type of ProjDataInfo with
    dynamic_cast with a sequence of if statements (or equivalent), make sure you test for
    ProjDataInfoGeneric before testing for ProjDataInfoCylindricalNoArcCorr.(or even ProjDataInfoCylindrical). It is therefore strongly recommended to test via
    proj_data.get_proj_data_info_sptr()->get_scanner_ptr()->get_scanner_geometry() == "Cylindrical")
    etc
    PR #1696
  • ProjDataInfo::clone() now uses covariant return types, avoiding need for explicit downcasting. Also added the DataWithProjDataInfo class, reducing duplicate C++ code.
    PR #1712.

New Deprecations and renames

  • ProjDataInfoGeneric is now identical to ProjDataInfoGenericNoArcCorr.
  • ProjDataInfoBlocksOnCylindricalNoArcCorr will be removed in v7.0 as it is almost identical to ProjDataInfoGenericNoArcCorr.

Code improvements

  • Minor fix to replace a deprecated std::sprintf() with std::snprintf(), see
    #1586.
    PR #1697
  • Minor fix to replace a deprecated std::istrstream() with std::istringstream(), see #1637.
    PR #1698
  • Fix to adjust buffer size in `manip_projdata.cxx` to account for appended extensions for file names.
    PR #1699

Test changes

All new features and most code changes were accompanied by new tests.

List of pull requests

Full Changelog: rel_6.3.1...rel_6.4.0