tomwer 1.4.3__py3-none-any.whl → 1.4.4__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.
@@ -181,21 +181,8 @@ class _StitcherThread(qt.QThread):
181
181
  },
182
182
  )
183
183
 
184
- if self._cluster_config in (None, {}):
185
- self._runLocally(task)
186
- else:
187
- self._runRemotely(task)
188
-
189
- def _runLocally(self, task):
190
- task.run()
191
-
192
- def _runRemotely(self, task):
193
184
  task.run()
194
- # wait for processing to be finished
195
- for future in task.outputs.future_tomo_obj.futures:
196
- future.result()
197
- # note: there is also a callback to aggregate result once all are finished.
198
- # so at this stage the final "nxtomo" or "volume" might not exists yet
185
+ print("stitching finished")
199
186
 
200
187
 
201
188
  class MainWindow(qt.QDialog):
@@ -26,7 +26,6 @@ from processview.core.superviseprocess import SuperviseProcess
26
26
  from tomwer.core.process.task import Task
27
27
  from tomwer.core.scan.nxtomoscan import NXtomoScan
28
28
  from tomwer.core.scan.scanfactory import ScanFactory
29
- from tomwer.core.futureobject import FutureTomwerObject
30
29
  from tomwer.core.volume.volumefactory import VolumeFactory
31
30
 
32
31
 
@@ -135,32 +134,24 @@ class StitcherTask(
135
134
  stitching_config=config,
136
135
  progress_bars=slurm_job_progress_bars,
137
136
  )
138
- for future in futures.values():
139
- # TODO: do we ned to make sure the processing is not finished yet ?
140
- future.add_done_callback(data_aggregation.onePartFinished)
137
+ # will wait and provide feedback until the stitching is completed.
138
+ data_aggregation.process()
141
139
 
142
140
  if config.stitching_type is StitchingType.Z_PREPROC:
143
141
  output_nx_tomo_file = config.output_file_path
144
142
  output_nx_tomo_entry = config.output_data_path
