Framework Changes#

Algorithms#

New features#

  • A new algorithm SaveMDToAscii v1 has been added to save an MDHistoWorkspace to a plain ASCII file, with configurable exclusion of integrated dimensions, normalization, column separator and numeric precision.

  • HFIRPowderReduction v1 now attempts to autopopulate the sample absorption parameters if correct data is found in sample run files

  • SumSpectra v1 algorithm has been optimized for better performance.

  • The Fit v1 algorithm now allows setting step sizes to customize the perturbation applied to each parameter value while fitting. Setting the StepSizeMethod to Custom will allow the step sizes list to be passed using the CustomStepSizes parameter.

  • EstimatePeakIntensities v1 allows parallel, fit-free estimation of peak intensities within specified windows, using a skew-seeded background estimation.

  • MDNormDirectSC v1 can now handle MDEvent workspaces created by ConvertToMD v1 with the UseLogTimes property.

  • HFIRPowderReduction v1 now has an IDFFilename property to optionally override the instrument geometry from the sample file, and loads MIDAS data with LoadEventAsWorkspace2D v1.

  • Algorithm ConvertToMD v1 with option UseLogTimes can use the time series logs at event times as coordinates for extra dimensions when log names are added in OtherDimensions property.

  • Parallelisation added to ConvertToMD v1 and improved in MDNormDirectSC v1.

  • FileFinder and MultipleFileProperty now resolve multi-run hint strings (ranges and lists) in a single batched archive lookup for HFIR and SNS data, replacing the previous per-run network round trips to ONCat.

  • FitPeaks v1 now has StrictConvergence flag, which decides whether fits which have finished due to the parameter step size passing below the stopping threshold should be considered as successful - default is True to match previous behaviour.

  • FitPeaks v1 now accepts Unweighted least squares cost function.

  • FitPeaks v1 now has PositionToleranceMode input which controls PositionTolerance behaviour. Default is Check which maintains previous behaviour of the positional tolerance being checked after the fit and discarding any fits outside tolerance. This parameter enables Constrain mode, which will instead apply the tolerances as constraints on the fit. Constrain mode requires ConstrainPeakPositions be disabled.

  • FitPeaks v1 now has CalculateUnconstrainedErrors which controls whether the errors for fits should be recomputed after the fit, without the constraints applied. Default is False.

  • FitPeaks v1 now has PositionToleranceFractional which controls whether the PositionTolerance should be treated as a fraction of the peak window (True) or as an absolute value (False, default).

  • Algorithm ConvertToMD v1 now accepts an option, UseLogTimes, to use log times of neutron events in coordinate calculations instead of their average.

  • Stitch1D and Stitch1DMany now have a UseValidDataOnly option which, when true, ignores the contribution of invalid signal values to overlap bins when another workspace has valid data in the same bin. When false (default) previous behaviour is maintained, where presence of invalid data in an overlap bin from either workspace results in the same invalid value in the output workspace.

  • The VesuvioTransmission v1 algorithm has been added which evaluates the transmission spectrum on the VESUVIO spectrometer for measured sample and empty run numbers.

  • A new property OutputWorkspaceSuffixes has been added to the Stitch1DMany v1 algorithm, which allows users to specify custom suffixes for the child workspaces in the output group when stitching workspace groups.

