Ticket #1313 (closed: fixed)
Modify SimpleRebin algorithm to work with EventWorkspace
Reported by: | Janik Zikovsky | Owned by: | Janik Zikovsky |
---|---|---|---|
Priority: | major | Milestone: | Iteration 24 |
Component: | Keywords: | ||
Cc: | Blocked By: | ||
Blocking: | Tester: | Michael Reuter |
Description
SimpleRebin needs to check if its input workspace is an EventWorkspace, and simply setX in this case (it does not need to recalculate everything immediately).
Change History
comment:10 Changed 10 years ago by Janik Zikovsky
comment:11 Changed 10 years ago by Janik Zikovsky
comment:12 Changed 10 years ago by Janik Zikovsky
comment:13 Changed 10 years ago by Janik Zikovsky
- Status changed from accepted to closed
- Resolution set to fixed
comment:14 Changed 10 years ago by Russell Taylor
- Status changed from closed to reopened
- Resolution fixed deleted
comment:15 Changed 10 years ago by Russell Taylor
comment:16 Changed 10 years ago by Peter Peterson
comment:18 Changed 10 years ago by Janik Zikovsky
comment:19 Changed 10 years ago by Janik Zikovsky
I am getting a semi-reproducible segfault in MantidPlot with the following steps:
- Load PG3_732 neutron event data.
- AlignDetectors in the same event workspace
- DiffractionFocussing, same WS
- Rebin: 0, 1e-3, 3.0; same WS
- Display data
- Plot all 3 spectra
- Rebin again: 1, 1e-6, 1.2. Sometimes this segfaults right away, sometimes I have to rebin a couple more times before it segfaults.
I reproduced this in the release but I am usually in a debug MantidPlot+libraries build.
comment:20 Changed 10 years ago by Janik Zikovsky
(Reposting to fix formatting)
I am getting a semi-reproducible segfault in MantidPlot with the following steps:
- Load PG3_732 neutron event data.
- AlignDetectors in the same event workspace
- DiffractionFocussing, same WS
- Rebin: 0, 1e-3, 3.0; same WS
- Display data
- Plot all 3 spectra
- Rebin again: 1, 1e-6, 1.2. Sometimes this segfaults right away, sometimes I have to rebin a couple more times before it segfaults.
I reproduced this in the release but I am usually in a debug MantidPlot+libraries build.
comment:21 Changed 10 years ago by Janik Zikovsky
I have identified the bug as being specific to MantidPlot, and in particular, you need to have a plot window open while rebinning for it to fail. Stack trace:
Thread [1] (Suspended: Signal 'SIGSEGV' received. Description: Segmentation fault.)
70 MantidQwtData::x() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidCurve.cpp:377 0x000000000096c6c7 69 QwtPlotCurve::drawSteps(QPainter*, QwtScaleMap const&, QwtScaleMap const&, int, int) const() 0x00007ffff759ab52 68 QwtPlotCurve::draw(QPainter*, QwtScaleMap const&, QwtScaleMap const&, int, int) const() 0x00007ffff7598eb2 67 MantidCurve::draw() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidCurve.cpp:163 0x000000000096ad52 66 QwtPlot::drawItems(QPainter*, QRect const&, QwtScaleMap const*, QwtPlotPrintFilter const&) const() 0x00007ffff7594960 65 Plot::drawItems() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Plot.cpp:223 0x000000000082294f 64 QwtPlot::drawCanvas() 0x00007ffff7594aba 63 QwtPlotCanvas::drawCanvas() 0x00007ffff75ada34 62 QwtPlotCanvas::drawContents() 0x00007ffff75adb86 61 QwtPlotCanvas::paintEvent() 0x00007ffff75add6f 60 QWidget::event() 0x00007ffff2b1e7a0 59 QFrame::event() 0x00007ffff2e7a2a6 58 QApplicationPrivate::notify_helper() 0x00007ffff2acfefc 57 QApplication::notify() 0x00007ffff2ad71ce 56 MantidApplication::notify() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidApplication.cpp:23 0x00000000008f3af7 55 QCoreApplication::notifyInternal() 0x00007ffff2321c2c 54 QWidgetPrivate::drawWidget() 0x00007ffff2b25b93 53 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 52 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b26204 51 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 50 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 49 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 48 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 47 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 46 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 45 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 44 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 43 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 42 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 41 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 40 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 39 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 38 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 37 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 36 <symbol is not available> 0x00007ffff2c97e1e 35 QWidgetPrivate::syncBackingStore() 0x00007ffff2b17fa0 34 QWidget::event() 0x00007ffff2b1e5b8 33 QMainWindow::event() 0x00007ffff2e949db 32 QApplicationPrivate::notify_helper() 0x00007ffff2acfefc 31 QApplication::notify() 0x00007ffff2ad71ce 30 MantidApplication::notify() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidApplication.cpp:23 0x00000000008f3af7 29 QCoreApplication::notifyInternal() 0x00007ffff2321c2c 28 <symbol is not available> 0x00007ffff2c95317 27 <symbol is not available> 0x00007ffff2c984f6 26 QWidget::repaint() 0x00007ffff2b19f1b 25 QwtPlotCanvas::replot() 0x00007ffff75adea0 24 QwtPlot::replot() 0x00007ffff7594d44 23 MantidCurve::dataReset() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidCurve.cpp:275 0x000000000096bae4 22 MantidCurve::qt_metacall() /home/janik/Code/Mantid/Code/qtiplot/tmp/qtiplot/debug/moc_MantidCurve.cpp:75 0x0000000000a82401 21 QMetaObject::activate() 0x00007ffff2336ddc 20 MantidCurve::resetData() /home/janik/Code/Mantid/Code/qtiplot/tmp/qtiplot/debug/moc_MantidCurve.cpp:88 0x0000000000a82483 19 MantidCurve::afterReplaceHandle() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidCurve.cpp:281 0x000000000096bbb3 18 ObserverCallback::handleAfterReplace() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/WorkspaceObserver.cpp:16 0x000000000096cdac 17 ObserverCallback::qt_metacall() /home/janik/Code/Mantid/Code/qtiplot/tmp/qtiplot/debug/moc_WorkspaceObserver.cpp:83 0x0000000000a82af2 16 QObject::event() 0x00007ffff23310f9 15 QApplicationPrivate::notify_helper() 0x00007ffff2acfefc 14 QApplication::notify() 0x00007ffff2ad71ce 13 MantidApplication::notify() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidApplication.cpp:23 0x00000000008f3af7 12 QCoreApplication::notifyInternal() 0x00007ffff2321c2c 11 QCoreApplicationPrivate::sendPostedEvents() 0x00007ffff232280a 10 <symbol is not available> 0x00007ffff234a533 9 g_main_context_dispatch() 0x00007fffec5febce 8 <symbol is not available> 0x00007fffec602598 7 g_main_context_iteration() 0x00007fffec6026c0 6 QEventDispatcherGlib::processEvents() 0x00007ffff234a1a6 5 <symbol is not available> 0x00007ffff2b644be 4 QEventLoop::processEvents() 0x00007ffff2320532 3 QEventLoop::exec() 0x00007ffff2320904 2 QCoreApplication::exec() 0x00007ffff2322ab9 1 main() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/main.cpp:175 0x000000000081d343
comment:22 Changed 10 years ago by Janik Zikovsky
Once again, the formatting was screwed up:
Thread [1] (Suspended: Signal 'SIGSEGV' received. Description: Segmentation fault.) 70 MantidQwtData::x() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidCurve.cpp:377 0x000000000096c6c7 69 QwtPlotCurve::drawSteps(QPainter*, QwtScaleMap const&, QwtScaleMap const&, int, int) const() 0x00007ffff759ab52 68 QwtPlotCurve::draw(QPainter*, QwtScaleMap const&, QwtScaleMap const&, int, int) const() 0x00007ffff7598eb2 67 MantidCurve::draw() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidCurve.cpp:163 0x000000000096ad52 66 QwtPlot::drawItems(QPainter*, QRect const&, QwtScaleMap const*, QwtPlotPrintFilter const&) const() 0x00007ffff7594960 65 Plot::drawItems() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Plot.cpp:223 0x000000000082294f 64 QwtPlot::drawCanvas() 0x00007ffff7594aba 63 QwtPlotCanvas::drawCanvas() 0x00007ffff75ada34 62 QwtPlotCanvas::drawContents() 0x00007ffff75adb86 61 QwtPlotCanvas::paintEvent() 0x00007ffff75add6f 60 QWidget::event() 0x00007ffff2b1e7a0 59 QFrame::event() 0x00007ffff2e7a2a6 58 QApplicationPrivate::notify_helper() 0x00007ffff2acfefc 57 QApplication::notify() 0x00007ffff2ad71ce 56 MantidApplication::notify() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidApplication.cpp:23 0x00000000008f3af7 55 QCoreApplication::notifyInternal() 0x00007ffff2321c2c 54 QWidgetPrivate::drawWidget() 0x00007ffff2b25b93 53 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 52 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b26204 51 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 50 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 49 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 48 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 47 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 46 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 45 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 44 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 43 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 42 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 41 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 40 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 39 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 38 QWidgetPrivate::paintSiblingsRecursive() 0x00007ffff2b262f0 37 QWidgetPrivate::drawWidget() 0x00007ffff2b25803 36 <symbol is not available> 0x00007ffff2c97e1e 35 QWidgetPrivate::syncBackingStore() 0x00007ffff2b17fa0 34 QWidget::event() 0x00007ffff2b1e5b8 33 QMainWindow::event() 0x00007ffff2e949db 32 QApplicationPrivate::notify_helper() 0x00007ffff2acfefc 31 QApplication::notify() 0x00007ffff2ad71ce 30 MantidApplication::notify() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidApplication.cpp:23 0x00000000008f3af7 29 QCoreApplication::notifyInternal() 0x00007ffff2321c2c 28 <symbol is not available> 0x00007ffff2c95317 27 <symbol is not available> 0x00007ffff2c984f6 26 QWidget::repaint() 0x00007ffff2b19f1b 25 QwtPlotCanvas::replot() 0x00007ffff75adea0 24 QwtPlot::replot() 0x00007ffff7594d44 23 MantidCurve::dataReset() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidCurve.cpp:275 0x000000000096bae4 22 MantidCurve::qt_metacall() /home/janik/Code/Mantid/Code/qtiplot/tmp/qtiplot/debug/moc_MantidCurve.cpp:75 0x0000000000a82401 21 QMetaObject::activate() 0x00007ffff2336ddc 20 MantidCurve::resetData() /home/janik/Code/Mantid/Code/qtiplot/tmp/qtiplot/debug/moc_MantidCurve.cpp:88 0x0000000000a82483 19 MantidCurve::afterReplaceHandle() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidCurve.cpp:281 0x000000000096bbb3 18 ObserverCallback::handleAfterReplace() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/WorkspaceObserver.cpp:16 0x000000000096cdac 17 ObserverCallback::qt_metacall() /home/janik/Code/Mantid/Code/qtiplot/tmp/qtiplot/debug/moc_WorkspaceObserver.cpp:83 0x0000000000a82af2 16 QObject::event() 0x00007ffff23310f9 15 QApplicationPrivate::notify_helper() 0x00007ffff2acfefc 14 QApplication::notify() 0x00007ffff2ad71ce 13 MantidApplication::notify() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/Mantid/MantidApplication.cpp:23 0x00000000008f3af7 12 QCoreApplication::notifyInternal() 0x00007ffff2321c2c 11 QCoreApplicationPrivate::sendPostedEvents() 0x00007ffff232280a 10 <symbol is not available> 0x00007ffff234a533 9 g_main_context_dispatch() 0x00007fffec5febce 8 <symbol is not available> 0x00007fffec602598 7 g_main_context_iteration() 0x00007fffec6026c0 6 QEventDispatcherGlib::processEvents() 0x00007ffff234a1a6 5 <symbol is not available> 0x00007ffff2b644be 4 QEventLoop::processEvents() 0x00007ffff2320532 3 QEventLoop::exec() 0x00007ffff2320904 2 QCoreApplication::exec() 0x00007ffff2322ab9 1 main() /home/janik/Code/Mantid/Code/qtiplot/qtiplot/src/main.cpp:175 0x000000000081d343
comment:25 Changed 10 years ago by Michael Reuter
- Status changed from verify to verifying
- Tester set to Michael Reuter
comment:26 Changed 10 years ago by Michael Reuter
- Status changed from verifying to closed
I have verified that the algorithm specified does work as intended. I can also reproduce the crash. My recommendation is to close this ticket as is and Janik will open a new one detailing the crash itself. The ticket for the crash is #1524.
comment:27 Changed 5 years ago by Stuart Campbell
This ticket has been transferred to github issue 2160