Closed MohamedAlmaki closed 1 month ago
When clicking on question mark on a Superplot it links to the docs on Basic 1D and Tiled plots but might be good if it linked to the Superplot docs: https://docs.mantidproject.org/nightly/workbench/superplot.html?
Loading this data and then doing a colorfill plot, I get an error https://stfc365-my.sharepoint.com/:t:/r/personal/robert_applin_stfc_ac_uk/Documents/Documents/WV_96538.txt?csf=1&web=1&e=TAOVRO
Traceback (most recent call last):
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/workbench/plugins/workspacewidget.py", line 217, in _do_plot_colorfill
pcolormesh(names)
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/mantid/plots/plotfunctions.py", line 89, in inner_func
return func(workspaces, *args, **kwargs)
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/mantidqt/plotting/functions.py", line 294, in pcolormesh
fig.canvas.draw()
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/matplotlib/backends/backend_agg.py", line 400, in draw
self.figure.draw(self.renderer)
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/matplotlib/artist.py", line 95, in draw_wrapper
result = draw(artist, renderer, *args, **kwargs)
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/matplotlib/artist.py", line 72, in draw_wrapper
return draw(artist, renderer)
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/matplotlib/figure.py", line 3175, in draw
mimage._draw_list_compositing_images(
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/matplotlib/image.py", line 131, in _draw_list_compositing_images
a.draw(renderer)
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/matplotlib/artist.py", line 72, in draw_wrapper
return draw(artist, renderer)
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/matplotlib/axes/_base.py", line 3064, in draw
mimage._draw_list_compositing_images(
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/matplotlib/image.py", line 131, in _draw_list_compositing_images
a.draw(renderer)
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/matplotlib/artist.py", line 39, in draw_wrapper
return draw(artist, renderer, *args, **kwargs)
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/mantid/plots/resampling_image/samplingimage.py", line 75, in draw
self._resample_image()
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/mantid/plots/resampling_image/samplingimage.py", line 111, in _resample_image
x, y, data = get_matrix_2d_ragged(
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/mantid/plots/datafunctions.py", line 542, in get_matrix_2d_ragged
x_centers = mantid.plots.datafunctions.points_from_boundaries(x_edges)
File "/home/mlc47243/mambaforge/envs/mantid_env/lib/python3.10/site-packages/mantid/plots/datafunctions.py", line 183, in points_from_boundaries
raise ValueError("could not get centers from less than two boundaries")
ValueError: could not get centers from less than two boundaries
A plot entry exists in the "Plot" tab in the bottom left. Should this exist if the plot failed?
It seems that the plot dialog has been created and is then set to be hidden. It will show (as an empty dialog) if you click the eye icon to show it. If you don't check the "Plot" tab, though, then you have no idea that this dialog exists.
Script to file for plots produces a file with multiple of the same imports and some unnecessary imports. You get the following:
# import mantid algorithms, numpy and matplotlib
from mantid.simpleapi import *
import matplotlib.pyplot as plt
import numpy as np
import matplotlib.pyplot as plt
from mantid.plots.utility import MantidAxType
from mantid.api import AnalysisDataService as ADS
If you use the script to clipboard option then you only get these imports:
import matplotlib.pyplot as plt
from mantid.plots.utility import MantidAxType
from mantid.api import AnalysisDataService as ADS
I can reproduce in 6.8, so this is not a regression.
Create a md_4D workspace
md_4D = CreateMDWorkspace(Dimensions=4, Extents=[-1,1,-1,1,-1,1,-10,10], Names="H,K,L,E", Units="U,U,U,V")
FakeMDEventData(InputWorkspace=md_4D, PeakParams='500000,0,0,0,0,3')
Do Show sample logs for md_4D workspace and you get a warning:
Could not open sample logs for workspace 'md_4D'.
ValueError: MDWorkspace::getExperimentInfo(): expInfoIndex is out of range.
Clicking Show Detectors for the WV_96538 dataset gives an error: https://stfc365-my.sharepoint.com/:t:/r/personal/robert_applin_stfc_ac_uk/Documents/Documents/WV_96538.txt?csf=1&web=1&e=TAOVRO
In Instrument::getSamplePos(). No SamplePos has been set.
Error in execution of algorithm CreateDetectorTable:
Matrix workspace has no instrument information
This is because there is no instrument on the workspace. The Show Instrument option on the workspace right click menu is disabled, so would it be better if the Show Detectors option was also disabled in this case?
Load MAR11060 Plot Spectrum 4 Select Fit Change Minimizer to "Simplex" Select Fit->Evaluate Function There is a segmentation fault
Happens on all operating systems. Can reproduce in 6.8, so not a regression.
Script to file for plots produces a file with multiple of the same imports and some unnecessary imports. You get the following:
# import mantid algorithms, numpy and matplotlib from mantid.simpleapi import * import matplotlib.pyplot as plt import numpy as np import matplotlib.pyplot as plt from mantid.plots.utility import MantidAxType from mantid.api import AnalysisDataService as ADS
If you use the script to clipboard option then you only get these imports:
import matplotlib.pyplot as plt from mantid.plots.utility import MantidAxType from mantid.api import AnalysisDataService as ADS
I can reproduce in 6.8, so this is not a regression.
It's a bit strange that one does exlude_headers=True
and the other doesn't. You would expect it to be the same right. Maybe they are expecting you to paste the clipboard script below the default workbench imports, but if you don't need them, why include it in a file?
None of the issues described above is a regression when compared to Mantid 6.10. I will raise separate GitHub issues for each, but do not think any of them need to be fixed urgently for the upcoming release.
Script to file for plots produces a file with multiple of the same imports and some unnecessary imports. You get the following:
# import mantid algorithms, numpy and matplotlib from mantid.simpleapi import * import matplotlib.pyplot as plt import numpy as np import matplotlib.pyplot as plt from mantid.plots.utility import MantidAxType from mantid.api import AnalysisDataService as ADS
If you use the script to clipboard option then you only get these imports:
import matplotlib.pyplot as plt from mantid.plots.utility import MantidAxType from mantid.api import AnalysisDataService as ADS
I can reproduce in 6.8, so this is not a regression.
It's a bit strange that one does
exlude_headers=True
and the other doesn't. You would expect it to be the same right. Maybe they are expecting you to paste the clipboard script below the default workbench imports, but if you don't need them, why include it in a file?
I am not sure if this is a problem. The reasoning behind this might be that some people create a script from a plot and then start to add more code. So the - strictly speaking unnecessary - first 3 lines might then be useful. If this script is not stored in a file but immediately copied into the editor by the user, we won't include these three imports as they are already in the Mantid editor by default.
You have been assigned manual testing. The hope is to catch as many problems with the code before release, so it would be great if you can take some time to give a serious test to your assigned area. Thank you!!
The general guide to manual testing:
Specific Notes:
https://developer.mantidproject.org/Testing/Core/Core.html