Bugfixes#

  • SaveDaveGrp v1 algorithm now optionally converts the spectrum numbers into Q values using GetQsInQENSData v1 when creating the .grp file.

  • CopySample v1 no longer causes a crash when called with CopyShape = False, CopyMaterial = True and an input workspace that is subsequently overwritten.

  • Algorithm SaveYDA now correctly distinguishes between spectra and bin center axes when saving data.

  • In BeamProfileFactory the auto-generated beam profile dimensions are now correct when the sample bounding box is offset from the origin. The beam half-extent is now taken from the furthest sample face on either side, so the beam remains valid for samples that are translated or rotated into a negative half-space.

  • In EstimateScatteringVolumeCentreOfMass the shape object now accounts for the goniometer set on the workspace. Previously this was not the case which gave erroneous values in non-rotationally symmetric situations.

  • FileFinder now recognises compound file extensions (e.g. .nxs.h5) listed in Facilities.xml when expanding multi-run hints, so ranges such as CNCS100:105.nxs.h5 resolve correctly instead of being misinterpreted as a stem ending in .nxs plus an .h5 extension. As a consequence, a hint that explicitly specifies one extension (e.g. BSS_24234_event.nxs or SXD30904.raw.md5) no longer silently resolves to a file with a different extension; specify the run number without an extension to let the facility’s preferred extensions apply.

  • In FitPeaks v1, the PeakParameterValueTable input option now reads and applies row-per-spectra parameter starting values. Previously this functionality was declared but was not applied.

  • :ref: CreateDetectorTable <algm-CreateDetectorTable> has received some performance improvements that should speed up the algorithm significantly for large workspaces with many spectra. This algorithm is used in the new Instrument View when opening, so this should improve the performance of that interface as well.

  • ExtractSpectra no longer gives an error when the argument DetectorList is used on focused workspaces where a workspace index maps to several detector IDs.

Deprecated#

  • The DPDFreduction algorithm has been deprecated and has no direct replacement.

Removed#

  • Removed SofQWCentre and SofQWPolygon (deprecated since release 6.12.0).

  • Removed the deprecated BayesQuasi and BayesStretch algorithms, which were based on the quasielasticbayes library. Users should now use the new quickbayes replacements, BayesQuasi2 v1 and BayesStretch2 v1, respectively.

Fit Functions#

New features#

Bugfixes#

  • In an Instrument Parameter File, defined fitting parameters no longer erroneously overwrite if they have the same name but for different functions (e.g. Bk2BkExpConvPV:Gamma and IkedaCarpenterPV:Gamma).

Deprecated#

Removed#

Data Objects#

New features#

  • Sample Environment is now saved in the Nexus File

  • getInstrumentName() can be used on workspaces or ExperimentInfo objects to get the name of the underlying instrument. Use this instead of getInstrument().getName().

Bugfixes#

  • Fixed a boundary-condition bug in MDGridBox splitting where events exactly on a child box’s upper boundary could be dropped during serial or threaded splitting.

Live Data#

New features#

Bugfixes#

  • The SNSLiveEventDataListener state machine is refactored to simplify its structure, remove race conditions, and make all state transitions explicit. These changes primarily add to the ILiveListener interface, deprecating its runStatus method, but otherwise leave most ILiveListener implementations largely unchanged.

Python#

New features#

  • Instrument now has getXmlText exposed to python.

  • The dimensions of an IMDHistoWorkspace can now have their name and units edited from Python via getDimension(i).setName(...) and getDimension(i).setUnits(...). Editing units is supported for HKL and general frames; an HKL dimension accepts r.l.u. or an inverse-Angstrom-style label such as in 2.5 A^-1. This is useful for relabelling the dimensions produced by MDNorm for unusual projections.

  • MeshObject now has getBoundingBox exposed to python.

  • MDHistoWorkspace now provides setNumEventsArray to overwrite the number-of-events array from a numpy array, mirroring the existing setSignalArray and setErrorSquaredArray methods. Manual updates through these array setters clear any link to the original MDEventWorkspace so downstream rebinning or slicing cannot bypass the manually-set values.

Bugfixes#

  • Fixed a crash where a Peak retrieved from a PeaksWorkspace in Python could reference deleted memory after the owning workspace is deleted. Peaks now share ownership of their workspace, keeping it alive for as long as the peak is in use.