145
- tomwer_scan = NXtomoScan(
143
+ self.outputs.data = NXtomoScan(
146
144
  scan=output_nx_tomo_file, entry=output_nx_tomo_entry
147
145
  )
148
- self.outputs.future_tomo_obj = FutureTomwerObject(
149
- tomo_obj=tomwer_scan,
150
- futures=tuple(futures.values()),
151
- )
152
- self.outputs.data = None
146
+ self.outputs.future_tomo_obj = None
153
147
  self.outputs.volume = None
154
148
 
155
149
  elif config.stitching_type is StitchingType.Z_POSTPROC:
156
150
  tomwer_volume = VolumeFactory.create_tomo_object_from_identifier(
157
151
  config.output_volume.get_identifier().to_str()
158
152
  )
159
- self.outputs.future_tomo_obj = FutureTomwerObject(
160
- tomo_obj=tomwer_volume,
161
- futures=tuple(futures.values()),
162
- )
163
- self.outputs.volume = None
153
+ self.outputs.future_tomo_obj = None
154
+ self.outputs.volume = tomwer_volume
164
155
  self.outputs.data = None
165
156
 
166
157
 
@@ -171,7 +162,7 @@ class StitchingPostProcAggregation(_StitchingPostProcAggregation):
171
162
 
172
163
  def __init__(self, *args, **kwargs) -> None:
173
164
  super().__init__(*args, **kwargs)
174
- self._n_finished = 0
165
+ print("creates StitchingPostProcAggregation")
175
166
 
176
167
  if isinstance(self.stitching_config, dict):
177
168
  stitching_type = StitchingType.from_value(
@@ -192,10 +183,6 @@ class StitchingPostProcAggregation(_StitchingPostProcAggregation):
192
183
  f"stitching_config is expected to be an instance of {StitchingConfiguration}. {type(self.stitching_config)} provided instead"
193
184
  )
194
185
 
195
- def onePartFinished(self, *args, **kwargs):
196
- self._n_finished += 1
197
- # note: for now we only consider the user of the futures.
198
- # if users want to only run post-processing agregation then they will use the nabu CLI for it.
199
- if self._n_finished == len(self._futures):
200
- _logger.info("All slurm job finished. Will aggregate results")
201
- self.process()
186
+ def process(self):
187
+ super().process()
188
+ _logger.info("Stitching finished.")
@@ -95,6 +95,7 @@ class _NabuPhaseConfig(qt.QWidget, base._NabuStageConfigBase):
95
95
  self._unsharpOpts.setDiscourageUnsharpMask(
96
96
  self.getMethod() is _NabuPhaseMethod.NONE
97
97
  )
98
+ self._unsharpOpts._updateUnsharpMaskWarning()
98
99
  self.sigConfChanged.emit("method")
99
100
 
100
101
  def _signalConfChanged(self, param):
tomwer/version.py CHANGED
@@ -77,7 +77,7 @@ RELEASE_LEVEL_VALUE = {
77
77
 
78
78
  MAJOR = 1
79
79
  MINOR = 4
80
- MICRO = 3
80
+ MICRO = 4
81
81
  RELEV = "final" # <16
82
82
  SERIAL = 0 # <16
83
83
 
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.1
2
2
  Name: tomwer
3
- Version: 1.4.3
3
+ Version: 1.4.4
4
4
  Summary: "tomography workflow tools"
5
5
  Home-page: https://gitlab.esrf.fr/tomotools/tomwer
6
6
  Author: Henri Payno, Pierre Paleo, Pierre-Olivier Autran, Jérôme Lesaint, Alessandro Mirone
@@ -220,7 +220,7 @@ orangecontrib/tomwer/widgets/visualization/tests/__init__.py,sha256=47DEQpj8HBSa
220
220
  tomwer/__init__.py,sha256=GeLSeY4__z-HQZu1y4ptZ5Y1OeXFvG8kuEwWXhkeaMA,360
221
221
  tomwer/__main__.py,sha256=7tCADiS4u7k1PCxFhlRAcYSIOpxQTGUTx8sCEQ-hi1E,8707
222
222
  tomwer/utils.py,sha256=7h7dEgKAEUmQ43jkULvC1B9Adl55nkCty-SEKUKCl4U,7008
223
- tomwer/version.py,sha256=a1loEqEj9NVb3IVtlWL8YHxJkt3I_gA4e_oclG0NANo,4386
223
+ tomwer/version.py,sha256=cQn0hp7H0RGoblTK9Od0_A4QCnVaVE5G-t2RThewbMg,4386
224
224
  tomwer/app/__init__.py,sha256=RYMB2YhbQaoMXC8W-oOyfZ_Y1vmHD7L13YkKeAMuShM,85
225
225
  tomwer/app/axis.py,sha256=OhDgMj_gS-45PnjKBTyOCOkmZ1Iy-Tb6Dj66mzQg0sU,5827
226
226
  tomwer/app/canvas.py,sha256=sM368nniUwbQXLA-oNCg1iNwMMol_ZGTKbiw8WsC4yw,1539
@@ -253,7 +253,7 @@ tomwer/app/canvas_launcher/splash.py,sha256=cpUuZVKwlQbeAWfAqjpjP4q1v1MmkfxU6WWl
253
253
  tomwer/app/canvas_launcher/utils.py,sha256=4zWaao2EW5OcKomAw38YUIUgOLfkUPGdPCqLsfD1NMI,1031
254
254
  tomwer/app/canvas_launcher/widgetsscheme.py,sha256=9Or1KMmSxIs_dJmJGV0Xhjg9HH4m8aPGbtiEuK2i6q0,2744
255
255
  tomwer/app/stitching/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
256
- tomwer/app/stitching/common.py,sha256=-CztPRSwIAHocNIDksBdbRWALsy9G5aRFiG9b78vtlg,15203
256
+ tomwer/app/stitching/common.py,sha256=TCXNnAz2MSJrrogB5iWptktxq-g5ED2FUt_jMnDXpnQ,14723
257
257
  tomwer/core/__init__.py,sha256=ry3BZxaZzsbjymW1wqPcKROzJO9ePkiiqWp1JRVOrS8,72
258
258
  tomwer/core/futureobject.py,sha256=YQE6zROyDFu2PYBI7hxZKpn-K_FqZQ9xGSIyqMErK5U,5114
259
259
  tomwer/core/settings.py,sha256=57qD44LU_3eB50rD7RHdg5nBweiHerzWbXHcBUna6gY,4089
@@ -374,7 +374,7 @@ tomwer/core/process/script/python.py,sha256=NScx6DtRA6m71jciiN6a7QIr3ICWmo3rXJY1
374
374
  tomwer/core/process/script/tests/test_script.py,sha256=1uku23G5_6JEjohI53FZyLpTjkmfsdGrwX__5Mr3DBg,1024
375
375
  tomwer/core/process/stitching/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
376
376
  tomwer/core/process/stitching/metadataholder.py,sha256=QWo04TRsGFg1MdydLvuuK1C2ICRXNwL1oK32JXB1dE8,6530
377
- tomwer/core/process/stitching/nabustitcher.py,sha256=DQTmCqOvcei9S9eu-H9NoVXBcBQf6DRxYOJO2Nn50QY,8129
377
+ tomwer/core/process/stitching/nabustitcher.py,sha256=wJGCpPIcBQXv-g6F6kxchEtcMEiqMGsq-r0Nq36aKmo,7422
378
378
  tomwer/core/process/stitching/tests/test_metadataholder.py,sha256=E9jgvtwdbcF9tgWS3uqHppHf8ff0aCvjROrLAFVZSpQ,631
379
379
  tomwer/core/process/tests/__init__.py,sha256=47DEQpj8HBSa-_TImW-5JCeuQeRkm5NMpJWZG3hSuFU,0
380
380
  tomwer/core/process/tests/test_conditions.py,sha256=FBmBn3fvMW2H27ZLVnyYyS1bnfCb9v86WnWDw46WbMo,2140
@@ -568,7 +568,7 @@ tomwer/gui/reconstruction/nabu/nabuconfig/base.py,sha256=ZsfZORtztbZRIGmcX5bJGlV
568
568
  tomwer/gui/reconstruction/nabu/nabuconfig/ctf.py,sha256=z7mqBt77Y81gO7GO1OsXG3iGxcgSKNYLAjxlG-uC0K8,13142
569
569
  tomwer/gui/reconstruction/nabu/nabuconfig/nabuconfig.py,sha256=rJXFMr_dlTekd0mCbzzg7b7L2QJrLthDHX6JK1zkZTc,9059
570
570
  tomwer/gui/reconstruction/nabu/nabuconfig/output.py,sha256=0SShYqvFj-motxTw20e3I1Z0WiierSqgOsN15qwe-TY,11907
571
- tomwer/gui/reconstruction/nabu/nabuconfig/phase.py,sha256=3SPSokMuE4wvoKTn-aFStln__sjewcpG7H9oJY4x5qs,16239
571
+ tomwer/gui/reconstruction/nabu/nabuconfig/phase.py,sha256=h4F0qtKXOeligVuqKa-pBAvP2ol2EgfSRHjxvsQkvAQ,16293
572
572
  tomwer/gui/reconstruction/nabu/nabuconfig/preprocessing.py,sha256=lmL2UTL7gt20nbDv921SFIAnVoJkumafSCjqTE4zGlY,32608
573
573
  tomwer/gui/reconstruction/nabu/nabuconfig/reconstruction.py,sha256=bGCF7bJBfnh0xh4zcWpqhLrzqHuG32F-Tn4xHVQny3M,41151
574
574
  tomwer/gui/reconstruction/nabu/test/test_cast_volume.py,sha256=kup5JVKNN4QZOXYGco1ZRb_4TWrXAQOtfuQcqTpraA0,2764
@@ -903,9 +903,9 @@ tomwer/tests/orangecontrib/tomwer/widgets/visualization/tests/test_volume_viewer
903
903
  tomwer/tests/test_ewoks/test_conversion.py,sha256=a8cEWbErXiFCAkaapi0jeEoRKYxcFQCoa-Jr_u77_OM,3656
904
904
  tomwer/tests/test_ewoks/test_single_node_execution.py,sha256=YBUHfiAnkciv_kjj7biC5fOs7c7ofNImM_azGMn4LZM,2813
905
905
  tomwer/tests/test_ewoks/test_workflows.py,sha256=Eq80eexf5NVL7SzvwctLOaUeuQ8V3vDiFiHgbJA4Yb8,4871
906
- tomwer-1.4.3.dist-info/LICENSE,sha256=62p1wL0n9WMTu8x2YDv0odYgTqeSvTd9mQ0v6Mq7lzE,1876
907
- tomwer-1.4.3.dist-info/METADATA,sha256=Ld2sbq0AQqYvZRs3bw6o5BjDIzkFYxLOMzOXiANnUiY,13377
908
- tomwer-1.4.3.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
909
- tomwer-1.4.3.dist-info/entry_points.txt,sha256=py3ZUWvGnWGc5c7Yhw_uBTm8Fmew0BDw3aQZnWMBNZI,500
910
- tomwer-1.4.3.dist-info/top_level.txt,sha256=Yz5zKh0FPiImtzHYcPuztG1AO8-6KEpUWgoChGbA0Ys,21
911
- tomwer-1.4.3.dist-info/RECORD,,
906
+ tomwer-1.4.4.dist-info/LICENSE,sha256=62p1wL0n9WMTu8x2YDv0odYgTqeSvTd9mQ0v6Mq7lzE,1876
907
+ tomwer-1.4.4.dist-info/METADATA,sha256=rX-5hSdlbZ--HdznnGl7KCiDSBycJgqfzwxurDQeYFU,13377
908
+ tomwer-1.4.4.dist-info/WHEEL,sha256=PZUExdf71Ui_so67QXpySuHtCi3-J3wvF4ORK6k_S8U,91
909
+ tomwer-1.4.4.dist-info/entry_points.txt,sha256=py3ZUWvGnWGc5c7Yhw_uBTm8Fmew0BDw3aQZnWMBNZI,500
910
+ tomwer-1.4.4.dist-info/top_level.txt,sha256=Yz5zKh0FPiImtzHYcPuztG1AO8-6KEpUWgoChGbA0Ys,21
911
+ tomwer-1.4.4.dist-info/RECORD,,
File without changes