Ticket #9017 (closed: fixed)
ExtractMaskToTable bug
Reported by: | Peter Peterson | Owned by: | Roman Tolchenov |
---|---|---|---|
Priority: | major | Milestone: | Release 3.2 |
Component: | Framework | Keywords: | |
Cc: | Blocked By: | ||
Blocking: | Tester: | Peter Peterson |
Description (last modified by Peter Peterson) (diff)
This hasn't been fully characterized yet, but Antonio said:
I was under the impression that the mask bins from table was running however if the same bin is masked on two non-intercepting ranges, clearly something does not work properly as we still have some remaining unmasked bins, furthermore I have been faced with repeated segmentation faults (see error below). Would it be possible to discuss this capability, and what it is used for, with the person responsible so that we can sort this out for good? Thanks Antonio ExtractMaskToTable-[Notice] ExtractMaskToTable started ExtractMaskToTable-[Notice] InputWorkspace is a MaskWorkspace. ExtractMaskToTable-[Notice] [To implement] Parse input table workspace. ExtractMaskToTable-[Notice] About to copying input table workspace content to output workspace.. /var/tmp/sclXFCu4S: line 8: 5396 Segmentation fault (core dumped) /opt/Mantid/bin/MantidPlot_exe
To reproduce the bug (data file doesn't matter):
- LoadEventNexus(SNAP_14666_event.nxs)
- Bring up the instrument view and rotate to see a single side of the instrument and switch to the Mask/Group tab
- Reduce the TOF range to 1000-2000 (arbitrary)
- Mask a region and "Apply and Save" "As Mask to table"
- Close the instrument view
- MaskBinsFromTable with that workspace
- Bring up the instrument view again
- Change the TOF range to 1500-2500 (arbitrary but partially overlapping)
- Mask an overlapping region and "Apply and Save" "As Mask to table"
- CRASH!
Change History
comment:2 Changed 7 years ago by Peter Peterson
- Status changed from assigned to inprogress
- Description modified (diff)
comment:3 Changed 7 years ago by Peter Peterson
- Owner changed from Peter Peterson to Roman Tolchenov
Some notes from Roman and me:
- This only happens on instruments with rectangular detectors
- Having overlapping x-range does not matter
- Having overlapping pixel ids is required
comment:4 Changed 7 years ago by Roman Tolchenov
The bug is in ExtractMaskToTable addToTableWorkspace method. If there are no new detector ids to add a vector gets emptied and used without size checking.
Simpler steps to reproduce the bug:
- Open instrument view (any instrument)
- Mask a region and "Apply and Save" "As Mask to table"
- Use "Apply and Save" "As Mask to table" again
- Crash
comment:5 Changed 7 years ago by Roman Tolchenov
Re #9017. Check for empty vector.
Changeset: cf7771af8f3a5235188c45684b7ff93df0be7963
comment:6 Changed 7 years ago by Roman Tolchenov
Re #9017. Added a test case to test the fix.
Changeset: 9c634d2c96270ef6559bbddeffd07532b9898ccb
comment:7 Changed 7 years ago by Roman Tolchenov
- Status changed from inprogress to verify
- Resolution set to fixed
comment:8 Changed 7 years ago by Peter Peterson
- Status changed from verify to verifying
- Tester set to Peter Peterson
comment:9 Changed 7 years ago by Peter Peterson
- Status changed from verifying to closed
Merge remote branch 'origin/bugfix/9017_extractmasktotable_bug'
Full changeset: a1a819a1edef3fcfd3669613b97c5abb6b0b2d82
comment:10 Changed 5 years ago by Stuart Campbell
This ticket has been transferred to github issue 9860