Ticket #8547 (closed: fixed)
Make the MuonAnalysis less sensitive to filenames
Reported by: | Arturs Bekasovs | Owned by: | Arturs Bekasovs |
---|---|---|---|
Priority: | critical | Milestone: | Release 3.2 |
Component: | Muon | Keywords: | |
Cc: | Blocked By: | #8020 | |
Blocking: | #2369 | Tester: | Roman Tolchenov |
Description
Instead of getting the instrument name from the filename, we should get it from the loaded workspace, letting Load algorithm deal with how it gets it.
In that case, we can use files like 00015189.nxs instead of MUSR00015189.nxs.
Change History
comment:2 Changed 7 years ago by Arturs Bekasovs
- Blocking 8020 added
There is a slight difficulty with that one: if we are not using the filename to determine the instrument, we can't actually say that the file user is trying to load is not a Muon file before actually loading it. This makes it much easier to reproduce the problem described in #8020. So it makes sense to do that other ticket first. Afterwards, I will be able to just throw an error if I determine that the instrument of the loaded workspace is not a Muon instrument and nothing will get affected.
comment:3 Changed 7 years ago by Arturs Bekasovs
- Blocking 8020 removed
- Blocked By 8020 added
Mixed up "Blocking" and "Blocked By".
comment:7 Changed 7 years ago by Arturs Bekasovs
- Summary changed from [Muon] Make the MuonAnalysis less sensitive to filenames to Make the MuonAnalysis less sensitive to filenames
comment:8 Changed 7 years ago by Nick Draper
- Status changed from new to assigned
Bulk move of tickets out of triage (new) to assigned at the introduction of the triage state
comment:9 Changed 7 years ago by Arturs Bekasovs
There is slight disadvantage with that approach: files with run_number set to 0 will have names like EMU00000000. Asked Steve Cottrell whether this can be a problem. Waiting for the answer.
comment:10 Changed 7 years ago by Arturs Bekasovs
- Status changed from assigned to inprogress
Steve haven't answered, so I am going ahead with this. If zero run numbers will become a problem, I'll fix it separately.
comment:11 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Methods to get run[s] label from ws and tests for them.
Changeset: 93c1a972c6acc8b78ea5e783dac9e63d84de1dd1
comment:12 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Move sumWorkspaces to helper, fix it and add tests.
sumWorkspaces method was modifying the first workspace in the list passed in, which caused problems.
Changeset: ef9cb6d5d694c15c2c39758995f30ed8ef7f6136
comment:13 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Make load() return the label.
Changeset: 1028041705953ceed6302e73bca5ce5ec570ee34
comment:14 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Use the returned label, create and store a group for it.
Instead of getting group name and retrieving it on every plot, we can just store a pointer to the group.
Changeset: a7a05f1927c6592ee0997c1c26deea9cf688228d
comment:15 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Remove unused functions.
Changeset: 77d712a1b10042105081cf55caf94b346110804e
comment:16 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Different zero-padding width for ARGUS.
Changeset: afd9a93945675ae382a134060d61aac84422923f
comment:17 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Re-use logic of getLabel.
Changeset: 61c926d24cd0142487daea3a00e0d7a4e77236aa
comment:18 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Remove numerous Plus algorithm log messages.
Changeset: 7822bee681945bebc3ce62e760004d389ac826f4
comment:19 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Better error-reporting.
Changeset: 1e0b2c3a7cd238f63f67a2a2f1695d6779183562
comment:20 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Check group membership by name, not pointer.
Otherwise we end up with multiple workspaces with the same name in the group.
Changeset: 10ab90f7c1867df24bae51030ce3737c4c5aa734
comment:21 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Remove another unused function.
Changeset: c51fc72da94dc26cc6872396ad907b5ffd128cb9
comment:22 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Use the proper way to get zero padding for the instrument
Changeset: 35d2164ac6ae58345026868fbab69d1c7bc5ba28
comment:23 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Merge 'origin/master' into 8547
Conflicts:
Code/Mantid/MantidQt/CustomInterfaces/inc/MantidQtCustomInterfaces/MuonAnalysis.h Code/Mantid/MantidQt/CustomInterfaces/src/MuonAnalysis.cpp Code/Mantid/MantidQt/CustomInterfaces/src/MuonAnalysisHelper.cpp
Changeset: 09a0125611e691e53d1300b45f3c711b06a3ce27
comment:24 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Use the proper DLL export macro
Should fix windows builds.
Changeset: 7325e87e810656ce40bdbedf7900c3439eb6ac44
comment:25 Changed 7 years ago by Arturs Bekasovs
Refs #8547. Move local comparison structure to comparison function
Should fix RHEL builds
Changeset: c93603ad1402147115c7c4d9d30c9c2842b95670
comment:26 Changed 7 years ago by Arturs Bekasovs
Tester:
Copy MUSR00015189.nxs, MUSR00015190.nxs and MUSR00015191.nxs files from AutoTestData directory to a different one and rename them to something like my_musr_file1.nxs, my_musr_files2.nxs and my_musr_file3.nxs.
In MuonAnalysis, try to load my_musr_file1.nxs. Check that the file is loaded fine and the workspaces group is named correctly (MUSR00015189). Make a few plots. Make sure they end up in the right group.
Now try to load all 3 files at once. Again, check that thet are loaded fine and the group name is sensible (MUSR00015189-91). Plot Counts of some group and verify that numbers seem to be correct (should be approx. 3 times higher that the ones from a single file).
Try to load a non-Muon instrument file. Try to load files of different Muon instruments at once. Do more checks to make sure the right files are loaded and the wrong ones are discarded, no matter what the filename is.
comment:27 Changed 7 years ago by Arturs Bekasovs
- Status changed from inprogress to verify
- Resolution set to fixed
comment:28 Changed 7 years ago by Arturs Bekasovs
- Blocking 2369 added
comment:29 Changed 7 years ago by Roman Tolchenov
- Status changed from verify to verifying
- Tester set to Roman Tolchenov
comment:30 Changed 7 years ago by Roman Tolchenov
- Status changed from verifying to closed
Merge remote-tracking branch 'origin/feature/8547_muonanalysis_filenames'
Full changeset: 726a4f8d6d76290b2bf82357538c952a458a6238
comment:31 Changed 5 years ago by Stuart Campbell
This ticket has been transferred to github issue 9391
That's really annoying scientists.