FSL 6.0.7.18, 22nd May 2025
- file-tree-fsl 0.2.2 -> 0.2.3
- fsleyes 1.13.0 -> 1.14.2
- fslpy 3.21.1 -> 3.22.0
- fsl-armawrap 0.6.0 -> 0.7.0
- fsl-base 2502.1 -> 2504.3
- fsl-basisfield 2203.1 -> 2203.4
- fsl-eddy_qc v1.2.3 -> v1.3.0
- fsl-fdt 2202.10 -> 2202.11
- fsl-first_lib 2111.0 -> 2111.1
- fsl-flameo 2111.1 -> 2111.2
- fsl-flirt 2111.2 -> 2111.4
- fsl-fnirt 2203.1 -> 2203.2
- fsl-installer 3.16.5 -> 3.16.8
- fsl-libvis 2111.0 -> 2111.2
- fsl-miscmaths 2203.2 -> 2412.4
- fsl_mrs 2.4.0 -> 2.4.3
- fsl-newimage 2203.12 -> 2501.4
- fsl-newmesh 2111.0 -> 2111.2
- fsl-pipe 1.2.2 -> 1.3.0
- fsl-possum 2111.2 -> 2111.3
- fsl-pyfeeds 0.13.1 -> 0.15.0
- fsl-shapemodel 2111.0 -> 2111.1
- fsl-sub-plugin-slurm 1.6.5 -> 1.6.7
- fsl-tirl 3.6.2 -> v3.6.3
- fsl-utils 2203.5 -> 2412.1
- fsl-warpfns 2203.0 -> 2501.0
- fsl-xtract 2.0.6 -> 2.0.7
- fsl-cudabasisfield 1.1.1 -> 1.1.2
- fsl-mmorf v0.3.3 -> v0.4.2
file-tree-fsl 0.2.2 -> 0.2.3
Detailed history
python 3.6 and 3.7 are no longer supported by file-tree
Replace pkg_resources with importlib_resources
Bump to v0.2.3
fsleyes 1.13.0 -> 1.14.2
- ENH: Apply alpha-modulation to MELODIC images when using
--autoDisplay
- BF: Fix bug in
DisplayContext.overlayOrder
management Unintentionally introduced in refactors related to preserving the selected overlay.
This MR also contains some changes which should suppress some harmless errors originating from toolbar/dialog widgets that could occur when removing overlays.
- ENH: Tractogram Slice width option
New Slice width option (--sliceWidth
/ -sw
on the CLI), allowing the width of 2D tractogram slices to be adjusted.
A couple of other unrelated changes:
- Plot panels will now use a solid line by default for all overlays, instead of cycling through all possible line styles.
- cluster_mask_*
images from FEAT analyses will now be shown as mask outlines when FSLeyes is started with --autoDisplay
.
Detailed history
RF: Add cluster mask as mask rather than label image
RF: Apply alpha modulation for melodic images with autoDisplay
DOC: Icon image for changelog in API docs
BF: copy-paste bug, oldOrder used in multiple branches
BF: Prevent (harmless) errors in widgets when overlays are removed
TEST: Unit test for syncing of DC.overlayOrder
RF: Show cluster masks as outlines. Clean up FEAT image autodisplay a bit - separate functions for each image type
RF: Use filled line by default for all images in plot panels - other line styles are often undesirable. Drop grey from pt lookup table, but double the number of colours used by creating darker equivalents
ENH: New TractogramOpts.sliceWidth property, for controlling width of 2D slices, as a percentage of Z axis bounds
RF: Restore behaviour of clipping in terms of ref image voxels when a ref is set
TEST: Test new TractogramOpts.sliceWidth option
fslpy 3.21.1 -> 3.22.0
- ENH: Add support for
scaled
coordinate system toImage.getAffine
Add a new supported coordinate system to theImage.getAffine
method, which is equivalent to thefsl
coordinate system, but without the L/R flip. This coordinate system is used by FSLeyes, and I'm not sure why I didn't add it in the first place.
The existing Image.voxToScaledVoxMat
and Image.scaledVoxToVoxMat
properties have been deprecated - the getAffine
method is a nicer interface, and these properties are confusingly named, as they refer to the fsl
coordinate system.
Detailed history
ENH: Add support for "scaled" coordinate system to getAffine - scaled voxels without L/R flip.
MNT,CI: Test py313, drop py39
BF: Mixed up affines
TEST: Add basic test cover for scaled coord system
MNT: Deprecate unfortunately named voxToScaledVoxMat and scaledVoxToVoxMat methods
TEST: Replace voxToScaledVox with getAffine
MNT: Pre-release version bump [skip-ci]
RF: No need for import inside function as numpy is already being imported at the top-level
TEST: Adjust identifyAffine test
DOC: Changelog [skip-ci]
fsl-armawrap 0.6.0 -> 0.7.0
Detailed history
TEST: Normalise signs of EigenValues/svd outputs. Default to c++17
MNT: Update armadillo to version 14.2.1
Fix CI rules path
CI job to rebuild docker image
fsl-base 2502.1 -> 2504.3
- BF: Fix bugs in CUDA build rules; improve
fslversion
Fix a couple of bugs in theMakefile
build rules for CUDA projects.
Adjust fslversion
to better support FSL installations where $FSLDIR
is a sym-link, and/or where the fsinstaller.py
script was passed a sym-linked destination.
- MNT: Minor updates to build system
- Add support for .c++
as a source-file suffix.
- Tweak to C/C++ dependency file generation - now if a dependency file has changed, the object file is not re-built. This is useful for CUDA projects where the same source file may be compiled more than once for CPU and GPU builds. In this case the dependency file will be re-generated, but we only want object files to be recompiled if the source file has changed, not the dependency file.
- TEST: Make sure command output is printed to standard output/error
- TEST: Make sure setuptools-scm
doesn't cause a crash
- RF: Improvements to update_fsl_package
The update_fsl_package
command can now be used to install/update third-party packages from conda-forge
.
- RF: Update update_fsl_package
to print the underlying conda
command
And also fix a bug in pyproject.toml
.
- MNT: Update update_fsl_package
to support both .conda
and .tar.bz2
packages
Detailed history
BF: Make sure that FSLDEVDIR takes precedence
BF: If BUILDDIR is set but CUDABUILDDIR isn't, default the latter to the former
RF: Adjust fslversion to try and support sym-linked installations
MNT: Add support for .c++ source file suffix
RF: Make dep files order-only dependencies, so make doesn't rebuild object files based on their timestamp. This is useful for CUDA projects where the same source file may be compiled more than once for different builds. In this case the dependency file is re-generated, but we only want object files to be recompiled if the source file has changed, not the dep file.
MNT: Use setuptools-scm to automatically set version when building python package
TEST: Make sure command is printed to stdout/err
TEST: Make sure setuptools-scm doesn't cause a crash
RF: Use --override-channels instead of trying to patch .condarc, which is insanity. Adjust update_fsl_package so it allows new packages to be installed, including third-party packages
MNT: update license def
MNT: Fix license identiifer
RF: Print underlying conda command
MNT: .conda packages are stored in a separate area of the repodata.json to .tar.bz2 files
fsl-basisfield 2203.1 -> 2203.4
- MNT: Need to link against
fsl-utils
on macOS TheUtilities::NoOfThreads
struct was previously specified entirely in theutils/threading.h
header, but is now compiled, so must be linked against (on macOS). - MNT: Need to link against fsl-utils in unit tests
- TEST: Rework unit tests All outputs generated from the MNI152 are identical across the three platform, so there is no need to store per-platform benchmark data. For the other tests, use the same RNG on all platforms to ensure that results are consistent, and evaluate results against equivalent operations in Python.
Detailed history
MNT: Need to link against fsl-utils on macOS
MNT: Need to link against fsl-utils in unit tests
TEST: Replace use of arma rng with cross-platform implementation
TEST: Rework unit tests. All outputs generated from the MNI152 are identical across the three platforms. Use a RNG for other tests to ensure results are the same across platforms.
fsl-eddy_qc v1.2.3 -> v1.3.0
- BF,MNT: Fix bugs in loading of eddy acquisition parameters and volume indices; update code to use
pypdf
ThePyPDF2
library has been sunsetted, and replaced withpypdf
; this requires a number of minor changes to theeddy_qc
code.
There also seem to be some issue in the way that eddy_qc
loads eddy
acquisition parameter and volume index files (typically called acqparams.txt
and index.txt
). It was incapable of handling datasets with entries in acqparams.txt
which were not referenced by index.txt
. The relevant code has been re-written. Results should be the same, although order in which PE directions are reported in the eddy_qc
output files may change.
The project has also been updated to use pyproject.toml
instead of setup.py
, which is necessary for modern Python build tooling.
Detailed history
MNT: Replace setup.py with pyproject.toml. Make eddy_quad/eddy_squad python modules. Replace pkg_resources with importlib
BF: Code seems to struggle when acqparams contains multiple entries, but provided data corresponds to fewer entries (e.g. acqparams describes both PA and AP, but data/index.txt only corresopnds to AP).
MNT: pypdf has renamed PdfFileReader to PdfReader
Bf: Re-write janky logic for standardising acqparams and volume indices
MNT: PyPDF2 ->pypdf and associated superfluous name changes
MNT: Clarification about acqparams/indexes standardisation
MNT: Bump version, update readme
DOC: Convert readme to markdown
MNT: Remove duplicate help text
MNT: Remove out-dated/incorrect instructions from README
fsl-fdt 2202.10 -> 2202.11
- RF: Fixes to
NEWIMAGE::volume
data access invecreg
Replaced calls toNEWIMAGE::volume[t] (x, y, z)
withNEWIMAGE::volume(x, y, z, t)
- the former pattern causes unnecessary copies of entire 3D volumes (specificallly spline coefficients) to be made. As this was happening for every voxel, this was having a substantial impact on performance.
Detailed history
MNT: Use vol(x,y,z,t) rather than vol[t] (x,y,z)
fsl-first_lib 2111.0 -> 2111.1
Detailed history
MNT: Need to link against fsl-utils on macOS
fsl-flameo 2111.1 -> 2111.2
- MNT: Cannot modify properties of
const volume
TheNEWIMAGE::volume
class no longer allows manipulation of state ofconst volume
instances, so this sort of ugliness needs to be handled by client code.
Detailed history
MNT: The newimage volume class no longer allows manipulation of state on const volumes, so this sort of ugliness needs to be handled by the client code
MNT: Change linking order (make sure utils comes after newimage/miscmaths)
fsl-flirt 2111.2 -> 2111.4
- MNT: Cannot modify properties of a
const NEWIMAGE::volume
In this instance there is no need for the volume to beconst
. - BF: Fix bug introduced in last change
Cannot pass a non-
const
rvalue (returned fromvolume.operator[]
) through tofinal_transform
. This is easily avoided by creating a localShadowVolume
instance, and passing that tofinal_transform
. - RF: Update method for changing interpolation/extrapolation settings on
NEWIMAGE::volume
instances This MR contains someShadowVolume
-related fixes toflirt
andapplyxfm4D
: - The code was calling
invol[t].setpadvalue(..);
. This is a throwback to an old version ofnewimage
where, for 4D images, thevolume
class would store astd::vector<volume>
containing a separate 3D volume for each timepoint. After the introduction of theShadowVolume
pattern, this code was having no effect, as theoperator[]
function would return a newShadowVolume
instance on each invocation. The logic inapplyxfm4D
has been changed so that the pad value is set via theNEWIMAGE::affine_transform
overload (innewimagefns.cc
) which accepts aset_backgnd
parameter. - With the introduction of the
ShadowVolume
cache in fsl/newimage!41, the calls toinvol[t]
described above resulted in the creation of aShadowVolume
for each time point, which meant that the subsequent call toinvol.setinterpolationmethod
(and similar) were not being applied to thoseShadowVolume
instances. This is being addressed in fsl/newimage!42, but the reworked code here avoids this issue.
Detailed history
MNT: Cannot modify properties of a const volume, In this instance there is no need for the volume to be marked as const
BF: Fix bug introduced in last change - cannot pass a non-const rvalue (from volume.operator[]) through to final_transform. Change code to create a local ShadowVolume, and pass that through.
MNT: Normalise indentation
RF: Change method of setting per-volume pad value - we can't set properties on a ShadowVolume instance, but can do it via the newimagefns.cc:affine_transform overload which accepts a set_backgnd parameter.
MNT: Avoid calling set* interp/extrap functions on ShadowVolume instances
fsl-fnirt 2203.1 -> 2203.2
- MNT: Do not modify any properties on a
const volume
instance. TheNEWIMAGE::volume
class is now more strict with respect to modifying properties onconst volume
instances. In this instance, taking a copy of thevolume
instance should not be overly expensive.
This MR also makes a small adjustment to the Makefile
so that config
files are installed at make install
rather than at make
.
Detailed history
MNT: Do not modify any properties on a const volume. Adjustment to make file so that config files are installed at "make install" rather than at "make"
fsl-installer 3.16.5 -> 3.16.8
- MNT: Use
--rc-file
argument to try and persuade conda to only use our configuration file - BF: Initial micromamba implementation wouldn't work when installing into a location requiring administrative privileges
- BF: Fixes to
createFSLWrapper
/removeFSLWrapper
when$FSLDIR
is a sym-linked location FSL wrapper scripts were not being created in$FSLDIR/share/fsl/bin/
when$FSLDIR
was set to a sym-linked location. This was because the$PREFIX
environment variable, set byconda
when callingpost-link.sh
scripts, seems to be set to the actual location, whereas$FSLDIR
was set to the sym-linked location.
Detailed history
MNT: Use --rc-file argument to try and persuade conda to only use our configuration file
BF: Initial micromamba implementation wouldn't work when installing into a location requiring administrative privileges
DOC: Readme
MNT: Use more standard tar incantation. Assume that tar will auto-detect compression format - works on ubuntu 22.04/macOS 11.7
BF: Wrapper scripts were potentially not being created when FSLDIR is set to a sym-linked location - it seems that $PREFIX gets set to the actual path
TEST: Unit test for create/removeFSLWrapper with sym-linked $FSLDIR
fsl-libvis 2111.0 -> 2111.2
- MNT: Need to use
${CFLAGS}
, not${CXXFLAGS}
, when compiling C code - BF: Fix terrible bug - pointer referencing destroyed object
Detailed history
MNT: Need to use CFLAGS, not CXXFLAGS, when compiling C code
BF: Fix terrible bug - pointer referencing destroyed object
fsl-miscmaths 2203.2 -> 2412.4
- ENH: Allow
Splinterpolator
instances to be created from an existing set of spline coefficients, and extend extrapolation options - The
Splinterpolator
class can now accept a pointer to an array of pre-calculated coefficients - in this case, a copy of the pointer is used (the data is not copied), and pre-filtering (coefficient calculation) is skipped - New
SoftZeros
extrapolation method - out of bounds coefficients will be set to zero, but out-of-bounds coordinates will still be constructed via interpolation. This differs from the existingZeros
extrapolation method, where out-of-bounds coordinates are forced to zero. - Adjustment to the coefficient initialisation method used when
Constant
extrapolation is requested; previously, a mirroring boundary condition was used. - New
Splinterpolator::Copy
function, which allows the spline coefficients to be copied/extracted. - BF: Fix bug in code controlling which adjacent spline coefficients to use when interpolating
This MR fixes a very subtle bug in the
Splinterpolator
class which was causing artifacts when extrapolating into negative coordinate space.
When using third-order cubic b-spline interpolation to interpolate a value at a particular location, the four nearest spline coefficients are combined to generate the interpolated value. For example, if interpolating a value at location -0.25
, the spline coefficients at locations [-2, -1, 0, 1]
would be used.
If interpolating at an integer location, e.g. 2
, the choice of whether to use coefficients at [0, 1, 2, 3]
, or [1, 2, 3, 4]
is arbitrary, but the convention in the Splinterpolator
class is to use the former.
The logic which controls which spline coefficients are used is in the get_start_indicies
function. While this function produces sensible values for positive coordinates, it was mis-behaving for negative coordinates.
- For coordinates with a fractional component greater than 0.5
, such as -3.75
, the code was correctly selecting coefficients [-5, -4, -3, -2]
. However, for coordinates with a fractional component smaller than 0.5
, such as -3.25
, the code was incorrectly selecting coefficients [-4, -3, -2, -1]
.
- For a negative integer coordinate such as -4
, the code was selecting coefficients [-5, -4, -3, -2]
, which would produce the correct result, but which was not following the same convention as for positive coordinates (i.e. it should be [-6, -5, -4, -3]
).
- MNT: Move constructor/assignment operator for Splinterpolator
, which inherits ownership of data pointer
- MNT: Revert spline coefficient initialisation boundary condition
This MR reverts the spline coefficient initialisation boundary condition for constant
/zeros
extrapolation to preserve the existing/established behaviour. The old behaviour for constant
/zeros
extrapolation was to use an initialisation method suitable for mirror
extrapolation.
This is not strictly the best approach, which is why I changed it in !17. However, the old logic has been in place for at least 16 years, and so arguably the better option is to preserve the existing behaviour. We can revisit this in the future if needed. - TEST: Re-generate splinterpolator benchmark data - TEST: Tweak test tolerance
Detailed history
BF: Fix start index selection for even order interpolation
MNT: Normalise indentation
MNT: remove obsolete debugging macros and statements
ENH: Scaffolding for ability to create a Splinterpolator instance from an existing set of spline coefficients
ENH: Adjust logic so that Splinterpolator can be created with pre-calculated coefficeints
ENH: New function to copy spline coefficients
MNT: Safeguard against being passed a bad value for nthr
ENH,RF: Implement clamped extrapolation boundary condition for coefficient initialisation
ENH: NEW "SoftZeros" extrapolation method, which sets out-of-bounds locations to zero, but still interpolates out-of-bounds, to allow a smooth transition from in-to-out of bounds
TEST: Unit tests for splinterpolator
BF: Fix extrapolation indexing bug in Splinterpolator::coef(). I think this code was added in an early commit, but was then replaced with indx2indx, and never updated / used.
TEST: Expand splinterpolator tests to cover all extrapolation methods, and order=2 interpolation
TEST: link fsl-utils
MNT: Don't pass a value to NoOfThreads, so that it will use a default value
MNT: Move constructor/assignment operator for Splinterpolator, which inherits ownership of data pointer
MNT: Const version of kernel::kernelvals function
MNT: Revert spline coefficient initialisation boundary condition for constant/zeros to previous incorrect method, to preserve existing behaviour
MNT: Comment
TEST: Re-generate splinterpolator benchmark data
TEST: Tweak test tolerance
fsl_mrs 2.4.0 -> 2.4.3
- Add negative voigt model Adds model which allows voigt peaks to be inverted.
- BF: minor bugs Dealing with accumulated small bugs.
- Handle single coil data in coil combine function
- Allow phased peaks to be added to basis set.
- Removed use of depreciated matplotlib function
tostring_rgb
.
Also added the negativevoigt
model, which allows inverted peaks.
- ENH: P spline baseline in dynamic fitting
- P-spline baseline added as an option to dynamic fitting.
- Dynamic fitting default solver changed to L-BFGS (method='quasi-newton'
)
- Citation information added for p-spline fitting (https://doi.org/10.1002/mrm.28385).
- ENH: freeshift with lorentzian
- Added a freeshift_lorentzian
model with inter-metabolite shifts (freeshift) and lorentzian lineshape.
- Added freeshift
option to dynamic fitting script and MRSI
- ENH: Phase corrected report
- add option to show phase corrected fit in main HTML report
- ENH: Preproc options
- Added option to suppress alignment step in fsl_mrs_preproc{_edit}
.
- Changed syntax for water removal in fsl_mrs_preproc{_edit}
from --hlsvd
to --remove-water
- Changed syntax for truncation in fsl_mrs_preproc{_edit}
from --leftshift {N}
to --truncate-fid {N}
- BF: basis_tools all_shift conjugation
- Basis sets are automatically conjugated when using basis_tools shift_all
.
- BF: preproc(edit) noalign
* Fixed bug introduced in 2.4.2 where the option to suppress alignment step in fsl_mrs_preproc{_edit}
only suppressed some alignment.
* Update minimum hlsvdpropy version to 2.0.2
Detailed history
Add negative voigt model
BF: minor bugs
ENH: P spline baseline in dynamic fitting
ENH: freeshift with lorentzian
ENH: Phase corrected report
ENH: Preproc options
BF: basis_tools all_shift conjugation
BF: preproc(edit) noalign
fsl-newimage 2203.12 -> 2501.4
- RF: Improve thread-safety of
NEWIMAGE::volume
class Builds on !41, which must be merged first.
This MR makes some adjustments to the NEWIMAGE::volume
class to improve thread safety.
-
Several member fields of the
volume
class were unnecessarily declared asmutable
, and several functions which modify fields were unnecessarily declared asconst
. -
Functions which modify the extrapolation/interpolation settings of a
const volume
have been marked as deprecated, and their use will cause a warning to be emitted at compilation time. -
The
extrapolate()
function previously returned a reference to themutable T extrapval
field, which was required in the unlikely event of client code writing to a out-of-bounds voxel via theoperator()
function (e.g.vol(-1, -1, -1) = 0;
). This has been changed so thatextrapolate()
now returns a reference to a member of the newextrapparams
class (more on this below); theextrapval
field has been removed from thevolume
class. -
The
userinterpolation
,userextrapolation
,boundsassert
,boundsexception
interpolation/extrapolation methods have been removed, as they were not being used anywhere throughout the FSL codebase. -
Fields related to spline interpolation have been left as
mutable
, as otherwise it would not be possible to have spline coefficients lazily calculated on-demand when performing spline interpolation on aconst volume
instance. Access to these fields were already being protected by astd::mutex
, and so should be thread-safe.
Downstream uses of the volume
class may have to be changed to ensure thread safety. Traditionally, a const volume
has allowed its interpolation and extrapolation settings to be changed, which has led to widespread use of this coding pattern:
extrapolation oldex = vol.getextrapolationmethod();
if (/* oldex isn't suitable for the current application */) {
vol.setextrapolationmethod(/* suitable extrapolation method */);
}
// do work which only involves reading from vol
float val = vol( x, y, z);
val = vol.interpolate(x, y, z);
// restore extrapolation method
vol.setextrapolationmethod(oldex);
Unfortunately, as this code mutates the state of the vol
object, it is not thread-safe. Therefore a compiler warning will now be emitted whenever setextrapolationmethod
is called on a const volume
. Additionally, the operator()
, interpolate
, splineinterpolate
, kernelinterpolation
and extrapolate
functions have been extended to accept a new optional extrapparams
parameter. This allows the extrapolation settings to be changed without having to change the state of the volume
instance, e.g.:
float val = vol( x, y, z, /* extrapolation parameters */);
val = vol.interpolate(x, y, z, /* extrapolation parameters */);
Similar changes have been made to the valid()
functions with respect to the setextrapolationvalidity
settings - code which previously had this structure (where vol
is a const volume
):
std::vector<bool> oldvalidity = vol.getextrapolationvalidity();
vol.setextrapolationvalidity(/* suitable validity */);
// do work, reading from from vol
// ...
if (vol.valid(x, y, z)) {
// ...
}
// ...
vol.setextrapolationvalidity(oldvalidity[0], oldvalidity[1], oldvalidity[2]);
should be adjusted to use this structure:
bool xvalid = /* suitable validity */;
bool yvalid = /* suitable validity */;
bool zvalid = /* suitable validity */;
// do work, reading from from vol
// ...
if (vol.valid(x, y, z, {xvalid, yvalid, zvalid})) {
// ...
}
// ...
This MR also makes some adjustments to the ShadowVolume
class to ensure that interpolation/extrapolation settings on a ShadowVolume
instance match that of the owning volume
instance. This was previously a given, as the volume::operator[]
function would return a new ShadowVolume
instance on every call. However, now that we are using a ShadowVolume
cache, there is a chance that the interpolation/extrapolation settings on a ShadowVolume
instance could get out of sync with those of its owning volume
. This has been resolved by refactoring the ShadowVolume
class so that it retains a reference to its owning volume
, and forwards all interpolation/extrapolation settings accesses to the owning volume.
- BF: Use volume
extrapolation getters rather than fields, as the fields may not have been initialised on ShadowVolume
instances, whereas the getters will delegate to the owning volume
- MNT: Adjust volume::invalidateSplines()
to resolve performance issue
Adjust the volume::invalidateSplines()
function so that it accesses the p_interpmethod
field directly instead of calling the virtual getinterpolationmethod()
function. The latter approach has a noticeable effect on performance when many large images need to be written to via the operator()
function.
In most circumstances use of getinterpolationmethod()
is necessary, as there are circumstances in which the p_interpmethod
field may not be set to the correct value on ShadowVolume
instances. However in this situation accessing p_interpmethod
is harmless - the code causes the ShadowVolume
cache to be cleared, but a ShadowVolume
instance will never cache other ShadowVolume
instances.
- ENH: Parallelise NEWIMAGE::convolve
operations on a per-voxel basis
The NEWIMAGE::convolve
routines are trivially parallelisable - the same operation is performed independently for each voxel. This MR parallelises the inner loops using the Utilities::parfor
routine, and uses source.nthreads()
as the number of threads to use - this essentially means that the value of the FSL_NUM_THREADS
environment variable will be used if it is set, or one thread will be used as the default.
This affects all uses of NEWIMAGE::smooth
and NEWIMAGE::generic_convolve
, for example the fslmaths -s
flag.
When run in single-threaded mode, the new code is slightly slower than the original code, by about 5%. This is primarily due to the additional overhead of use of the vbegin()
/vend()
functions, which use a NEWIMAGE::voxelIterator
to generate 3D voxel coordinates.
- MNT: Don't use source.nthreads()
to decide number of threads - just let NoOfThreads
select the default value
Detailed history
MNT: Normalise indentation
MNT: Adjust raw_affine_transform so it doesn't modify properties of a const volume
RF: Make all get/set interp/extrap functions virtual. Override set* functions in ShadowVolume so that they throw an error. Adjust ShadowVolume class so it stores a reference to its owning volume
RF: Add interp/extrap setting getters to ShadowVolume which delegate to the owning volume instance
MNT: Remove unused variable
RF: Handle interp/extrap settings access prior to initialisation, just by returning the ShadowVolume settings
RF: Make _owner a non-const pointer-to-const to allow copy-assignment
RF: Change ShadowVolume creation method. Instead of using constSubVolume, create directly from the source volume, calling initialize+copyproperties directly. Also save the 4D index to allow for copy construction.
TEST: Test that interp/extrap settings are propagated to shadowvolume instances
MNT: Template instantiations for some things in newimagefns.h, and a few fixes in those things
RF: Revert volume.initialize visibility back to protected. No need to be public, but can't be private, as ShadowVolume calls it.
TEST: std::execution not supported by clang?
BF: Use volume extrapolation getters rather than fields, as the fields won't have been initialised on ShadowVolume instances, whereas the getters will delegate to the owning volume
MNT: More useful error messages
MNT: Access p_interpmethod field directly instead of calling virtual getinterpolationmethod() function - the latter causes a noticeable slowdown when writing large images
TEST: Adjust test build to make in-source building easier
TEST: Sample off-centre when testing interpolation
ENH: Parallelise NEWIMAGE::convolve operations on a per-voxel basis
TEST: Basic unit tests for NEWIMAGE::convolve, both standard and masked versions, parallelising with different numbers of threads, comparing results against scipy.signal.convolve
MNT: Don't use source.nthreads() to decide number of threads - just let NoOfThreads select the default value
fsl-newmesh 2111.0 -> 2111.2
- MNT: Remove unnessary include statement -
fslsurface
is not required to buildnewmesh
- MNT: Need to link against
libfsl-utils
on macOS When compiling a shared library on macOS, one must link against the dependencies of the library. TheUtilities::NoOfThreads
struct was previously specified entirely in theutils/threading.h
header, but is now compiled, so must be linked against.
Detailed history
MNT: Remove unnessary include statement - fslsurface is not required to build newmesh
MNT: Need to link against libfsl-utils on macOS
fsl-pipe 1.2.2 -> 1.3.0
- Do not expect ignored value after
--skip-missing
- BF: linked placeholders can now be overwritten using the CLI
- Release v1.3.0
Detailed history
Do not expect ignored value after --skip-missing
BF: linked placeholders can now be overwritten using the CLI
Release v1.3.0
fsl-possum 2111.2 -> 2111.3
Detailed history
MNT: Don't need to adjust volume extrapolation, as boundsassert/boundsexception are no longer options
fsl-pyfeeds 0.13.1 -> 0.15.0
- RF: Adjust argument order for evaluation routines so they can be used by
feedsRun
scripts Thepyfeeds.evaluate.eval*
functions can now be called with just test file and benchmark file names. Not sure why I didn't do it this way in the first place. - BF,RF: Fix a few bugs, adjust
evalHeader
routine Adjusted theevalHeader
routine - now it comparesdim
andpixdim
for all valid dimensions by default. Thealldims
parameter has been replaced with andims
parameter, allowing the number of dimensions to be set (e.g. when you only want to compare the first three dimensions). - ENH: New
--printLogs
flag, which prints allfeedsRun.log
files on success or failure. Useful for when running tests in CI, and you don't have access to the output directory.
Detailed history
RF: Adjust argument order for evaluation routines so they can be used by feedsRun scripts. Not sure why I didn't do it this way in the first place.
TEST: Update tests for new eval routine signature
MNT: Bump version. Expose all eval routines at package level
DOC: Mention eval routines
BF:: copy+paste typo
MNT: Accept pathlib.Path, normalise to string for image cache keys. All other eval routines should already be compatible
RF: Adjust evalHeader so it compares all valid dimensions. Replace alldims arg with ndims for comparing 3D
BF: Not passing pyfeeds object to loadImage
BF: Typos/mistakes in tempdir routine
TEST: Tests are useful it turns out. Use pyfeeds.common.tempdir instead of pyfeeds.tests.tempdir
ENH: New --printLogs flag, which prints all feedsRun.log files on success or failure. Useful for when running tests in CI, and you don't have access to the output dir
fsl-shapemodel 2111.0 -> 2111.1
Detailed history
MNT: Need to link against fsl-utils
fsl-sub-plugin-slurm 1.6.5 -> 1.6.7
Detailed history
Fix account/project enumeration
Add documentation about smt option
Remove support for 3.8 Add 3.13
Remove 3.8 from CI file
fsl-tirl 3.6.2 -> v3.6.3
fsl-utils 2203.5 -> 2412.1
- ENH: Adjustments and enhancements to
threading.h
- Adjust the
NoOfThreads
class so that, if a value is not provided, or a value<=0
is provided, it will be set to a value read from the${FSL_NUM_THREADS}
environment variable, or 1 if that variable is not set. - Add new
parfor
andapply
functions for trivially parallelisable tasks. These functions perform essentially the same role asstd::for_eaach
andstd::transform
, but allow explicit control over the number of threads. - ENH: New
Utilities::ScopedTimer
class, for lightweight profiling A new class,ScopedTimer
, which allows code blocks to be timed in a lightweight manner. To use, you just need to create aScopedTimer
instance at the beginning of the code block to be timed, e.g.:
void some_func(bool some_cond) {
if (some_cond) {
ScopedTimer t("some_func - true branch");
// do work
}
else {
ScopedTimer t("some_func - false branch");
// do work
}
}
When the ScopedTimer
instance goes out of scope, its destructor will calculate the elapsed time, and emit a message to standard out, e.g. if some_func(false)
is called:
Detailed history
ENH: Adjust NoOfThreads so that it defaults to FSL_NUM_THREADS, which is read from the environment. Add two new utility functions, parfor and apply, for trivially parallelisable tasks over vector-likes
ENH: parfor/apply overloads which can be called without a NoOfThreads instance, and use the default number of threads (FSL_NUM_THREADS if set, single-threaded otherwise)
ENH: Variants for parfor/apply - they can now be called: - with a NoOfThreads instance - with an integer - without either, in which case FSL_NUM_THREADS will be used (or 1 if it is unset)
ENH: New Utilities::ScopedTimer class, for lightweight profiling
fsl-warpfns 2203.0 -> 2501.0
- ENH,RF: Use new features in
utils/threading.h
andnewimage::volume
to parallelise voxel-wise operations - Don't pass a value to
Utilities::NoOfThreads
- this allows it to take a value from theFSL_NUM_THREADS
environemnt variable (or default to single-threaded if that variable is unset) - Use
Utilities::parfor
to parallellise voxel-wise operations - Replace some instances of using
NEWIMAGE::volume[t] (x, y, z)
with eithervolume(x, y, z, t)
orauto volt = vol[t]; ... volt(x, y, z)
.
This MR depends on fsl/utils!15 and fsl/newimage!40
- RF: Change NEWIMAGE::volume
extrapolation settings in a thread-safe manner
This MR builds on !7, which must be merged first.
This MR makes some adjustments to the functions in warpfns.h
so that changes to the extrapolation settings of NEWIMAGE::volume
instances are made via passing in extrapparams
instances at the time of interpolation/extrapolation. These changes should be source-compatible with downstream projects, but they will require recompilation.
This is an alternative to using the setextrapolationmethod
and similar functions which, because they change the state of the volume
instance, cannot be safely used in multi-threaded applications.
I have also added a warpfns_stubs.cc
file which contains instantiations of the templated functions in warpfns.h
, to allow us to catch errors at build time, rather than when downstream code is compiled.
Detailed history
ENH,RF: Use new features in utils/newimage to parallelise voxel-wise operations. - Don't pass a value to Utilities::NoOfThreads - this allows it to take a value from the FSL_NUM_THREADS environemnt variable (or default to single-threaded) - Use Utilities::parfor to paralellise voxel-wise operations
ENH: Parallelise shift2warp
MNT: Use volume.operator(x,y,z,t) rather than volume[t] (x,y,z)
MNT: Normalise indentation
BF: Don't use auto with armadillo expressions; don't use volume.operator[] within voxel for-loops
MNT: Don't call setextrapolationmethod on const volumes - pass extrapolation settings into volume function calls instead
RF,BK: Rename set_extrapolation to calculate_extrapolation, and change it to return a pair of extrapolationparams instances. Next step is to update warpfns functions to pass these through.
MNT: Normalise indentation, pass input volume extrapolation params to affine_no_derivs/affine_with_derivs
MNT: Normalise indentation, pass extrapolationparams to displacements_[no,with]_iT
RF: Move extrapparams arguments alongside inputs - these are internal functions, so no need to preserve signature
RF,BF: Rename to extrapparams, a couple of fixes
RF: Adjust raw_general_transform to accept optional extrapparams for input volume and displacement field
RF: Adjust apply_warp to pass custom extrapolation parameters in rather than calling vol.setextrapolation..
MNT: Add stubs file which contains template instantiations of warpfns.h functions, to catch errors at build time
MNT: No longer need to adjust boundsassert/boundsexception extrapolation types, as they have been removed from newimage
BF: Accidentally re-declared variable
BF: Was calling wrong volume::valid overload - float coords silently coerced to int with no compiler warning. Fix logic in calculate_extrapolation - dfield method should be either periodic or extraslice
fsl-xtract 2.0.6 -> 2.0.7
Detailed history
Merge pull request #10 from SPMIC-UoN/xpy
minor fix to splash
minor fix: resolve splash escape sequence error
minor updates to splash
fsl-cudabasisfield 1.1.1 -> 1.1.2
Detailed history
MNT: Add FSL copyright placeholder
MNT: Use default compilation/dependency rules
fsl-mmorf v0.3.3 -> v0.4.2
- MNT: New
Config
class, for storing fixed global configuration settings Also added a--num_threads
command-line flag, which will be used in upcoming changes. - DOC: Add some entries to changelog
- DOC: More changelog updates
- MNT: Set version number from state of git repository
- MNT: Work-around
armadillo
performance regression MMORF v0.4.0 was found to have substantially slower runtime than v0.3.3 for a couple of reasons: - A change in
newimage
which has since been resolved (no changes needed to MMORF) - A subtle performance regression in
armadillo
The armadillo
issue has been resolved upstream, but as we will keep using armadillo
14.2.1 for some time, a work-around is needed in the MMORF code. When we upgrade armadillo
this work-around can be removed, although it is not particularly burdensome.
This MR also makes a few minor changes to the MMORF Makefile
to work with the latest version of the FSL build system.
- MNT: Revert behaviour of --version
so that it does not cause MMORF to exit
In version 0.4.0, the behaviour of the --version
flag was changed so that it would print the MMORF version number and then exit. This breaks compatibility with existing MMORF configuration files that contain version = true
, so this MR reverts the behaviour.
Detailed history
MNT: Use nthreads setting rather than hard-coding 6
DOC: Add some entries to changelog
DOC: More changelog updates
MNT: Set version number from git state
MNT: Print version at startup
MNT: formatting
MNT: Tweaks to Makefile to work with FSL build system behaviour - most notably: - use the default .cpp / .cu compilation rules - set "SRCDIR" before including default.mk, so that it doesn't try to take over our test compilation
TEST: Update to latest version of catch
TEST: Basic smoke test for main tensor cost function. Using pyfeeds test data
RF: Use temp matrix to store inverse to work around armadillo performance issue
MNT: CUDABUILDDIR should default to BUILDDIR if not set
RF: Revert behaviour of --version, as this was a breaking change