Deprecated#

  • MatrixWorkspace now exposes the preferred Histogram data accessors to python: x(), y(), e(), dx() (read-only numpy wrappers) and mutableX(), mutableY(), mutableE(), mutableDx() (writable numpy wrappers). These replace the legacy readX()/readY()/readE()/readDx() and dataX()/dataY()/dataE()/dataDx() methods, which are now deprecated and emit a DeprecationWarning naming the replacement, but continue to work and return the same data. See the Transition to the HistogramData module concept page for more information on the Histogram data model.

  • The deprecation warnings above are emitted via PyErr_Warn(PyExc_DeprecationWarning, …), equivalent to warnings.warn(message, DeprecationWarning), and follow Python’s standard warnings filtering: by default they are printed only for deprecated calls made directly from a user script or interactive session (__main__), once per call site, while calls from inside imported modules are silent. Run Python with -W default (or use warnings.simplefilter("default")) to surface every occurrence, or error in place of default to raise them as exceptions when hunting call sites in tests or CI.

  • dx()/mutableDx() behave the same way readDx()/dataDx() always have: if no Dx (x-error) data has been set on the spectrum, it is first initialized to zeros, so these methods are always safe to call without first checking hasDx().

  • Much of the legacy Instrument object tree exposed to python is now deprecated in favour of the index-based SpectrumInfo/DetectorInfo/ComponentInfo access layers. Calling the deprecated members now emits a DeprecationWarning naming the replacement. Affected members include getInstrument(), Instrument.getComponentByName/getDetector/getSample/getSource/getNumberDetectors/findRectDetectors/findGridDetectors, IComponent.getPos/getName/getFullName/type/getRelativeRot, Component.getRotation/getRelativePos, ICompAssembly.nelements/__len__/__getitem__, IObjComponent.shape and IDetector.getID/solidAngle/getTwoTheta/getPhi. The methods continue to work for now; see the Instrument Access via SpectrumInfo, DetectorInfo, ComponentInfo concept page for the recommended replacements.

  • The deprecation warnings above are emitted via PyErr_Warn(PyExc_DeprecationWarning, …), equivalent to warnings.warn(message, DeprecationWarning), and follow Python’s standard warnings filtering: by default they are printed only for deprecated calls made directly from a user script or interactive session (__main__), once per call site, while calls from inside imported modules are silent. Run Python with -W default (or use warnings.simplefilter("default")) to surface every occurrence, or error in place of default to raise them as exceptions when hunting call sites in tests or CI.

  • ComponentInfo now exposes solidAngle(index, observer) and componentType(index) (returning a ComponentType) to python. These provide index-based replacements for IDetector.solidAngle and the RectangularDetector/GridDetector type checks, as part of the migration to the ComponentInfo/DetectorInfo access layers.

  • MatrixWorkspace now exposes the preferred Histogram data accessors to python: x(), y(), e(), dx() (read-only numpy wrappers) and mutableX(), mutableY(), mutableE(), mutableDx() (writable numpy wrappers). These replace the legacy readX()/readY()/readE()/readDx() and dataX()/dataY()/dataE()/dataDx() methods, which are now deprecated and emit a DeprecationWarning naming the replacement, but continue to work and return the same data. See the Transition to the HistogramData module concept page for more information on the Histogram data model.

  • dx()/mutableDx() behave the same way readDx()/dataDx() always have: if no Dx (x-error) data has been set on the spectrum, it is first initialized to zeros, so these methods are always safe to call.

  • The deprecation warnings above are emitted via PyErr_Warn(PyExc_DeprecationWarning, …), equivalent to warnings.warn(message, DeprecationWarning), and follow Python’s standard warnings filtering: by default they are printed only for deprecated calls made directly from a user script or interactive session (__main__), once per call site, while calls from inside imported modules are silent. Run Python with -W default (or use warnings.simplefilter("default")) to surface every occurrence, or error in place of default to raise them as exceptions when hunting call sites in tests or CI.

Dependencies#

New features#

  • Upgraded python to 3.13. See the changes made to python here.

  • Removed dependence on the quasielasticbayes library to facilitate the upgrade to Qt6.

Bugfixes#

MantidWorkbench#

See Mantid Workbench Changes.

Release 7.0.0