Ticket #966 (closed: fixed)
Single peak and multi BG (multiple workspace) Fitting
Reported by: | Nick Draper | Owned by: | Roman Tolchenov |
---|---|---|---|
Priority: | major | Milestone: | Iteration 30 |
Component: | Mantid | Keywords: | |
Cc: | Blocked By: | ||
Blocking: | Tester: | Martyn Gigg |
Description
Need to get more detail from Toby on this but this appears to be when you have several datasets and you want to optimise a single peak on each simultaneously while allowing separate background functions.
Change History
comment:1 Changed 11 years ago by Roman Tolchenov
- Milestone changed from Iteration 21 to Iteration 22
comment:2 Changed 10 years ago by Nick Draper
- Milestone changed from Iteration 26 to Iteration 27
Bulk move of tickets to iteration 27, if your ticket is essential for Iteration 26 then move it back.
comment:3 Changed 10 years ago by Nick Draper
- Milestone changed from Iteration 27 to Iteration 28
Bulk move of tickets at the end of iteration 27
comment:4 Changed 9 years ago by Nick Draper
- Milestone changed from Iteration 28 to Iteration 29
Bulk move of tickets at the end of iteration 28
comment:5 Changed 9 years ago by Nick Draper
- Milestone changed from Iteration 29 to Iteration 30
"New" tickets moved at the code freeze of iteration 29
comment:6 Changed 9 years ago by Roman Tolchenov
- Status changed from new to accepted
- Component set to Mantid
comment:10 Changed 9 years ago by Roman Tolchenov
In [14410]:
comment:10 Changed 9 years ago by Mathieu Doucet
In [14448]:
comment:11 Changed 9 years ago by Roman Tolchenov
In [14521]:
comment:12 Changed 9 years ago by Roman Tolchenov
In [14522]:
comment:13 Changed 9 years ago by Mathieu Doucet
In [14559]:
comment:14 Changed 9 years ago by Mathieu Doucet
In [14560]:
comment:15 Changed 9 years ago by Roman Tolchenov
- Status changed from accepted to verify
- Resolution set to fixed
comment:16 Changed 9 years ago by Russell Taylor
In [14641]:
comment:17 Changed 9 years ago by Russell Taylor
In [14642]:
comment:18 Changed 9 years ago by Vickie Lynch
- Status changed from verify to verifying
- Tester set to Vickie Lynch
comment:19 Changed 9 years ago by Vickie Lynch
- Status changed from verifying to verify
- Tester Vickie Lynch deleted
Can't get this to work
comment:20 Changed 9 years ago by Roman Tolchenov
To testers. It's easy:
- Load ~10 spectra from MUSR00015189.nxs
- Rebin to MUSR00015189_1 0,0.1,29
- Open the fit browser in MantidPlot.
- Select MUSR00015189_1 for fitting.
- Change function type from CompositeFunctionMW to MultiBG
- Add ExpDecay to Functions.
- Set the initial values: Height=400, Lifetime=2
- Right click on Functions and select Setup multifit
- Check the box against Lifetime in the dialog. This parameter will be global - the same for all spectra
- Press OK. The fit browser will be populated with copies of ExpDecay, one for each spectrum in the WS. All Lifetimes will be tied to f0.Lifetime.
- Click on Fit. Created output: MUSR00015189_1_NormalisedCovarianceMatrix, MUSR00015189_1_Parameters, MUSR00015189_1_Workspace, MUSR00015189_1_Param_series.
MUSR00015189_1_Workspace is a WorkspaceGroup, each member is similar to an output from a simple Fit
comment:21 Changed 9 years ago by Martyn Gigg
- Status changed from verify to verifying
- Tester set to Martyn Gigg
comment:22 Changed 9 years ago by Martyn Gigg
- Status changed from verifying to reopened
- Resolution fixed deleted
Observed a crash after following the above instructions which is related to the the algorithm notifications and threading issues.
comment:23 Changed 9 years ago by Roman Tolchenov
- Status changed from reopened to verify
- Resolution set to fixed
In [14845]:
comment:25 Changed 9 years ago by Martyn Gigg
Tried the same again and that looks much better and more responsive.
Also tried with larger and smaller data sets and it looked good.
I saw another crash though:
- If you perform steps 1-5
- Click addFunction and select MultiBG as the function type instead of ExpDecay
- When you click okay you get a crash. Unfortunately it is the default so this is probably worth looking at. The stack trace is below. Basically it seems to be a problem in Mantid::CurveFitting::MultiBG::getWorkspace
Program received signal SIGSEGV, Segmentation fault. 0x00007ffff6d71b04 in shared_ptr<Mantid::API::MatrixWorkspace const> (this=0x7fffffffbf20, r=...) at /usr/include/boost/smart_ptr/shared_ptr.hpp:238 238 : px( r.px ), pn( r.pn ) // never throws (gdb) bt #0 0x00007ffff6d71b04 in shared_ptr<Mantid::API::MatrixWorkspace const> (this=0x7fffffffbf20, r=...) at /usr/include/boost/smart_ptr/shared_ptr.hpp:238 #1 0x00007fffd56f5961 in Mantid::CurveFitting::MultiBG::getWorkspace (this=0x279b480) at /home/dmn58364/mantidproject/svn/trunk/Code/Mantid/Framework/CurveFitting/inc/MantidCurveFitting/MultiBG.h:62 #2 0x00007ffff65dccf4 in MantidQt::MantidWidgets::PropertyHandler::initWorkspace (this=0x29d45a0) at /home/dmn58364/mantidproject/svn/trunk/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp:311 #3 0x00007ffff65db9cd in MantidQt::MantidWidgets::PropertyHandler::init (this=0x29d45a0) at /home/dmn58364/mantidproject/svn/trunk/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp:127 #4 0x00007ffff6d5f683 in Mantid::API::IFitFunction::setHandler (this=0x279b590, handler=0x29d45b0) at /home/dmn58364/mantidproject/svn/trunk/Code/Mantid/Framework/API/src/IFitFunction.cpp:261 #5 0x00007ffff65dd927 in MantidQt::MantidWidgets::PropertyHandler::addFunction (this=0x174aa00, fnName=...) at /home/dmn58364/mantidproject/svn/trunk/Code/Mantid/MantidQt/MantidWidgets/src/PropertyHandler.cpp:435 #6 0x00007ffff65b2881 in MantidQt::MantidWidgets::FitPropertyBrowser::addFunction (this=0x1442040) at /home/dmn58364/mantidproject/svn/trunk/Code/Mantid/MantidQt/MantidWidgets/src/FitPropertyBrowser.cpp:539
comment:26 Changed 9 years ago by Martyn Gigg
- Status changed from verifying to reopened
- Resolution fixed deleted
comment:27 Changed 9 years ago by Roman Tolchenov
- Status changed from reopened to verify
- Resolution set to fixed
In [14848]:
comment:29 Changed 9 years ago by Martyn Gigg
- Status changed from verifying to closed
Confirmed that the function has been removed, as it wasn't supposed to be there anyway, so the crash can no longer occur.
comment:30 Changed 5 years ago by Stuart Campbell
This ticket has been transferred to github issue 1814