dcscope 2.22.1__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.
- dcscope/__init__.py +17 -0
- dcscope/__main__.py +44 -0
- dcscope/_version.py +21 -0
- dcscope/extensions.py +250 -0
- dcscope/gui/__init__.py +2 -0
- dcscope/gui/analysis/__init__.py +10 -0
- dcscope/gui/analysis/ana_basins.py +110 -0
- dcscope/gui/analysis/ana_basins.ui +143 -0
- dcscope/gui/analysis/ana_filter.py +341 -0
- dcscope/gui/analysis/ana_filter.ui +364 -0
- dcscope/gui/analysis/ana_log.py +122 -0
- dcscope/gui/analysis/ana_log.ui +100 -0
- dcscope/gui/analysis/ana_meta.py +207 -0
- dcscope/gui/analysis/ana_meta.ui +141 -0
- dcscope/gui/analysis/ana_plot.py +638 -0
- dcscope/gui/analysis/ana_plot.ui +1060 -0
- dcscope/gui/analysis/ana_slot.py +504 -0
- dcscope/gui/analysis/ana_slot.ui +684 -0
- dcscope/gui/analysis/ana_tables.py +227 -0
- dcscope/gui/analysis/ana_tables.ui +195 -0
- dcscope/gui/analysis/ana_view.py +69 -0
- dcscope/gui/analysis/ana_view.ui +269 -0
- dcscope/gui/analysis/dlg_slot_reorder.py +55 -0
- dcscope/gui/analysis/dlg_slot_reorder.ui +138 -0
- dcscope/gui/bulk/__init__.py +2 -0
- dcscope/gui/bulk/bulk_emodulus.py +200 -0
- dcscope/gui/bulk/bulk_emodulus.ui +245 -0
- dcscope/gui/compute/__init__.py +3 -0
- dcscope/gui/compute/comp_lme4.py +115 -0
- dcscope/gui/compute/comp_lme4.ui +194 -0
- dcscope/gui/compute/comp_lme4_dataset.py +51 -0
- dcscope/gui/compute/comp_lme4_dataset.ui +92 -0
- dcscope/gui/compute/comp_lme4_results.py +120 -0
- dcscope/gui/compute/comp_lme4_results.ui +268 -0
- dcscope/gui/compute/comp_stats.py +223 -0
- dcscope/gui/compute/comp_stats.ui +187 -0
- dcscope/gui/dcor/__init__.py +304 -0
- dcscope/gui/dcor/dcor.ui +118 -0
- dcscope/gui/export/__init__.py +3 -0
- dcscope/gui/export/e2data.py +394 -0
- dcscope/gui/export/e2data.ui +367 -0
- dcscope/gui/export/e2filter.py +76 -0
- dcscope/gui/export/e2filter.ui +111 -0
- dcscope/gui/export/e2plot.py +94 -0
- dcscope/gui/export/e2plot.ui +175 -0
- dcscope/gui/main.py +1089 -0
- dcscope/gui/main.ui +579 -0
- dcscope/gui/matrix/__init__.py +4 -0
- dcscope/gui/matrix/block_matrix.py +141 -0
- dcscope/gui/matrix/block_matrix.ui +207 -0
- dcscope/gui/matrix/data_matrix.py +574 -0
- dcscope/gui/matrix/dm_dataset.py +116 -0
- dcscope/gui/matrix/dm_dataset.ui +348 -0
- dcscope/gui/matrix/dm_element.py +111 -0
- dcscope/gui/matrix/dm_element.ui +169 -0
- dcscope/gui/matrix/dm_filter.py +115 -0
- dcscope/gui/matrix/dm_filter.ui +287 -0
- dcscope/gui/matrix/plot_matrix.py +316 -0
- dcscope/gui/matrix/pm_element.py +39 -0
- dcscope/gui/matrix/pm_plot.py +86 -0
- dcscope/gui/matrix/pm_plot.ui +249 -0
- dcscope/gui/pipeline_plot.py +797 -0
- dcscope/gui/pipeline_plot.ui +66 -0
- dcscope/gui/preferences.py +380 -0
- dcscope/gui/preferences.ui +554 -0
- dcscope/gui/quick_view/__init__.py +1 -0
- dcscope/gui/quick_view/qv_main.py +1072 -0
- dcscope/gui/quick_view/qv_main.ui +1297 -0
- dcscope/gui/quick_view/qv_scatter.py +284 -0
- dcscope/gui/quick_view/qv_style.css +10 -0
- dcscope/gui/update.py +90 -0
- dcscope/gui/widgets/__init__.py +15 -0
- dcscope/gui/widgets/bg_thread.py +29 -0
- dcscope/gui/widgets/bulk_list.py +79 -0
- dcscope/gui/widgets/bulk_list.ui +95 -0
- dcscope/gui/widgets/double_spin_box_nan.py +75 -0
- dcscope/gui/widgets/feature_combobox.py +140 -0
- dcscope/gui/widgets/get_path.py +42 -0
- dcscope/gui/widgets/key_value_table_widget.css +12 -0
- dcscope/gui/widgets/key_value_table_widget.py +75 -0
- dcscope/gui/widgets/mdi_subwindow_wo_close.py +12 -0
- dcscope/gui/widgets/qrangeslider.py +262 -0
- dcscope/gui/widgets/rangecontrol.py +308 -0
- dcscope/gui/widgets/rangecontrol.ui +136 -0
- dcscope/gui/widgets/simple_image_view.py +55 -0
- dcscope/gui/widgets/simple_plot_widget.py +113 -0
- dcscope/gui/widgets/so_colorbaritem.py +29 -0
- dcscope/gui/widgets/wait_cursor.py +33 -0
- dcscope/idiom.py +26 -0
- dcscope/img/__init__.py +2 -0
- dcscope/img/icon-theme/breeze/COPYING-ICONS +209 -0
- dcscope/img/icon-theme/breeze/COPYING.LIB +510 -0
- dcscope/img/icon-theme/breeze/README +5 -0
- dcscope/img/icon-theme/breeze/actions/16/application-exit.svg +17 -0
- dcscope/img/icon-theme/breeze/actions/16/code-context.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/dialog-cancel.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/dialog-close.svg +17 -0
- dcscope/img/icon-theme/breeze/actions/16/dialog-messages.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/dialog-ok-apply.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/dialog-ok.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/document-open-folder.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/document-open.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/document-save.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/documentinfo.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/16/draw-watercolor.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/edit-clear-all.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/edit-clear.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/edit-paste.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/globe.svg +16 -0
- dcscope/img/icon-theme/breeze/actions/16/gtk-preferences.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/list-add.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/messagebox_warning.svg +20 -0
- dcscope/img/icon-theme/breeze/actions/16/object-columns.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/object-order-lower.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/object-rows.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/office-chart-line-stacked.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/office-chart-ring.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/office-chart-scatter.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/path-mode-polyline.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/preferences-activities.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/remove.svg +10 -0
- dcscope/img/icon-theme/breeze/actions/16/search.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/show-grid.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/special_paste.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/tools-wizard.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/view-calendar-list.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/view-filter.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/view-list-tree.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/view-statistics.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/16/visibility.svg +21 -0
- dcscope/img/icon-theme/breeze/actions/22/application-exit.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/22/code-context.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/dialog-cancel.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/dialog-close.svg +10 -0
- dcscope/img/icon-theme/breeze/actions/22/dialog-messages.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/dialog-ok-apply.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/dialog-ok.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/document-open-folder.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/document-open.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/document-save.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/documentinfo.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/draw-watercolor.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/edit-clear-all.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/edit-clear.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/edit-paste.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/globe.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/22/gtk-preferences.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/22/list-add.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/messagebox_warning.svg +17 -0
- dcscope/img/icon-theme/breeze/actions/22/object-columns.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/object-order-lower.svg +17 -0
- dcscope/img/icon-theme/breeze/actions/22/object-rows.svg +17 -0
- dcscope/img/icon-theme/breeze/actions/22/office-chart-line-stacked.svg +17 -0
- dcscope/img/icon-theme/breeze/actions/22/office-chart-ring.svg +17 -0
- dcscope/img/icon-theme/breeze/actions/22/office-chart-scatter.svg +17 -0
- dcscope/img/icon-theme/breeze/actions/22/path-mode-polyline.svg +17 -0
- dcscope/img/icon-theme/breeze/actions/22/preferences-activities.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/remove.svg +10 -0
- dcscope/img/icon-theme/breeze/actions/22/special_paste.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/tools-wizard.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/view-calendar-list.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/view-filter.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/view-list-tree.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/view-statistics.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/22/visibility.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/24/application-exit.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/code-context.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/dialog-cancel.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/dialog-close.svg +10 -0
- dcscope/img/icon-theme/breeze/actions/24/dialog-messages.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/dialog-ok-apply.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/dialog-ok.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/24/document-open-folder.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/document-open.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/document-save.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/documentinfo.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/24/draw-watercolor.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/edit-clear-all.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/24/edit-clear.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/edit-paste.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/globe.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/24/gtk-preferences.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/24/list-add.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/messagebox_warning.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/24/object-columns.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/object-order-lower.svg +15 -0
- dcscope/img/icon-theme/breeze/actions/24/object-rows.svg +15 -0
- dcscope/img/icon-theme/breeze/actions/24/office-chart-line-stacked.svg +15 -0
- dcscope/img/icon-theme/breeze/actions/24/office-chart-ring.svg +15 -0
- dcscope/img/icon-theme/breeze/actions/24/office-chart-scatter.svg +15 -0
- dcscope/img/icon-theme/breeze/actions/24/path-mode-polyline.svg +15 -0
- dcscope/img/icon-theme/breeze/actions/24/preferences-activities.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/24/remove.svg +10 -0
- dcscope/img/icon-theme/breeze/actions/24/special_paste.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/tools-wizard.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/view-calendar-list.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/view-filter.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/view-list-tree.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/view-statistics.svg +12 -0
- dcscope/img/icon-theme/breeze/actions/24/visibility.svg +14 -0
- dcscope/img/icon-theme/breeze/actions/32/application-exit.svg +8 -0
- dcscope/img/icon-theme/breeze/actions/32/dialog-cancel.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/32/dialog-messages.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/32/dialog-ok-apply.svg +1 -0
- dcscope/img/icon-theme/breeze/actions/32/dialog-ok.svg +1 -0
- dcscope/img/icon-theme/breeze/actions/32/document-open-folder.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/32/document-open.svg +13 -0
- dcscope/img/icon-theme/breeze/actions/32/document-save.svg +18 -0
- dcscope/img/icon-theme/breeze/actions/32/gtk-preferences.svg +17 -0
- dcscope/img/icon-theme/breeze/actions/32/object-order-lower.svg +18 -0
- dcscope/img/icon-theme/breeze/actions/32/view-filter.svg +18 -0
- dcscope/img/icon-theme/breeze/actions/32/view-list-tree.svg +18 -0
- dcscope/img/icon-theme/breeze/places/16/folder-cloud.svg +13 -0
- dcscope/img/icon-theme/breeze/places/16/folder.svg +13 -0
- dcscope/img/icon-theme/breeze/places/22/folder-cloud.svg +13 -0
- dcscope/img/icon-theme/breeze/places/22/folder.svg +13 -0
- dcscope/img/icon-theme/breeze/places/24/folder-cloud.svg +12 -0
- dcscope/img/icon-theme/breeze/places/24/folder.svg +12 -0
- dcscope/img/icon-theme/breeze/places/32/folder-cloud.svg +35 -0
- dcscope/img/icon-theme/breeze/places/32/folder.svg +30 -0
- dcscope/img/icon-theme/breeze/places/64/folder-cloud.svg +35 -0
- dcscope/img/icon-theme/breeze/places/64/folder.svg +30 -0
- dcscope/img/icon-theme/breeze/status/16/dialog-error.svg +9 -0
- dcscope/img/icon-theme/breeze/status/16/dialog-information.svg +9 -0
- dcscope/img/icon-theme/breeze/status/16/dialog-question.svg +7 -0
- dcscope/img/icon-theme/breeze/status/16/dialog-warning.svg +9 -0
- dcscope/img/icon-theme/breeze/status/22/dialog-error.svg +9 -0
- dcscope/img/icon-theme/breeze/status/22/dialog-information.svg +9 -0
- dcscope/img/icon-theme/breeze/status/22/dialog-question.svg +7 -0
- dcscope/img/icon-theme/breeze/status/22/dialog-warning.svg +9 -0
- dcscope/img/icon-theme/breeze/status/24/dialog-error.svg +13 -0
- dcscope/img/icon-theme/breeze/status/24/dialog-information.svg +13 -0
- dcscope/img/icon-theme/breeze/status/24/dialog-question.svg +9 -0
- dcscope/img/icon-theme/breeze/status/24/dialog-warning.svg +1 -0
- dcscope/img/icon-theme/breeze/status/64/dialog-error.svg +25 -0
- dcscope/img/icon-theme/breeze/status/64/dialog-information.svg +25 -0
- dcscope/img/icon-theme/breeze/status/64/dialog-question.svg +25 -0
- dcscope/img/icon-theme/breeze/status/64/dialog-warning.svg +25 -0
- dcscope/img/icon-theme/collect_icons.py +124 -0
- dcscope/img/icon-theme/dcscope/dcor.png +0 -0
- dcscope/img/icon-theme/dcscope/edit-copy-anew.svg +13 -0
- dcscope/img/icon-theme/dcscope/emodulus.svg +69 -0
- dcscope/img/icon-theme/dcscope/filter_ray.svg +54 -0
- dcscope/img/icon-theme/dcscope/region_channel.svg +86 -0
- dcscope/img/icon-theme/dcscope/region_reservoir.svg +89 -0
- dcscope/img/icon-theme/dcscope/rlang.svg +108 -0
- dcscope/img/icon-theme/dcscope/statistical_significance.svg +106 -0
- dcscope/img/icon-theme/index.theme +81 -0
- dcscope/img/icon.png +0 -0
- dcscope/img/icon.svg +73 -0
- dcscope/img/splash.png +0 -0
- dcscope/meta_tool.py +143 -0
- dcscope/pipeline/__init__.py +5 -0
- dcscope/pipeline/core.py +632 -0
- dcscope/pipeline/dataslot.py +270 -0
- dcscope/pipeline/filter.py +161 -0
- dcscope/pipeline/filter_ray.py +170 -0
- dcscope/pipeline/plot.py +187 -0
- dcscope/plot_cache.py +79 -0
- dcscope/session.py +379 -0
- dcscope/util.py +34 -0
- dcscope-2.22.1.dist-info/METADATA +95 -0
- dcscope-2.22.1.dist-info/RECORD +267 -0
- dcscope-2.22.1.dist-info/WHEEL +5 -0
- dcscope-2.22.1.dist-info/entry_points.txt +2 -0
- dcscope-2.22.1.dist-info/licenses/LICENSE +621 -0
- dcscope-2.22.1.dist-info/top_level.txt +1 -0
|
@@ -0,0 +1,141 @@
|
|
|
1
|
+
import copy
|
|
2
|
+
import importlib.resources
|
|
3
|
+
|
|
4
|
+
from PyQt6 import uic, QtCore, QtWidgets
|
|
5
|
+
|
|
6
|
+
|
|
7
|
+
class BlockMatrix(QtWidgets.QWidget):
|
|
8
|
+
pipeline_changed = QtCore.pyqtSignal(dict)
|
|
9
|
+
quickviewed = QtCore.pyqtSignal(int, int)
|
|
10
|
+
|
|
11
|
+
filter_modify_clicked = QtCore.pyqtSignal(str)
|
|
12
|
+
plot_modify_clicked = QtCore.pyqtSignal(str)
|
|
13
|
+
slot_modify_clicked = QtCore.pyqtSignal(str)
|
|
14
|
+
|
|
15
|
+
def __init__(self, *args, **kwargs):
|
|
16
|
+
"""Helper class that wraps DataMatrix and PlotMatrix"""
|
|
17
|
+
super(BlockMatrix, self).__init__(*args, **kwargs)
|
|
18
|
+
ref = importlib.resources.files(
|
|
19
|
+
"dcscope.gui.matrix") / "block_matrix.ui"
|
|
20
|
+
with importlib.resources.as_file(ref) as path_ui:
|
|
21
|
+
uic.loadUi(path_ui, self)
|
|
22
|
+
|
|
23
|
+
self._old_state = {}
|
|
24
|
+
# Signals
|
|
25
|
+
# DataMatrix
|
|
26
|
+
self.data_matrix.matrix_changed.connect(self.on_matrix_changed)
|
|
27
|
+
self.data_matrix.filter_modify_clicked.connect(
|
|
28
|
+
self.filter_modify_clicked)
|
|
29
|
+
self.data_matrix.slot_modify_clicked.connect(self.slot_modify_clicked)
|
|
30
|
+
self.data_matrix.quickviewed.connect(self.quickviewed)
|
|
31
|
+
# PlotMatrix
|
|
32
|
+
self.plot_matrix.matrix_changed.connect(self.on_matrix_changed)
|
|
33
|
+
self.plot_matrix.plot_modify_clicked.connect(self.plot_modify_clicked)
|
|
34
|
+
|
|
35
|
+
def read_pipeline_state(self):
|
|
36
|
+
state = self.data_matrix.read_pipeline_state()
|
|
37
|
+
statep = self.plot_matrix.read_pipeline_state()
|
|
38
|
+
state["plots"] = statep["plots"]
|
|
39
|
+
for ss in statep["elements"]:
|
|
40
|
+
for plot in statep["elements"][ss]:
|
|
41
|
+
state["elements"][ss][plot] = statep["elements"][ss][plot]
|
|
42
|
+
return state
|
|
43
|
+
|
|
44
|
+
def write_pipeline_state(self, state):
|
|
45
|
+
# DataMatrix
|
|
46
|
+
stated = copy.deepcopy(state)
|
|
47
|
+
stated.pop("plots")
|
|
48
|
+
for slot_state in state["slots"]:
|
|
49
|
+
slot_id = slot_state["identifier"]
|
|
50
|
+
for plot_state in state["plots"]:
|
|
51
|
+
plot_id = plot_state["identifier"]
|
|
52
|
+
stated["elements"][slot_id].pop(plot_id)
|
|
53
|
+
self.data_matrix.write_pipeline_state(stated)
|
|
54
|
+
# PlotMatrix
|
|
55
|
+
statep = copy.deepcopy(state)
|
|
56
|
+
statep.pop("filters")
|
|
57
|
+
statep.pop("filters used")
|
|
58
|
+
statep.pop("slots used")
|
|
59
|
+
for slot_state in state["slots"]:
|
|
60
|
+
slot_id = slot_state["identifier"]
|
|
61
|
+
for filt_state in state["filters"]:
|
|
62
|
+
filt_id = filt_state["identifier"]
|
|
63
|
+
statep["elements"][slot_id].pop(filt_id)
|
|
64
|
+
self.plot_matrix.write_pipeline_state(statep)
|
|
65
|
+
|
|
66
|
+
def add_dataset(self, *args, **kwargs):
|
|
67
|
+
self.data_matrix.add_dataset(*args, **kwargs)
|
|
68
|
+
|
|
69
|
+
def add_filter(self, *args, **kwargs):
|
|
70
|
+
self.data_matrix.add_filter(*args, **kwargs)
|
|
71
|
+
|
|
72
|
+
def add_plot(self, *args, **kwargs):
|
|
73
|
+
self.plot_matrix.add_plot(*args, **kwargs)
|
|
74
|
+
|
|
75
|
+
def adopt_pipeline(self, pipeline_state):
|
|
76
|
+
self.write_pipeline_state(pipeline_state)
|
|
77
|
+
|
|
78
|
+
def enable_quickview(self, view):
|
|
79
|
+
self.data_matrix.enable_quickview(view)
|
|
80
|
+
|
|
81
|
+
def get_quickview_indices(self):
|
|
82
|
+
return self.data_matrix.get_quickview_indices()
|
|
83
|
+
|
|
84
|
+
def get_widget(self, slot_id=None, filt_plot_id=None):
|
|
85
|
+
"""Convenience function for testing"""
|
|
86
|
+
if slot_id is None and filt_plot_id is not None:
|
|
87
|
+
# get a filter or a plot
|
|
88
|
+
w = self.data_matrix.filter_widgets + self.plot_matrix.plot_widgets
|
|
89
|
+
for wi in w:
|
|
90
|
+
if wi.identifier == filt_plot_id:
|
|
91
|
+
break
|
|
92
|
+
else:
|
|
93
|
+
raise KeyError(
|
|
94
|
+
"Widget identifier '{}' not found!".format(filt_plot_id))
|
|
95
|
+
return wi
|
|
96
|
+
elif slot_id is not None and filt_plot_id is None:
|
|
97
|
+
# get a slot
|
|
98
|
+
for wi in self.data_matrix.dataset_widgets:
|
|
99
|
+
if wi.identifier == slot_id:
|
|
100
|
+
break
|
|
101
|
+
else:
|
|
102
|
+
raise KeyError(
|
|
103
|
+
"Widget identifier '{}' not found!".format(filt_plot_id))
|
|
104
|
+
return wi
|
|
105
|
+
elif slot_id is not None and filt_plot_id is not None:
|
|
106
|
+
# get a matrix element
|
|
107
|
+
wd = self.data_matrix.element_widget_dict
|
|
108
|
+
wp = self.plot_matrix.element_widget_dict
|
|
109
|
+
fpd = wd[slot_id]
|
|
110
|
+
fpp = wp[slot_id]
|
|
111
|
+
if filt_plot_id in fpp:
|
|
112
|
+
wi = fpp[filt_plot_id]
|
|
113
|
+
elif filt_plot_id in fpd:
|
|
114
|
+
wi = fpd[filt_plot_id]
|
|
115
|
+
else:
|
|
116
|
+
raise KeyError(
|
|
117
|
+
"Widget identifier '{}' not found!".format(filt_plot_id))
|
|
118
|
+
return wi
|
|
119
|
+
else:
|
|
120
|
+
raise ValueError(
|
|
121
|
+
"At least one of `slot_id`, `filt_plot_id` must be specified!")
|
|
122
|
+
|
|
123
|
+
def invalidate_elements(self, invalid_dm, invalid_pm):
|
|
124
|
+
for slot_id, filt_id in invalid_dm:
|
|
125
|
+
em = self.data_matrix.get_matrix_element(slot_id, filt_id)
|
|
126
|
+
em.active = False
|
|
127
|
+
em.invalid = True
|
|
128
|
+
em.update_content()
|
|
129
|
+
for slot_id, plot_id in invalid_pm:
|
|
130
|
+
em = self.plot_matrix.get_matrix_element(slot_id, plot_id)
|
|
131
|
+
em.active = False
|
|
132
|
+
em.invalid = True
|
|
133
|
+
em.update_content()
|
|
134
|
+
|
|
135
|
+
def on_matrix_changed(self):
|
|
136
|
+
state = self.read_pipeline_state()
|
|
137
|
+
self.pipeline_changed.emit(state)
|
|
138
|
+
|
|
139
|
+
def update(self, *args, **kwargs):
|
|
140
|
+
self.scrollArea_block.update()
|
|
141
|
+
super(BlockMatrix, self).update(*args, **kwargs)
|
|
@@ -0,0 +1,207 @@
|
|
|
1
|
+
<?xml version="1.0" encoding="UTF-8"?>
|
|
2
|
+
<ui version="4.0">
|
|
3
|
+
<class>Form</class>
|
|
4
|
+
<widget class="QWidget" name="Form">
|
|
5
|
+
<property name="geometry">
|
|
6
|
+
<rect>
|
|
7
|
+
<x>0</x>
|
|
8
|
+
<y>0</y>
|
|
9
|
+
<width>310</width>
|
|
10
|
+
<height>464</height>
|
|
11
|
+
</rect>
|
|
12
|
+
</property>
|
|
13
|
+
<property name="font">
|
|
14
|
+
<font>
|
|
15
|
+
<pointsize>9</pointsize>
|
|
16
|
+
</font>
|
|
17
|
+
</property>
|
|
18
|
+
<property name="windowTitle">
|
|
19
|
+
<string>Form</string>
|
|
20
|
+
</property>
|
|
21
|
+
<layout class="QVBoxLayout" name="verticalLayout">
|
|
22
|
+
<property name="topMargin">
|
|
23
|
+
<number>0</number>
|
|
24
|
+
</property>
|
|
25
|
+
<property name="rightMargin">
|
|
26
|
+
<number>0</number>
|
|
27
|
+
</property>
|
|
28
|
+
<property name="bottomMargin">
|
|
29
|
+
<number>0</number>
|
|
30
|
+
</property>
|
|
31
|
+
<item>
|
|
32
|
+
<widget class="QScrollArea" name="scrollArea_block">
|
|
33
|
+
<property name="sizePolicy">
|
|
34
|
+
<sizepolicy hsizetype="Preferred" vsizetype="Preferred">
|
|
35
|
+
<horstretch>0</horstretch>
|
|
36
|
+
<verstretch>0</verstretch>
|
|
37
|
+
</sizepolicy>
|
|
38
|
+
</property>
|
|
39
|
+
<property name="minimumSize">
|
|
40
|
+
<size>
|
|
41
|
+
<width>300</width>
|
|
42
|
+
<height>0</height>
|
|
43
|
+
</size>
|
|
44
|
+
</property>
|
|
45
|
+
<property name="lineWidth">
|
|
46
|
+
<number>1</number>
|
|
47
|
+
</property>
|
|
48
|
+
<property name="verticalScrollBarPolicy">
|
|
49
|
+
<enum>Qt::ScrollBarAsNeeded</enum>
|
|
50
|
+
</property>
|
|
51
|
+
<property name="horizontalScrollBarPolicy">
|
|
52
|
+
<enum>Qt::ScrollBarAsNeeded</enum>
|
|
53
|
+
</property>
|
|
54
|
+
<property name="sizeAdjustPolicy">
|
|
55
|
+
<enum>QAbstractScrollArea::AdjustToContents</enum>
|
|
56
|
+
</property>
|
|
57
|
+
<property name="widgetResizable">
|
|
58
|
+
<bool>true</bool>
|
|
59
|
+
</property>
|
|
60
|
+
<property name="alignment">
|
|
61
|
+
<set>Qt::AlignLeading|Qt::AlignLeft|Qt::AlignTop</set>
|
|
62
|
+
</property>
|
|
63
|
+
<widget class="QWidget" name="scrollAreaWidgetContents">
|
|
64
|
+
<property name="geometry">
|
|
65
|
+
<rect>
|
|
66
|
+
<x>0</x>
|
|
67
|
+
<y>0</y>
|
|
68
|
+
<width>299</width>
|
|
69
|
+
<height>462</height>
|
|
70
|
+
</rect>
|
|
71
|
+
</property>
|
|
72
|
+
<layout class="QGridLayout" name="gridLayout_3">
|
|
73
|
+
<property name="spacing">
|
|
74
|
+
<number>2</number>
|
|
75
|
+
</property>
|
|
76
|
+
<item row="0" column="2" alignment="Qt::AlignLeft|Qt::AlignTop">
|
|
77
|
+
<widget class="QToolButton" name="toolButton_new_filter">
|
|
78
|
+
<property name="toolTip">
|
|
79
|
+
<string>Add a new filter</string>
|
|
80
|
+
</property>
|
|
81
|
+
<property name="text">
|
|
82
|
+
<string>+</string>
|
|
83
|
+
</property>
|
|
84
|
+
<property name="icon">
|
|
85
|
+
<iconset theme="view-filter">
|
|
86
|
+
<normaloff>.</normaloff>.</iconset>
|
|
87
|
+
</property>
|
|
88
|
+
</widget>
|
|
89
|
+
</item>
|
|
90
|
+
<item row="0" column="3">
|
|
91
|
+
<widget class="PlotMatrix" name="plot_matrix" native="true">
|
|
92
|
+
<property name="sizePolicy">
|
|
93
|
+
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
|
|
94
|
+
<horstretch>0</horstretch>
|
|
95
|
+
<verstretch>0</verstretch>
|
|
96
|
+
</sizepolicy>
|
|
97
|
+
</property>
|
|
98
|
+
<property name="minimumSize">
|
|
99
|
+
<size>
|
|
100
|
+
<width>91</width>
|
|
101
|
+
<height>67</height>
|
|
102
|
+
</size>
|
|
103
|
+
</property>
|
|
104
|
+
<property name="maximumSize">
|
|
105
|
+
<size>
|
|
106
|
+
<width>95</width>
|
|
107
|
+
<height>156</height>
|
|
108
|
+
</size>
|
|
109
|
+
</property>
|
|
110
|
+
</widget>
|
|
111
|
+
</item>
|
|
112
|
+
<item row="0" column="4" alignment="Qt::AlignLeft|Qt::AlignTop">
|
|
113
|
+
<widget class="QToolButton" name="toolButton_new_plot">
|
|
114
|
+
<property name="toolTip">
|
|
115
|
+
<string>Add a new plot</string>
|
|
116
|
+
</property>
|
|
117
|
+
<property name="text">
|
|
118
|
+
<string>+</string>
|
|
119
|
+
</property>
|
|
120
|
+
<property name="icon">
|
|
121
|
+
<iconset theme="draw-watercolor">
|
|
122
|
+
<normaloff>.</normaloff>.</iconset>
|
|
123
|
+
</property>
|
|
124
|
+
</widget>
|
|
125
|
+
</item>
|
|
126
|
+
<item row="0" column="5">
|
|
127
|
+
<spacer name="horizontalSpacer_2">
|
|
128
|
+
<property name="orientation">
|
|
129
|
+
<enum>Qt::Horizontal</enum>
|
|
130
|
+
</property>
|
|
131
|
+
<property name="sizeHint" stdset="0">
|
|
132
|
+
<size>
|
|
133
|
+
<width>0</width>
|
|
134
|
+
<height>20</height>
|
|
135
|
+
</size>
|
|
136
|
+
</property>
|
|
137
|
+
</spacer>
|
|
138
|
+
</item>
|
|
139
|
+
<item row="0" column="0" rowspan="2" colspan="2">
|
|
140
|
+
<widget class="DataMatrix" name="data_matrix" native="true">
|
|
141
|
+
<property name="sizePolicy">
|
|
142
|
+
<sizepolicy hsizetype="Expanding" vsizetype="Expanding">
|
|
143
|
+
<horstretch>0</horstretch>
|
|
144
|
+
<verstretch>0</verstretch>
|
|
145
|
+
</sizepolicy>
|
|
146
|
+
</property>
|
|
147
|
+
<property name="minimumSize">
|
|
148
|
+
<size>
|
|
149
|
+
<width>67</width>
|
|
150
|
+
<height>99</height>
|
|
151
|
+
</size>
|
|
152
|
+
</property>
|
|
153
|
+
</widget>
|
|
154
|
+
</item>
|
|
155
|
+
<item row="3" column="1">
|
|
156
|
+
<spacer name="verticalSpacer">
|
|
157
|
+
<property name="orientation">
|
|
158
|
+
<enum>Qt::Vertical</enum>
|
|
159
|
+
</property>
|
|
160
|
+
<property name="sizeHint" stdset="0">
|
|
161
|
+
<size>
|
|
162
|
+
<width>20</width>
|
|
163
|
+
<height>0</height>
|
|
164
|
+
</size>
|
|
165
|
+
</property>
|
|
166
|
+
</spacer>
|
|
167
|
+
</item>
|
|
168
|
+
<item row="2" column="0">
|
|
169
|
+
<widget class="QToolButton" name="toolButton_load_dataset">
|
|
170
|
+
<property name="toolTip">
|
|
171
|
+
<string>Import a dataset</string>
|
|
172
|
+
</property>
|
|
173
|
+
<property name="text">
|
|
174
|
+
<string>+</string>
|
|
175
|
+
</property>
|
|
176
|
+
<property name="icon">
|
|
177
|
+
<iconset theme="office-chart-ring">
|
|
178
|
+
<normaloff>.</normaloff>.</iconset>
|
|
179
|
+
</property>
|
|
180
|
+
<property name="autoRaise">
|
|
181
|
+
<bool>false</bool>
|
|
182
|
+
</property>
|
|
183
|
+
</widget>
|
|
184
|
+
</item>
|
|
185
|
+
</layout>
|
|
186
|
+
</widget>
|
|
187
|
+
</widget>
|
|
188
|
+
</item>
|
|
189
|
+
</layout>
|
|
190
|
+
</widget>
|
|
191
|
+
<customwidgets>
|
|
192
|
+
<customwidget>
|
|
193
|
+
<class>DataMatrix</class>
|
|
194
|
+
<extends>QWidget</extends>
|
|
195
|
+
<header>dcscope.gui.matrix.data_matrix</header>
|
|
196
|
+
<container>1</container>
|
|
197
|
+
</customwidget>
|
|
198
|
+
<customwidget>
|
|
199
|
+
<class>PlotMatrix</class>
|
|
200
|
+
<extends>QWidget</extends>
|
|
201
|
+
<header>dcscope.gui.matrix.plot_matrix</header>
|
|
202
|
+
<container>1</container>
|
|
203
|
+
</customwidget>
|
|
204
|
+
</customwidgets>
|
|
205
|
+
<resources/>
|
|
206
|
+
<connections/>
|
|
207
|
+
</ui>
|