tomwer 1.3.7__py3-none-any.whl → 1.3.8__py3-none-any.whl
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- tomwer/core/process/reconstruction/nabu/utils.py +2 -0
- tomwer/gui/control/datawatcher/datawatcher.py +1 -24
- tomwer/version.py +1 -1
- {tomwer-1.3.7.dist-info → tomwer-1.3.8.dist-info}/METADATA +1 -1
- {tomwer-1.3.7.dist-info → tomwer-1.3.8.dist-info}/RECORD +11 -108
- orangecontrib/tomwer/test/TestAcquisition.py +0 -246
- orangecontrib/tomwer/widgets/cluster/test/test_future_supervisorow.py +0 -87
- orangecontrib/tomwer/widgets/cluster/test/test_slurm_clusterow.py +0 -67
- orangecontrib/tomwer/widgets/control/test/test_advancement.py +0 -51
- orangecontrib/tomwer/widgets/control/test/test_data_validator.py +0 -55
- orangecontrib/tomwer/widgets/control/test/test_datadiscovery.py +0 -131
- orangecontrib/tomwer/widgets/control/test/test_datalist.py +0 -70
- orangecontrib/tomwer/widgets/control/test/test_datalistener.py +0 -137
- orangecontrib/tomwer/widgets/control/test/test_dataselector.py +0 -95
- orangecontrib/tomwer/widgets/control/test/test_datawatcher.py +0 -436
- orangecontrib/tomwer/widgets/control/test/test_emailow.py +0 -29
- orangecontrib/tomwer/widgets/control/test/test_notifier.py +0 -51
- orangecontrib/tomwer/widgets/control/test/test_nxtomo_concatenate_ow.py +0 -64
- orangecontrib/tomwer/widgets/control/test/test_nxtomomill.py +0 -160
- orangecontrib/tomwer/widgets/control/test/test_reduce_dark_flat_selector.py +0 -40
- orangecontrib/tomwer/widgets/control/test/test_singletomoobj.py +0 -40
- orangecontrib/tomwer/widgets/control/test/test_timerow.py +0 -51
- orangecontrib/tomwer/widgets/control/test/test_tomoobj_serie.py +0 -96
- orangecontrib/tomwer/widgets/control/test/test_volume_selector.py +0 -69
- orangecontrib/tomwer/widgets/control/test/test_volumesymlink.py +0 -51
- orangecontrib/tomwer/widgets/debugtools/test/test_dataset_generator.py +0 -57
- orangecontrib/tomwer/widgets/debugtools/test/test_object_inspector.py +0 -62
- orangecontrib/tomwer/widgets/other/test/test_pythonscript.py +0 -31
- orangecontrib/tomwer/widgets/reconstruction/test/test_axis.py +0 -224
- orangecontrib/tomwer/widgets/reconstruction/test/test_cast_volumeow.py +0 -85
- orangecontrib/tomwer/widgets/reconstruction/test/test_dark_refs_widget.py +0 -136
- orangecontrib/tomwer/widgets/reconstruction/test/test_delta_beta_selector.py +0 -15
- orangecontrib/tomwer/widgets/reconstruction/test/test_i_norm.py +0 -226
- orangecontrib/tomwer/widgets/reconstruction/test/test_nabu_helical_prepare_weights_double.py +0 -20
- orangecontrib/tomwer/widgets/reconstruction/test/test_nabu_volume.py +0 -100
- orangecontrib/tomwer/widgets/reconstruction/test/test_nabu_widget.py +0 -107
- orangecontrib/tomwer/widgets/reconstruction/test/test_sa_delta_beta.py +0 -194
- orangecontrib/tomwer/widgets/reconstruction/test/test_saaxis.py +0 -220
- orangecontrib/tomwer/widgets/stitching/test/test_zstitching.py +0 -308
- orangecontrib/tomwer/widgets/test/test_conditions.py +0 -111
- orangecontrib/tomwer/widgets/test/test_darkref.py +0 -251
- orangecontrib/tomwer/widgets/test/test_foldertransfert.py +0 -131
- orangecontrib/tomwer/widgets/visualization/test/test_dataviewerow.py +0 -83
- orangecontrib/tomwer/widgets/visualization/test/test_diffviewerow.py +0 -65
- orangecontrib/tomwer/widgets/visualization/test/test_live_sliceow.py +0 -63
- orangecontrib/tomwer/widgets/visualization/test/test_nxtomo_metadata_viewer.py +0 -29
- orangecontrib/tomwer/widgets/visualization/test/test_radio_stackow.py +0 -56
- orangecontrib/tomwer/widgets/visualization/test/test_sample_movedow.py +0 -72
- orangecontrib/tomwer/widgets/visualization/test/test_sinogram_viewerow.py +0 -56
- orangecontrib/tomwer/widgets/visualization/test/test_slice_stackow.py +0 -57
- orangecontrib/tomwer/widgets/visualization/test/test_volume_viewerow.py +0 -57
- tomwer/core/log/test/test_processlog.py +0 -41
- tomwer/core/process/edit/test/test_darkflatpatch.py +0 -269
- tomwer/core/process/edit/test/test_imagekey_editor.py +0 -125
- tomwer/core/process/icat/test/test_create_screenshots.py +0 -98
- tomwer/core/process/icat/test/test_gallery.py +0 -170
- tomwer/core/process/reconstruction/nabu/test/test_castvolume.py +0 -143
- tomwer/core/process/reconstruction/nabu/test/test_nabu_utils.py +0 -203
- tomwer/core/process/reconstruction/nabu/test/test_nabunormalization.py +0 -222
- tomwer/core/process/script/test/test_script.py +0 -68
- tomwer/core/process/stitching/test/test_metadataholder.py +0 -17
- tomwer/core/process/visualization/test/test_data_viewer.py +0 -39
- tomwer/core/process/visualization/test/test_diff_viewer.py +0 -39
- tomwer/core/process/visualization/test/test_image_stack_viewer.py +0 -41
- tomwer/core/process/visualization/test/test_radio_stack.py +0 -39
- tomwer/core/process/visualization/test/test_sample_moved.py +0 -41
- tomwer/core/process/visualization/test/test_sinogram_viewer.py +0 -39
- tomwer/core/process/visualization/test/test_slice_stack.py +0 -39
- tomwer/core/process/visualization/test/test_volume_viewer.py +0 -39
- tomwer/core/utils/test/test_image.py +0 -30
- tomwer/core/utils/test/test_nxtomo.py +0 -66
- tomwer/core/utils/test/test_scan_utils.py +0 -46
- tomwer/core/utils/test/test_time.py +0 -6
- tomwer/core/volume/test/test_volumes.py +0 -21
- tomwer/gui/control/serie/test/test_creator.py +0 -451
- tomwer/gui/control/serie/test/test_nxtomo_concatenate.py +0 -21
- tomwer/gui/icat/test/test_create_screenshots_gui.py +0 -23
- tomwer/gui/icat/test/test_gallery_gui.py +0 -37
- tomwer/gui/reconstruction/nabu/test/test_check.py +0 -92
- tomwer/gui/reconstruction/nabu/test/test_ctf.py +0 -46
- tomwer/gui/reconstruction/nabu/test/test_helical.py +0 -21
- tomwer/gui/reconstruction/nabu/test/test_nabu_preprocessing.py +0 -81
- tomwer/gui/reconstruction/normalization/test/test_intensity.py +0 -119
- tomwer/gui/stitching/config/tests/test_axisparams.py +0 -25
- tomwer/gui/stitching/tests/test_axis_ordered_list.py +0 -21
- tomwer/gui/stitching/tests/test_normalization.py +0 -27
- tomwer/gui/stitching/tests/test_preview.py +0 -85
- tomwer/gui/stitching/tests/test_stitching_raw.py +0 -110
- tomwer/gui/stitching/tests/test_z_stitching.py +0 -67
- tomwer/gui/stitching/tests/utils.py +0 -79
- tomwer/gui/stitching/z_stitching/tests/test_fine_estimation.py +0 -35
- tomwer/gui/stitching/z_stitching/tests/test_raw_estimation.py +0 -215
- tomwer/gui/stitching/z_stitching/tests/test_stitching_window.py +0 -51
- tomwer/gui/utils/test/test_completer.py +0 -67
- tomwer/gui/utils/test/test_line_selector.py +0 -21
- tomwer/gui/utils/test/test_splashscreen.py +0 -8
- tomwer/gui/utils/test/test_vignettes.py +0 -68
- tomwer/io/utils/test/test_raw_and_processed_data.py +0 -10
- tomwer/io/utils/test/test_utils.py +0 -92
- tomwer/tests/test_ewoks/test_conversion.py +0 -104
- tomwer/tests/test_ewoks/test_single_node_execution.py +0 -112
- tomwer/tests/test_ewoks/test_workflows.py +0 -160
- /tomwer-1.3.7-py3.11-nspkg.pth → /tomwer-1.3.8-py3.11-nspkg.pth +0 -0
- {tomwer-1.3.7.dist-info → tomwer-1.3.8.dist-info}/LICENSE +0 -0
- {tomwer-1.3.7.dist-info → tomwer-1.3.8.dist-info}/WHEEL +0 -0
- {tomwer-1.3.7.dist-info → tomwer-1.3.8.dist-info}/entry_points.txt +0 -0
- {tomwer-1.3.7.dist-info → tomwer-1.3.8.dist-info}/namespace_packages.txt +0 -0
- {tomwer-1.3.7.dist-info → tomwer-1.3.8.dist-info}/top_level.txt +0 -0
@@ -1,131 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
# /*##########################################################################
|
3
|
-
#
|
4
|
-
# Copyright (c) 2016-2017 European Synchrotron Radiation Facility
|
5
|
-
#
|
6
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
-
# of this software and associated documentation files (the "Software"), to deal
|
8
|
-
# in the Software without restriction, including without limitation the rights
|
9
|
-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
-
# copies of the Software, and to permit persons to whom the Software is
|
11
|
-
# furnished to do so, subject to the following conditions:
|
12
|
-
#
|
13
|
-
# The above copyright notice and this permission notice shall be included in
|
14
|
-
# all copies or substantial portions of the Software.
|
15
|
-
#
|
16
|
-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
22
|
-
# THE SOFTWARE.
|
23
|
-
#
|
24
|
-
# ###########################################################################*/
|
25
|
-
|
26
|
-
__authors__ = ["H. Payno"]
|
27
|
-
__license__ = "MIT"
|
28
|
-
__date__ = "24/01/2017"
|
29
|
-
|
30
|
-
|
31
|
-
import gc
|
32
|
-
import logging
|
33
|
-
import os
|
34
|
-
import shutil
|
35
|
-
import tempfile
|
36
|
-
import time
|
37
|
-
from glob import glob
|
38
|
-
|
39
|
-
from silx.gui import qt
|
40
|
-
from silx.gui.utils.testutils import TestCaseQt
|
41
|
-
|
42
|
-
from orangecontrib.tomwer.widgets.control.DataTransfertOW import DataTransfertOW
|
43
|
-
from tomwer.core.scan.scanfactory import ScanFactory
|
44
|
-
from tomwer.core.utils.scanutils import MockEDF
|
45
|
-
|
46
|
-
logging.disable(logging.INFO)
|
47
|
-
|
48
|
-
|
49
|
-
class TestEDFFolderTransfertWidget(TestCaseQt):
|
50
|
-
"""class testing the DataTransfertOW within an EDF acquisition"""
|
51
|
-
|
52
|
-
def setUp(self):
|
53
|
-
TestCaseQt.setUp(self)
|
54
|
-
self.n_file = 10
|
55
|
-
self.sourcedir = tempfile.mkdtemp()
|
56
|
-
os.makedirs(self.sourcedir, exist_ok=True)
|
57
|
-
self.targettedir = tempfile.mkdtemp()
|
58
|
-
os.makedirs(self.targettedir, exist_ok=True)
|
59
|
-
MockEDF.fastMockAcquisition(self.sourcedir, n_radio=self.n_file)
|
60
|
-
self.scan = ScanFactory.create_scan_object(self.sourcedir)
|
61
|
-
|
62
|
-
self.folderTransWidget = DataTransfertOW()
|
63
|
-
self.folderTransWidget.turn_off_print = True
|
64
|
-
self.folderTransWidget.setDestDir(self.targettedir)
|
65
|
-
self.folderTransWidget._copying = False
|
66
|
-
self.folderTransWidget.setForceSync(True)
|
67
|
-
|
68
|
-
def tearDown(self):
|
69
|
-
self.folderTransWidget.settingsHandler.removeCallback(
|
70
|
-
self.folderTransWidget._updateSettingsVals
|
71
|
-
)
|
72
|
-
self.folderTransWidget.setAttribute(qt.Qt.WA_DeleteOnClose)
|
73
|
-
self.folderTransWidget.close()
|
74
|
-
self.folderTransWidget = None
|
75
|
-
|
76
|
-
if os.path.isdir(self.sourcedir):
|
77
|
-
shutil.rmtree(self.sourcedir)
|
78
|
-
if os.path.isdir(self.targettedir):
|
79
|
-
shutil.rmtree(self.targettedir)
|
80
|
-
gc.collect()
|
81
|
-
|
82
|
-
def testMoveFiles(self):
|
83
|
-
"""
|
84
|
-
simple test that files are correctly moved
|
85
|
-
"""
|
86
|
-
self.folderTransWidget._process(self.scan, move=True, noRsync=True)
|
87
|
-
|
88
|
-
outputdir = os.path.join(self.targettedir, os.path.basename(self.sourcedir))
|
89
|
-
timeout = 1
|
90
|
-
while (
|
91
|
-
(os.path.isdir(self.sourcedir))
|
92
|
-
and timeout > 0
|
93
|
-
or self.folderTransWidget.isCopying()
|
94
|
-
):
|
95
|
-
timeout = timeout - 0.1
|
96
|
-
time.sleep(0.1)
|
97
|
-
self.qapp.processEvents()
|
98
|
-
|
99
|
-
self.assertTrue(os.path.isdir(outputdir))
|
100
|
-
self.assertTrue(self.checkDataCopied())
|
101
|
-
|
102
|
-
def testCopyFiles(self):
|
103
|
-
"""
|
104
|
-
Simple test that file are copy and deleted
|
105
|
-
"""
|
106
|
-
self.folderTransWidget._process(self.scan, move=False, noRsync=True)
|
107
|
-
|
108
|
-
timeout = 1
|
109
|
-
outputdir = os.path.join(self.targettedir, os.path.basename(self.sourcedir))
|
110
|
-
while (
|
111
|
-
os.path.isdir(self.sourcedir) and timeout > 0
|
112
|
-
) or self.folderTransWidget.isCopying():
|
113
|
-
timeout = timeout - 0.1
|
114
|
-
time.sleep(0.1)
|
115
|
-
self.qapp.processEvents()
|
116
|
-
|
117
|
-
time.sleep(1)
|
118
|
-
|
119
|
-
self.assertTrue(os.path.isdir(outputdir))
|
120
|
-
self.assertTrue(self.checkDataCopied())
|
121
|
-
|
122
|
-
def checkDataCopied(self):
|
123
|
-
outputdir = os.path.join(self.targettedir, os.path.basename(self.sourcedir))
|
124
|
-
outputFiles = os.listdir(outputdir)
|
125
|
-
inputFile = glob(self.sourcedir)
|
126
|
-
|
127
|
-
return (
|
128
|
-
(len(inputFile) == 0)
|
129
|
-
and (len(outputFiles) == (self.n_file + 3))
|
130
|
-
and (not os.path.isdir(self.sourcedir))
|
131
|
-
)
|
@@ -1,83 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
# /*##########################################################################
|
3
|
-
#
|
4
|
-
# Copyright (c) 2017-2021 European Synchrotron Radiation Facility
|
5
|
-
#
|
6
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
-
# of this software and associated documentation files (the "Software"), to deal
|
8
|
-
# in the Software without restriction, including without limitation the rights
|
9
|
-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
-
# copies of the Software, and to permit persons to whom the Software is
|
11
|
-
# furnished to do so, subject to the following conditions:
|
12
|
-
#
|
13
|
-
# The above copyright notice and this permission notice shall be included in
|
14
|
-
# all copies or substantial portions of the Software.
|
15
|
-
#
|
16
|
-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
22
|
-
# THE SOFTWARE.
|
23
|
-
#
|
24
|
-
# ###########################################################################*/
|
25
|
-
|
26
|
-
__authors__ = ["H. Payno"]
|
27
|
-
__license__ = "MIT"
|
28
|
-
__date__ = "21/06/2021"
|
29
|
-
|
30
|
-
|
31
|
-
import gc
|
32
|
-
import os
|
33
|
-
import shutil
|
34
|
-
import tempfile
|
35
|
-
|
36
|
-
from orangecanvas.scheme.readwrite import literal_dumps
|
37
|
-
from silx.gui import qt
|
38
|
-
from silx.gui.utils.testutils import TestCaseQt
|
39
|
-
|
40
|
-
from orangecontrib.tomwer.widgets.visualization.DataViewerOW import DataViewerOW
|
41
|
-
from tomwer.core.utils.scanutils import MockNXtomo
|
42
|
-
|
43
|
-
|
44
|
-
class TestDataViewerOW(TestCaseQt):
|
45
|
-
def setUp(self):
|
46
|
-
self.tmp_dir = tempfile.mkdtemp()
|
47
|
-
self.scan = MockNXtomo(
|
48
|
-
scan_path=os.path.join(self.tmp_dir, "myscan"),
|
49
|
-
n_proj=20,
|
50
|
-
n_ini_proj=20,
|
51
|
-
dim=10,
|
52
|
-
).scan
|
53
|
-
self.widget = DataViewerOW()
|
54
|
-
|
55
|
-
def tearDown(self):
|
56
|
-
self.widget.setAttribute(qt.Qt.WA_DeleteOnClose)
|
57
|
-
self.widget.close()
|
58
|
-
self.widget = None
|
59
|
-
shutil.rmtree(self.tmp_dir)
|
60
|
-
self.qapp.processEvents()
|
61
|
-
gc.collect()
|
62
|
-
|
63
|
-
def test(self):
|
64
|
-
self.widget.addScan(self.scan)
|
65
|
-
for mode in (
|
66
|
-
"projections-radios",
|
67
|
-
"slices",
|
68
|
-
"raw darks",
|
69
|
-
"raw flats",
|
70
|
-
"reduced darks",
|
71
|
-
"reduced flats",
|
72
|
-
):
|
73
|
-
self.widget.viewer.setDisplayMode(mode)
|
74
|
-
self.qapp.processEvents()
|
75
|
-
|
76
|
-
def test_literal_dumps(self):
|
77
|
-
"""
|
78
|
-
test settings are correcly dump to literals (and load)
|
79
|
-
"""
|
80
|
-
self.widget._updateSettings()
|
81
|
-
config = self.widget._viewer_config
|
82
|
-
literal_dumps(config)
|
83
|
-
self.widget._setSettings(config)
|
@@ -1,65 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
# /*##########################################################################
|
3
|
-
#
|
4
|
-
# Copyright (c) 2017-2021 European Synchrotron Radiation Facility
|
5
|
-
#
|
6
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
-
# of this software and associated documentation files (the "Software"), to deal
|
8
|
-
# in the Software without restriction, including without limitation the rights
|
9
|
-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
-
# copies of the Software, and to permit persons to whom the Software is
|
11
|
-
# furnished to do so, subject to the following conditions:
|
12
|
-
#
|
13
|
-
# The above copyright notice and this permission notice shall be included in
|
14
|
-
# all copies or substantial portions of the Software.
|
15
|
-
#
|
16
|
-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
22
|
-
# THE SOFTWARE.
|
23
|
-
#
|
24
|
-
# ###########################################################################*/
|
25
|
-
|
26
|
-
__authors__ = ["H. Payno"]
|
27
|
-
__license__ = "MIT"
|
28
|
-
__date__ = "21/06/2021"
|
29
|
-
|
30
|
-
|
31
|
-
import gc
|
32
|
-
import os
|
33
|
-
import shutil
|
34
|
-
import tempfile
|
35
|
-
|
36
|
-
from silx.gui import qt
|
37
|
-
from silx.gui.utils.testutils import TestCaseQt
|
38
|
-
|
39
|
-
from orangecontrib.tomwer.widgets.visualization.DiffViewerOW import DiffViewerOW
|
40
|
-
from tomwer.core.utils.scanutils import MockNXtomo
|
41
|
-
|
42
|
-
|
43
|
-
class TestDiffViewerOW(TestCaseQt):
|
44
|
-
def setUp(self):
|
45
|
-
super().setUp()
|
46
|
-
self.tmp_dir = tempfile.mkdtemp()
|
47
|
-
os.makedirs(self.tmp_dir, exist_ok=True)
|
48
|
-
self.scan = MockNXtomo(
|
49
|
-
scan_path=os.path.join(self.tmp_dir, "myscan"),
|
50
|
-
n_proj=20,
|
51
|
-
n_ini_proj=20,
|
52
|
-
dim=10,
|
53
|
-
).scan
|
54
|
-
self.widget = DiffViewerOW()
|
55
|
-
|
56
|
-
def tearDown(self):
|
57
|
-
self.widget.setAttribute(qt.Qt.WA_DeleteOnClose)
|
58
|
-
self.widget.close()
|
59
|
-
self.widget = None
|
60
|
-
self.qapp.processEvents()
|
61
|
-
shutil.rmtree(self.tmp_dir)
|
62
|
-
gc.collect()
|
63
|
-
|
64
|
-
def test(self):
|
65
|
-
self.widget.addScan(self.scan)
|
@@ -1,63 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
# /*##########################################################################
|
3
|
-
#
|
4
|
-
# Copyright (c) 2017-2019 European Synchrotron Radiation Facility
|
5
|
-
#
|
6
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
-
# of this software and associated documentation files (the "Software"), to deal
|
8
|
-
# in the Software without restriction, including without limitation the rights
|
9
|
-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
-
# copies of the Software, and to permit persons to whom the Software is
|
11
|
-
# furnished to do so, subject to the following conditions:
|
12
|
-
#
|
13
|
-
# The above copyright notice and this permission notice shall be included in
|
14
|
-
# all copies or substantial portions of the Software.
|
15
|
-
#
|
16
|
-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
22
|
-
# THE SOFTWARE.
|
23
|
-
#
|
24
|
-
# ###########################################################################*/
|
25
|
-
__authors__ = ["H. Payno"]
|
26
|
-
__license__ = "MIT"
|
27
|
-
__date__ = "10/12/2021"
|
28
|
-
|
29
|
-
|
30
|
-
import gc
|
31
|
-
|
32
|
-
import pytest
|
33
|
-
from silx.gui import qt
|
34
|
-
from silx.gui.utils.testutils import TestCaseQt
|
35
|
-
|
36
|
-
from tomwer.tests.utils import skip_gui_test
|
37
|
-
|
38
|
-
try:
|
39
|
-
from orangecontrib.tomwer.widgets.visualization.LivesliceOW import LiveSliceOW
|
40
|
-
except ImportError:
|
41
|
-
has_live_slice = False
|
42
|
-
else:
|
43
|
-
has_live_slice = True
|
44
|
-
|
45
|
-
|
46
|
-
@pytest.mark.skipif(not has_live_slice, reason="live slice not found")
|
47
|
-
@pytest.mark.skipif(skip_gui_test(), reason="skip gui test")
|
48
|
-
class TestLiveSliceOW(TestCaseQt):
|
49
|
-
"""Test that the axis widget work correctly"""
|
50
|
-
|
51
|
-
def setUp(self):
|
52
|
-
super().setUp()
|
53
|
-
self._window = LiveSliceOW()
|
54
|
-
|
55
|
-
def tearDown(self):
|
56
|
-
self._window.setAttribute(qt.Qt.WA_DeleteOnClose)
|
57
|
-
self._window.close()
|
58
|
-
self._window = None
|
59
|
-
gc.collect()
|
60
|
-
|
61
|
-
def test(self):
|
62
|
-
self._window.show()
|
63
|
-
self.qWaitForWindowExposed(self._window)
|
@@ -1,29 +0,0 @@
|
|
1
|
-
import gc
|
2
|
-
|
3
|
-
import pytest
|
4
|
-
from silx.gui import qt
|
5
|
-
from silx.gui.utils.testutils import TestCaseQt
|
6
|
-
|
7
|
-
from orangecontrib.tomwer.widgets.visualization.NXtomoMetadataViewerOW import (
|
8
|
-
NXtomoMetadataViewerOW,
|
9
|
-
)
|
10
|
-
from tomwer.tests.utils import skip_gui_test
|
11
|
-
|
12
|
-
|
13
|
-
@pytest.mark.skipif(skip_gui_test(), reason="skip gui test")
|
14
|
-
class TestNXtomoEditorOW(TestCaseQt):
|
15
|
-
"""Test that the NXtomoEditorOW widget work correctly. Processing test are done in the core module. gui test are done in the tomwer.gui.edit module"""
|
16
|
-
|
17
|
-
def setUp(self):
|
18
|
-
super().setUp()
|
19
|
-
self._window = NXtomoMetadataViewerOW()
|
20
|
-
|
21
|
-
def tearDown(self):
|
22
|
-
self._window.setAttribute(qt.Qt.WA_DeleteOnClose)
|
23
|
-
self._window.close()
|
24
|
-
self._window = None
|
25
|
-
gc.collect()
|
26
|
-
|
27
|
-
def test(self):
|
28
|
-
self._window.show()
|
29
|
-
self.qWaitForWindowExposed(self._window)
|
@@ -1,56 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
# /*##########################################################################
|
3
|
-
#
|
4
|
-
# Copyright (c) 2017-2019 European Synchrotron Radiation Facility
|
5
|
-
#
|
6
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
-
# of this software and associated documentation files (the "Software"), to deal
|
8
|
-
# in the Software without restriction, including without limitation the rights
|
9
|
-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
-
# copies of the Software, and to permit persons to whom the Software is
|
11
|
-
# furnished to do so, subject to the following conditions:
|
12
|
-
#
|
13
|
-
# The above copyright notice and this permission notice shall be included in
|
14
|
-
# all copies or substantial portions of the Software.
|
15
|
-
#
|
16
|
-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
22
|
-
# THE SOFTWARE.
|
23
|
-
#
|
24
|
-
# ###########################################################################*/
|
25
|
-
__authors__ = ["H. Payno"]
|
26
|
-
__license__ = "MIT"
|
27
|
-
__date__ = "10/12/2021"
|
28
|
-
|
29
|
-
|
30
|
-
import gc
|
31
|
-
|
32
|
-
import pytest
|
33
|
-
from silx.gui import qt
|
34
|
-
from silx.gui.utils.testutils import TestCaseQt
|
35
|
-
|
36
|
-
from orangecontrib.tomwer.widgets.visualization.RadioStackOW import RadioStackOW
|
37
|
-
from tomwer.tests.utils import skip_gui_test
|
38
|
-
|
39
|
-
|
40
|
-
@pytest.mark.skipif(skip_gui_test(), reason="skip gui test")
|
41
|
-
class TestRadioStack(TestCaseQt):
|
42
|
-
"""Test that the axis widget work correctly"""
|
43
|
-
|
44
|
-
def setUp(self):
|
45
|
-
super().setUp()
|
46
|
-
self._window = RadioStackOW()
|
47
|
-
|
48
|
-
def tearDown(self):
|
49
|
-
self._window.setAttribute(qt.Qt.WA_DeleteOnClose)
|
50
|
-
self._window.close()
|
51
|
-
self._window = None
|
52
|
-
gc.collect()
|
53
|
-
|
54
|
-
def test(self):
|
55
|
-
self._window.show()
|
56
|
-
self.qWaitForWindowExposed(self._window)
|
@@ -1,72 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
# /*##########################################################################
|
3
|
-
#
|
4
|
-
# Copyright (c) 2017-2019 European Synchrotron Radiation Facility
|
5
|
-
#
|
6
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
-
# of this software and associated documentation files (the "Software"), to deal
|
8
|
-
# in the Software without restriction, including without limitation the rights
|
9
|
-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
-
# copies of the Software, and to permit persons to whom the Software is
|
11
|
-
# furnished to do so, subject to the following conditions:
|
12
|
-
#
|
13
|
-
# The above copyright notice and this permission notice shall be included in
|
14
|
-
# all copies or substantial portions of the Software.
|
15
|
-
#
|
16
|
-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
22
|
-
# THE SOFTWARE.
|
23
|
-
#
|
24
|
-
# ###########################################################################*/
|
25
|
-
__authors__ = ["H. Payno"]
|
26
|
-
__license__ = "MIT"
|
27
|
-
__date__ = "10/12/2021"
|
28
|
-
|
29
|
-
|
30
|
-
import gc
|
31
|
-
import tempfile
|
32
|
-
|
33
|
-
import pytest
|
34
|
-
from silx.gui import qt
|
35
|
-
from silx.gui.utils.testutils import TestCaseQt
|
36
|
-
|
37
|
-
from orangecontrib.tomwer.widgets.visualization.SampleMovedOW import SampleMovedOW
|
38
|
-
from tomwer.core.utils.scanutils import MockNXtomo
|
39
|
-
from tomwer.tests.utils import skip_gui_test
|
40
|
-
|
41
|
-
|
42
|
-
@pytest.mark.skipif(skip_gui_test(), reason="skip gui test")
|
43
|
-
class TestSampleMoved(TestCaseQt):
|
44
|
-
"""Test that the axis widget work correctly"""
|
45
|
-
|
46
|
-
def setUp(self):
|
47
|
-
super().setUp()
|
48
|
-
self._window = SampleMovedOW()
|
49
|
-
self._tmp_path = tempfile.mkdtemp()
|
50
|
-
|
51
|
-
self._scan = MockNXtomo(
|
52
|
-
scan_path=self._tmp_path,
|
53
|
-
create_ini_dark=True,
|
54
|
-
create_ini_flat=True,
|
55
|
-
create_final_flat=False,
|
56
|
-
n_proj=10,
|
57
|
-
n_ini_proj=10,
|
58
|
-
dim=12,
|
59
|
-
).scan
|
60
|
-
|
61
|
-
def tearDown(self):
|
62
|
-
self._window.setAttribute(qt.Qt.WA_DeleteOnClose)
|
63
|
-
self._window.close()
|
64
|
-
self._window = None
|
65
|
-
gc.collect()
|
66
|
-
|
67
|
-
def test(self):
|
68
|
-
self._window.show()
|
69
|
-
self.qWaitForWindowExposed(self._window)
|
70
|
-
|
71
|
-
self._window.updateScan(self._scan)
|
72
|
-
self.qapp.processEvents()
|
@@ -1,56 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
# /*##########################################################################
|
3
|
-
#
|
4
|
-
# Copyright (c) 2017-2019 European Synchrotron Radiation Facility
|
5
|
-
#
|
6
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
-
# of this software and associated documentation files (the "Software"), to deal
|
8
|
-
# in the Software without restriction, including without limitation the rights
|
9
|
-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
-
# copies of the Software, and to permit persons to whom the Software is
|
11
|
-
# furnished to do so, subject to the following conditions:
|
12
|
-
#
|
13
|
-
# The above copyright notice and this permission notice shall be included in
|
14
|
-
# all copies or substantial portions of the Software.
|
15
|
-
#
|
16
|
-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
22
|
-
# THE SOFTWARE.
|
23
|
-
#
|
24
|
-
# ###########################################################################*/
|
25
|
-
__authors__ = ["H. Payno"]
|
26
|
-
__license__ = "MIT"
|
27
|
-
__date__ = "10/12/2021"
|
28
|
-
|
29
|
-
|
30
|
-
import gc
|
31
|
-
|
32
|
-
import pytest
|
33
|
-
from silx.gui import qt
|
34
|
-
from silx.gui.utils.testutils import TestCaseQt
|
35
|
-
|
36
|
-
from orangecontrib.tomwer.widgets.visualization.SinogramViewerOW import SinogramViewerOW
|
37
|
-
from tomwer.tests.utils import skip_gui_test
|
38
|
-
|
39
|
-
|
40
|
-
@pytest.mark.skipif(skip_gui_test(), reason="skip gui test")
|
41
|
-
class TestSinogramViewerOW(TestCaseQt):
|
42
|
-
"""Test that the axis widget work correctly"""
|
43
|
-
|
44
|
-
def setUp(self):
|
45
|
-
super().setUp()
|
46
|
-
self._window = SinogramViewerOW()
|
47
|
-
|
48
|
-
def tearDown(self):
|
49
|
-
self._window.setAttribute(qt.Qt.WA_DeleteOnClose)
|
50
|
-
self._window.close()
|
51
|
-
self._window = None
|
52
|
-
gc.collect()
|
53
|
-
|
54
|
-
def test(self):
|
55
|
-
self._window.show()
|
56
|
-
self.qWaitForWindowExposed(self._window)
|
@@ -1,57 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
# /*##########################################################################
|
3
|
-
#
|
4
|
-
# Copyright (c) 2017-2019 European Synchrotron Radiation Facility
|
5
|
-
#
|
6
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
-
# of this software and associated documentation files (the "Software"), to deal
|
8
|
-
# in the Software without restriction, including without limitation the rights
|
9
|
-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
-
# copies of the Software, and to permit persons to whom the Software is
|
11
|
-
# furnished to do so, subject to the following conditions:
|
12
|
-
#
|
13
|
-
# The above copyright notice and this permission notice shall be included in
|
14
|
-
# all copies or substantial portions of the Software.
|
15
|
-
#
|
16
|
-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
22
|
-
# THE SOFTWARE.
|
23
|
-
#
|
24
|
-
# ###########################################################################*/
|
25
|
-
__authors__ = ["H. Payno"]
|
26
|
-
__license__ = "MIT"
|
27
|
-
__date__ = "10/12/2021"
|
28
|
-
|
29
|
-
|
30
|
-
import gc
|
31
|
-
|
32
|
-
import pytest
|
33
|
-
from silx.gui import qt
|
34
|
-
from silx.gui.utils.testutils import TestCaseQt
|
35
|
-
|
36
|
-
from orangecontrib.tomwer.widgets.visualization.SliceStackOW import SlicesStackOW
|
37
|
-
from tomwer.tests.utils import skip_gui_test
|
38
|
-
|
39
|
-
|
40
|
-
@pytest.mark.skip("Fail on CI")
|
41
|
-
@pytest.mark.skipif(skip_gui_test(), reason="skip gui test")
|
42
|
-
class TestSliceStackOW(TestCaseQt):
|
43
|
-
"""Test that the axis widget work correctly"""
|
44
|
-
|
45
|
-
def setUp(self):
|
46
|
-
super().setUp()
|
47
|
-
self._window = SlicesStackOW()
|
48
|
-
|
49
|
-
def tearDown(self):
|
50
|
-
self._window.setAttribute(qt.Qt.WA_DeleteOnClose)
|
51
|
-
self._window.close()
|
52
|
-
self._window = None
|
53
|
-
gc.collect()
|
54
|
-
|
55
|
-
def test(self):
|
56
|
-
self._window.show()
|
57
|
-
self.qWaitForWindowExposed(self._window)
|
@@ -1,57 +0,0 @@
|
|
1
|
-
# coding: utf-8
|
2
|
-
# /*##########################################################################
|
3
|
-
#
|
4
|
-
# Copyright (c) 2017-2019 European Synchrotron Radiation Facility
|
5
|
-
#
|
6
|
-
# Permission is hereby granted, free of charge, to any person obtaining a copy
|
7
|
-
# of this software and associated documentation files (the "Software"), to deal
|
8
|
-
# in the Software without restriction, including without limitation the rights
|
9
|
-
# to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
|
10
|
-
# copies of the Software, and to permit persons to whom the Software is
|
11
|
-
# furnished to do so, subject to the following conditions:
|
12
|
-
#
|
13
|
-
# The above copyright notice and this permission notice shall be included in
|
14
|
-
# all copies or substantial portions of the Software.
|
15
|
-
#
|
16
|
-
# THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
|
17
|
-
# IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
|
18
|
-
# FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
|
19
|
-
# AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
|
20
|
-
# LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
|
21
|
-
# OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN
|
22
|
-
# THE SOFTWARE.
|
23
|
-
#
|
24
|
-
# ###########################################################################*/
|
25
|
-
__authors__ = ["H. Payno"]
|
26
|
-
__license__ = "MIT"
|
27
|
-
__date__ = "10/12/2021"
|
28
|
-
|
29
|
-
|
30
|
-
import gc
|
31
|
-
|
32
|
-
import pytest
|
33
|
-
from silx.gui import qt
|
34
|
-
from silx.gui.utils.testutils import TestCaseQt
|
35
|
-
|
36
|
-
from orangecontrib.tomwer.widgets.visualization.VolumeViewerOW import VolumeViewerOW
|
37
|
-
from tomwer.tests.utils import skip_gui_test
|
38
|
-
|
39
|
-
|
40
|
-
@pytest.mark.skipif(skip_gui_test(), reason="skip gui test")
|
41
|
-
class TestVolumeViewerOW(TestCaseQt):
|
42
|
-
"""Test that the axis widget work correctly"""
|
43
|
-
|
44
|
-
def setUp(self):
|
45
|
-
super().setUp()
|
46
|
-
self._window = VolumeViewerOW()
|
47
|
-
|
48
|
-
def tearDown(self):
|
49
|
-
self._window.setAttribute(qt.Qt.WA_DeleteOnClose)
|
50
|
-
self._window.close()
|
51
|
-
del self._window.viewer
|
52
|
-
self._window = None
|
53
|
-
gc.collect()
|
54
|
-
|
55
|
-
def test(self):
|
56
|
-
self._window.show()
|
57
|
-
self.qWaitForWindowExposed(self._window)
|