Recent Releases of sirf
sirf - SIRF Release 3.8.0
What's Changed
SIRF/STIR (PET and SPECT)
- use direct STIR operations for arrays, potentially resulting in speed-up when using STIR 6.2 or later
- fixed STIR linking problems by adding STIR_REGISTRIES to Reg executables
- added
compute_attenuation_factorsmethod to AcquisitionSensitivityModel - added means for setting maximal and minimal value for scale factor in stir::ScatterEstimation
- added support for the STIR 6.2 (somewhat experimental) Cuda Relative Difference Prior
MR
- fixed density_weight shape issue caused by upgrading numpy to version 2.0
CMake/building:
- set CMP0074 policy to NEW, i.e. honour
_ROOT env variables
- set CMP0074 policy to NEW, i.e. honour
- C++
Published by evgueni-ovtchinnikov almost 2 years ago
sirf - SIRF Release 3.7.0
What's Changed
- CMake improvements when coping with old Gadgetron by @KrisThielemans in https://github.com/SyneRBI/SIRF/pull/1236
- Enabling PET reconstruction from list mode data by @evgueni-ovtchinnikov in https://github.com/SyneRBI/SIRF/pull/1103
- Added optional argument out in all gradient-computing methods by @evgueni-ovtchinnikov in https://github.com/SyneRBI/SIRF/pull/1246
- sapyb to return even if out is not None by @paskino in https://github.com/SyneRBI/SIRF/pull/1254
- Computing Hessian products with image data objects and related stuff by @evgueni-ovtchinnikov in https://github.com/SyneRBI/SIRF/pull/1253
- Updated data submodule by @evgueni-ovtchinnikov in https://github.com/SyneRBI/SIRF/pull/1256
- V3.7.0 prep by @KrisThielemans in https://github.com/SyneRBI/SIRF/pull/1258
Full Changelog: https://github.com/SyneRBI/SIRF/compare/v3.6.0...v3.7.0
- C++
Published by evgueni-ovtchinnikov about 2 years ago
sirf - v3.6.0
PET:
- added extra members to ScatterEstimation to set behaviour of OSEM used during scatter estimation
- added test for scatter simulation and estimation
- added missing
set/getmethods for OSSPSrelaxation_parameter,relaxation_gammaandupper_bound - fixed estimate_randoms
- ensured compatibility with STIR 6.0
CMake/building:
- default
DISABLE_MATLABtoONas our Matlab support is out-of-date and could generate conflicts with Python shared libraries.
- default
Demo scripts:
- replaced importing reconstruction engines by
exec('from sirf.' + args['--engine'] + ' import *')with importing viaimportlib.import_modulethus getting rid of Codacy complaints about undefined modules.
- replaced importing reconstruction engines by
Python interfaces for the reconstruction engines:
- Several allocate methods in STIR.py, Gadgetron.py and Reg.py are replaced with just one allocate in DataContainer class that does not copy data between Python and C++.
return Nonein the methodDatacontainer.shape()replaced with more Pythonesquereturn (0,).
MR
- Improved handling of "irregular" ISMRMRD acquisitions by providing IgnoreMask object that allows the user to specify which kind of acquisitions is to be ignored. By default, no acquisition is ignored when reading from file.
Registration
- fixed handling of complex images in NiftiImageData.cpp.
- C++
Published by evgueni-ovtchinnikov over 2 years ago
sirf - v3.5.0
SIRF/common:
- Replaced Python implementation of
DataContainermethods with simple Python wraps of their C++ implementation. - Provided C++ tools for accessing the examples data (
examples_data_pathand utility functions such asappend_pathincommon/utilities.h).
- Replaced Python implementation of
MR
- Re-designed handling of "irregular" ISMRMRD acquisitions, making it user-controlled and more flexible. See https://github.com/SyneRBI/SIRF/pull/1174 for more information.
- Allow user to set radial, goldenangle, spiral and rpe trajectories.
- Added setter for acquisition header information and encoding limits. This allows the user to modify the reconstructed k-space dimensions and enables e.g. retrospective motion resolved or time-resolved reconstructions, or combinations of such dimensions. The acquisition model picks up these changes automatically if the encoding limits are set correctly.
- Added Gadgetron gadgets that allow for k-space filtering, coil compression and partial fourier reconstruction.
PET/SPECT
- Added SIRF interfaces to STIR functions to know where its files are:
get_STIR_doc_dir()andget_STIR_examples_dir(). - Added SIRF interfaces to STIR functions for
LogcoshPriorandRelativeDifferencePrior. - Added SIRF interfaces to STIR functions for
kappa(spatially variant penalty strengths) for QP, Log-cosh, and RDP. - Fixed
IterativeReconstructor.get_objective_function().
- Added SIRF interfaces to STIR functions to know where its files are:
- C++
Published by evgueni-ovtchinnikov almost 3 years ago
sirf - v3.4.0
MR:
- Added support for spiral trajectories that are pre-computed by the user (by exposing a trajectory setter).
- Writing images to
.dcmfiles fixed. - Running image processing chains after reconstruction fixed.
- Use C++ 17 if Gadgetron-support is enabled.
- Support Gadgetron
masterof end November 2022- using
find_package(gadgetron)in CMake, but still support old version by looking for toolboxes.
- using
PET/SPECT
- Require STIR 5.0 and support 5.1.
- If SIRF is compiled with STIR 5.1, we now support Pinhole SPECT via the
PinholeSPECTUBMatrixacquisition model. Examples are provided (but the code is not yet tested). sirf.STIR.AcquisitionDataconstructor taking a scanner now has an extra optional argument tofmashfactor (defaulting to 1). This is only functional if a STIR version supporting TOF is used.- C++: Renamed PETAcquisitionData and derived classes to STIRAcquisitionData* as STIR now supports SPECT in addition to PET modality. Backward compatibility ensured by defining old nomenclature via typedefs until the release of SIRF 4.
Documentation
- revision of READMEs for the examples.
Changed Python test framework to pytest.
Added support for the extraction of subsets of STIR and Gadgetron acquisition data.
- C++
Published by evgueni-ovtchinnikov over 3 years ago
sirf - v3.3.0
Added a new acquisition model
SPECTUBMatrixfor (simple) usage in SPECT.sirf.STIR.ImageDatahas now a way to set/get the modality.interactive Python demos superseded by SIRF-Exercises notebooks removed.
arguments setting number of CG iterations and verbosity of output of acquisition models method
norm()added.path for ISMRMRD shared library when generating MR data fixed.
extension processing in
ISMRMRDImageData::writefixed.Python int array check/conversion ensuring C++ compatibility added.
C/Python interfaces for computing prior value added.
added
CITATION.cfffile (replacing .zenodo.json`)
- C++
Published by KrisThielemans almost 4 years ago
sirf - v3.2.0
To avoid appending to an existing
.h5file, writing methods now first check whether the file to which data is to be written already exists, and if so, delete it before writing.A version.h is created by CMake and installed to access version minor and major from C++.
MR
- added acquisition models for 2D non-cartesian encoding.
- The 2D radial, golden-angle increment radial and stack-of-stars trajectory are supported.
MR Geometry
- fixed GadgetronImagesVector::reorient() to only consider slice index and ignore dimensions such as contrast, repetition etc.
PET/STIR
- (C++) Replaced where possible returning
stir::Succeeded::nowith throwing exception. - (C++) Fixed a bug in
PETAcquisitionDataInMemory::norm. - (C++) Expose advanced parameters from STIR to sirf.STIR.RayTracingMatrix
- (Python) Expose advanced parameters from STIR to sirf.STIR.RayTracingMatrix and add get_info()
- (C++) Replaced where possible returning
SIRF Python interface
- Removed
__div__,__idiv__operators forDataContainersrequired for Python2. - Added
__truediv__and__itruediv__Python3 operators to DataContainer algebra.
- Removed
Build system
- export a CMake config file such that external C++ projects can use SIRF via CMake,
see the
examples/C++directory for basic usage. - during the build step the executable ismrmrdgeneratecartesianshepplogan is called to generate simulated data to be used in tests such that the test data are compatible with the installed ISMRMRD version.
- we now require ISMRMRD v1.4.2.1 to allow for the -w flag for the creation of Shepp Logan test data during build.
- export a CMake config file such that external C++ projects can use SIRF via CMake,
see the
Other changes
- added conjugation methods to DataContainer
- C++
Published by evgueni-ovtchinnikov over 4 years ago
sirf - v3.1.0
v3.1.0
MR/Gadgetron
- Golden-angle radial phase encoding (RPE) trajectory is supported if
Gadgetrontoolboxes were found during building
WARNING if Gadgetron was compiled with CUDA support, you need to build SIRF with theGadgetron_USE_CUDACMake variable set toON. - Automatic calling of
sort_by_time()in most places. This ensures that only consistent images are reconstructed. - Encoding classes perform the Fourier transformations instead of the
MRAcquisitionModel CoilSensitivitiesVectorclass now has forward and backward method using the encoding classes getting rid of the duplicate FFT code used to computecoil sensitivitiesfromMRAcquisitionData.- Added constructor for
GadgetronImagesVectorfromMRAcquisitionData. This allows setting up an MR acquisition model without having to perform a reconstruction first.
- Golden-angle radial phase encoding (RPE) trajectory is supported if
PET/STIR
- iterative reconstructors
set_current_estimateandget_current_estimatenow create a clone to avoid surprising modifications of arguments. The old behaviour ofset_current_estimatecan still be achieved byset_estimate.
Warning This is backwards incompatible, but arguably a bug fix.
- iterative reconstructors
SIRF Python interface
range_geometryanddomain_geometrymethods ofAcquisitionModelclasses, required by CIL algorithms, now obtain data via respective C++AcquisitionModelclasses accessors, in line with our strategy of keeping interface code minimalsirf.Gadgetron.AcquisitionData.get_infowas renamed toget_ISMRMRD_infoto avoid confusion with the otherget_info()methods that return a string. (get_infostill works but issues a deprecation warning).
Build system
- fix bug with older CMake (pre-3.12?) that the Python interface was not built #939.
- C++
Published by KrisThielemans almost 5 years ago
sirf - SIRF v3.0.0
New features
- PET
- Addition of
sirf.STIR.ScatterEstimationandScatterSimulationto allow (non-TOF) scatter estimation in PET - GE Signa PET/MR reading of listmode data, sinograms, normalisation and randoms support added.
- If STIR is at least version 5 or built from the master branch, Georg Schramm's parallel (computing) projector is now made available from SIRF (use
AcquisitionModelUsingParallelproj). This uses Joseph interpolation, but importantly can use your GPU (if CUDA was found during building). - Implemented extraction of the operator representing the linear part of PET acquisition model and computation of its norm.
- When adding a shape to a
sirf.STIR.ImageData, optionally give the number of times to sample a voxel. This is useful when the shape partially - but not completely - fills a voxel. - If
storage_schemeis set tomemory,PETAcquisitionDataallows direct modification, whereas before a copy would need to be created first. (Internally, it uses STIRProjDataInMemory, instead ofProjDataFromStream).
- Addition of
- Registration
- Registration of 2d images is now supported with aladin and f3d.
- examples data:
- Installs
examples,dataanddocto the install directory, i.e.${CMAKE_INSTALL_PREFIX}/share/SIRF-<version_major>.<version_minor>directory. - If the
SIRF_DATA_PATHenvironment variable is set,examples_data_pathwill search for the examples data there, or inSIRF_INSTALL_PATH/share/SIRF-<version_major>.<version_minor>/datadirectory. In MATLAB, theexample_data_pathfunction has the version set by CMake at install time.
- Installs
- Other Python features:
- Define
__version__insirfpython package. - Added implementation of division and multiplication for
NiftiImageData. - Data validity checks return
NotImplementedinstead of throwing error, opening the door for future implementations of operations on data.
- Define
Backwards incompatible changes
- STIR version 4.1.0 is now required.
- Python 2 is no longer supported. Most code might still work, but we do not check. A warning is written when the Python version found is 2. This will be changed to
FATAL_ERRORat a later stage. - Handling of coil images and sensitivities in C++ code simplified by inheriting CoilImagesVector from GadgetronImagesVector and replacing CoilSensitivitiesAsImages with CoilSensitivitiesVector, also inheriting from GadgetronImagesVector. All methods of CoilImagesVector and CoilSensitivitiesVector other than those inherited from GadgetronImagesVector are no longer supported except methods named compute(), which are renamed to calculate().
Deprecations (will be errors in SIRF 4.0)
Registration: renamedResampletoResamplerandNiftyResampletoNiftyResampler. Old names are now deprecated but should still work.- STIR
AcquisitionModelforward,direct,backwardandadjointsignatures have changed in Python. Subset information should now be set vianum_subsetsandsubset_nummembers.Theforwardandbackwardmembers can still be called with the previous syntax but this will be removed in a later version. Note that default values ofnumsubsetsandsubsetnum` are 0 and 1 respectively, such that default behaviour is default behaviour (i.e. process all data) is unchanged. - MR acquisition data storage scheme restricted to memory only (a message will be printed but no error thrown)
- Use CMake variable names from
find_package(Python)which are available with CMake 3.12+. SIRF CMake files will accept bothPython_EXECUTABLEorPYTHON_EXECUTABLE, for the latter it will send a deprecation warning.
Other changes
- When registering, internally the forward displacement is no longer stored, replaced by the forward deformation. The inverse is no longer stored, and is calculated as needed.
PETAcquisitionData.axpbynow uses STIR'saxpbyand is therefore faster.- Speed-up in
stir::AcquisitionDataInMemoryofas_array,fill,dot,norm, etc. (by using STIR iterators). - Added common Python
DataContaineralgebra unit tests for allDataContainerinherited classes. - Continuous Integration now uses Github Actions. Travis-CI has been dropped.
- New
CMakeoptionBUILD_DOCUMENTATIONto use doxygen to build C++ documentation. It will be installed in theshare/SIRF-version/doc/doxygen.
Bug fixes
- Python
fillmethod in MRDataContaineracceptsnumpyarray, number orDataContainer. get_index_to_physical_point_matrix()returned a wrong matrix in MATLAB and Python.- path manipulation of
examples_data_pathnow should work for any platform, not just linux.
- C++
Published by evgueni-ovtchinnikov about 5 years ago
sirf - SIRF v2.2.0
PET/STIR
- updates to steepest ascent demo
- STIR.AcquisitionData.get_info() returns a string that describes the scanner etc
- NiftyPET projector wrapped (if STIR is built with NiftyPET)
- Added
set_image_data_processortoPETAcquisitionModel. This allows for instance image-based PSF modelling. - Ability to set and get STIR verbosity from python.
- Save STIR images using a parameter file (e.g., for saving as
.nii) - A passthrough for both the maximum and minimum relative change during OSMAPOSL reconstruction has been added.
MR/Gadgetron
- We have now corrected the geometrical information of
.h5images (coming from ISMRMRD and Gadgetron). This means we can now convert them to other SIRF image types (e.g.,NiftiImageDataandSTIRImageData). This is necessary for any kind of synergistic reconstruction. Further, to the best of our knowledge, this is the first ISMRMRD to NIfTI converter out there!
- We have now corrected the geometrical information of
Registration
- Default F3d to using non-symmetric version (previously, symmetric was used). Option to use the symmetric in C++, but currently exposed to python and matlab as we suspect there is an upstream bug there.
- The adjoint transformation has now been implemented for
NiftyResamplethrough the wrapping of NiftyMoMo. - The following methods have been added to C++, python and matlab NiftyResample:
out = forward(in)forward(out, in)out = adjoint(in)adjoint(out, in)
- Inverse deformation images. Inverse displacements are also possible by converting to and from deformations.
- Resampling of complex images.
- SPM registration wrapping (only SPM12 tested). If
MatlabandSPMare present, the SPM wrapper is available fromC++,MatlabandPython. - Support for registering multiple floating images has been added. This is only available for certain algorithms (currently only
SPM). There are therefore new methodsadd_floating_imageandclear_floating_imageson top of the originalset_floating_image. Methods extracting the results of registrations can now be called with an index (get_output(idx = 0),get_transformation_matrix_forward(idx = 0), etc.). This index defaults to the first to maintain backwards compatibility. - Ability to pad
NiftiImageData, e.g.,a.pad([10,10,0],[10,10,0])to add 10 voxels to the minimum and maximum of the x- and y-directions.
Other
- Changed CCP PETMR to SyneRBI
- documentation fixes/additions
- C++
Published by KrisThielemans about 6 years ago
sirf - SyneRBI SIRF v2.2.0 Release Candidate 1
- A passthrough for both the maximum and minimum relative change during OSMAPOSL reconstruction has been added.
- We have now corrected the geometrical information of
.h5images (coming from ISMRMRD and Gadgetron). This means we can now convert them to other SIRF image types (e.g.,NiftiImageDataandSTIRImageData). This is necessary for any kind of synergistic reconstruction. Further, to the best of our knowledge, this is the first ISMRMRD to NIfTI converter out there! - The adjoint transformation has now been implemented for
NiftyResamplethrough the wrapping of NiftyMoMo. Resample::process()has been marked as deprecated. Instead, the following methods have been added to C++, python and matlab NiftyResample:out = forward(in)forward(out, in)out = adjoint(in)adjoint(out, in)out = backward(in)<- alias for adjointbackward(out, in)<- alias for adjoint
- Inverse deformation images. Inverse displacements are also possible by converting to and from deformations.
- NiftyPET projector wrapped (if STIR is built with NiftyPET)
- Added
set_image_data_processortoPETAcquisitionModel. This allows for instance image-based PSF modelling. - Resampling of complex images.
- SPM registration wrapping (only SPM12 tested). If
MatlabandSPMare present, the SPM wrapper is available fromC++,MatlabandPython. - Support for registering multiple floating images has been added. This is only available for certain algorithms (currently only
SPM). There are therefore new methodsadd_floating_imageandclear_floating_imageson top of the originalset_floating_image. Methods extracting the results of registrations can now be called with an index (get_output(idx = 0),get_transformation_matrix_forward(idx = 0), etc.). This index defaults to the first to maintain backwards compatibility. - Ability to pad
NiftiImageData, e.g.,a.pad([10,10,0],[10,10,0])to add 10 voxels to the minimum and maximum of the x- and y-directions. - Ability to set and get STIR verbosity from python.
- Save STIR images using a parameter file (e.g., for saving as
.nii) - Default F3d to using non-symmetric version (previously, symmetric was used). Option to use the symmetric in C++, but currently exposed to python and matlab as we suspect there is an upstream bug there.
- C++
Published by evgueni-ovtchinnikov about 6 years ago
sirf - CCPPETMR SIRF v2.1.0
- PET/STIR
- Interfaced HKEM into SIRF
- Interfaced SeparableGaussianImageFilter into SIRF
- MR/Gadgetron
- Added DICOM-writing gadgets for MR images output
- Added few Gadgetron GPU gadgets to SIRF gadget library
- Enabled handling of 3D slices of MR images by switching to 3D FFT
- Python
- Switched to new class style
- Introduced contiguity checks of filled data
- CIL/SIRF Compatibility
- added methods to AcquisitionData, ImageData and AcquisitionModel to be compatible with CCPi's Core Imaging Library (CIL)
- C++
Published by evgueni-ovtchinnikov over 6 years ago
sirf - CCPPETMR SIRF v2.0.0
- Set CMake policy CMP0079.
- Use
swig_add_libraryinstead ofswig_add_module. - Averaging of rigid transformation matrices via quaternions (and therefore a quaternion class).
- Arrays of SIRF objects can be passed from the Python and Matlab interfaces to the C++ level (e.g., averaging a large number of matrices) via the DataHandleVector class. This is an internal class that should not be used. Simply pass a native array of objects and SIRF will convert to the DataHandleVector class if necessary.
- Image data role checks in MRAcquisitionModel introduced.
- Corrected ISMRMRD acquisition sorting.
- Added PhysioInterpolationGadget and FatWaterGadget to SIRF gadgets library.
- Wrapping of NiftyReg to allow registration/resampling in SIRF.
- Implemented new
ImageDatahierarchy common to PET and MR.ImageDatacontain geometrical info. - MR/Gadgetron
- Added default constructor and set_up to MRAcquisitionModel
- Implemented sorting of MR images
- Implemented reading of MR acquisition data from ISMRMRD file
- PET/STIR
- projectors can now handle subsets (although with a somewhat ugly work-around)
- added FBP2D, SSRB and the Parallel Level Sets prior
- added TOF bins dimension to
PETAcquisitionData(still fixed to have size 1)
- C++ changes
- Removed
usingstatements from the C++ header files - Created namespace
sirf - include files are now moved to subdirectories (such as
include/sirf/common). - Modified ObjectHandle type so that it can handle both
std::shared_ptrandboost::shared_ptr.
- Removed
- Python/MATLAB:
petmr_data_pathis now obsolete. Useexamples_data_pathinstead.
- Python:
- everything is now in a
sirfmodule. Use for instanceimport sirf.Gadgetron
- everything is now in a
- Matlab:
- in keeping with changes to c++ and python, classes are now called with e.g.,
sirf.STIR.objinstead ofmSTIR.obj. Aliases can be used to shorten this (e.g.,PET=set_up_PET()and thenPET.obj).
- in keeping with changes to c++ and python, classes are now called with e.g.,
- CMake:
- Updated minimum required version of CMake to 3.9.0.
- C++
Published by evgueni-ovtchinnikov about 7 years ago
sirf - CCPPETMR SIRF v1.1.0
- Various bug fixes and corrections
BUILD_STIR_WITH_OPENMPis nowONby default- Gadgetron data processors check for Gadgetron server crash
- More data files in
SIRF/data/examples/MR - Grayscale plotting enabled
- Created a python
sirfpackage (recommended way of importing)- aliased
p(Gadgetron|STIR|Utilities) -> sirf.(Gadgetron|STIR|Utilities) - added
setup.py - exposed cmake variable
PYTHON_STRATEGY. Options:PYTHONPATH: prefix$PYTHONPATH(default)SETUP_PY: execute${PYTHON_EXECUTABLE} setup.py installCONDA: do nothing
- aliased
- Added
PYTHON_DEST_DIRvariable, which allows the user to select the install destination of the SIRF python modules.PYTHON_DEST_DIRis a cached variable which can be updated on the GUI. IfPYTHON_DEST_DIRis not set, we will install in${CMAKE_INSTALL_PREFIX}/python. Likewise forMATLAB_DEST_DIR. - Some improvements to the demos. Note that PET reconstruction demos have somewhat different parameters.
- Implemented PLS Prior
- Implemented 2D Filtered Back Projection
- C++
Published by casperdcl about 7 years ago
sirf - CCPPETMR SIRF v1.0.0
- Access to all MR images and acquisition parameters
- All 8 file IO available (PET: Interfile, MR: HDF5)
- PET
- PETAcquisitionData object creation from scanner name and parameters
- ListmodeToSinograms converter class, also estimating randoms (from delayed coincidences)
- Normalization from ECAT8 (Siemens mMR) and attenuation image
- Build with OpenMP delivers stable and substantially accelerated performance
- More documentation
- Developer's Guide
- Doxygen inline documentation (available on CCP PETMR website)
- More tests (now run via CTest), for Python, Matlab and C++.
- Coverage reporting for Python tests done by ctest
- C++
Published by casperdcl about 7 years ago