From e29d44f3187df2fa09bf16a02d72bdeb5ed83975 Mon Sep 17 00:00:00 2001 From: mschwoerer <82171591+mschwoer@users.noreply.github.com> Date: Thu, 14 Nov 2024 10:10:39 +0100 Subject: [PATCH] add some comments --- alphadia/workflow/manager.py | 1 + alphadia/workflow/managers/raw_file_manager.py | 6 +++--- 2 files changed, 4 insertions(+), 3 deletions(-) diff --git a/alphadia/workflow/manager.py b/alphadia/workflow/manager.py index bc1d91e6..ea70d2f2 100644 --- a/alphadia/workflow/manager.py +++ b/alphadia/workflow/manager.py @@ -55,6 +55,7 @@ def __init__( self.reporter = reporting.LogBackend() if reporter is None else reporter if load_from_file: + # Note: be careful not to overwrite loaded values by initializing them in child classes after calling super().__init__() self.load() @property diff --git a/alphadia/workflow/managers/raw_file_manager.py b/alphadia/workflow/managers/raw_file_manager.py index 18d9f24f..0a4f369b 100644 --- a/alphadia/workflow/managers/raw_file_manager.py +++ b/alphadia/workflow/managers/raw_file_manager.py @@ -20,8 +20,8 @@ def __init__( load_from_file: bool = False, **kwargs, ): - """Contains and updates timing information for the portions of the workflow.""" - self.stats = {} # needs to be before super().__init__ to avoid overwriting when loading + """Handles raw file loading and contains information on the raw file.""" + self.stats = {} # needs to be before super().__init__ to avoid overwriting loaded values super().__init__(path=path, load_from_file=load_from_file, **kwargs) self.reporter.log_string(f"Initializing {self.__class__.__name__}") @@ -50,7 +50,7 @@ def get_dia_data_object( is_wsl = self._config["general"]["wsl"] if is_wsl: - # copy file to /tmp # TODO why is that? + # copy file to /tmp # TODO check if WSL support can be dropped import shutil tmp_path = "/tmp"