From d7fe47d408f12a327f4b8a60517dcccf9ac2044e Mon Sep 17 00:00:00 2001 From: "pre-commit-ci[bot]" <66853113+pre-commit-ci[bot]@users.noreply.github.com> Date: Mon, 11 Mar 2024 22:29:03 +0100 Subject: [PATCH] [pre-commit.ci] pre-commit autoupdate (#74) Co-authored-by: pre-commit-ci[bot] <66853113+pre-commit-ci[bot]@users.noreply.github.com> --- .pre-commit-config.yaml | 4 ++-- mne_pipeline_hd/functions/operations.py | 4 +--- mne_pipeline_hd/gui/function_widgets.py | 18 +++++++++--------- mne_pipeline_hd/gui/loading_widgets.py | 12 ++++++------ 4 files changed, 18 insertions(+), 20 deletions(-) diff --git a/.pre-commit-config.yaml b/.pre-commit-config.yaml index 8f931a6..03c2ee2 100644 --- a/.pre-commit-config.yaml +++ b/.pre-commit-config.yaml @@ -12,13 +12,13 @@ repos: # Black - repo: https://github.com/psf/black - rev: 23.11.0 + rev: 24.2.0 hooks: - id: black # Ruff - repo: https://github.com/astral-sh/ruff-pre-commit - rev: v0.1.7 + rev: v0.2.2 hooks: - id: ruff args: [--fix, --exit-non-zero-on-fix] diff --git a/mne_pipeline_hd/functions/operations.py b/mne_pipeline_hd/functions/operations.py index ce7ae41..d87f376 100644 --- a/mne_pipeline_hd/functions/operations.py +++ b/mne_pipeline_hd/functions/operations.py @@ -447,9 +447,7 @@ def find_6ch_binary_events(meeg, min_duration, shortest_event, adjust_timeline_b and q not in events[:, 0] + 1 and q not in events[:, 0] - 1 ): - events = np.append( - events, [[q, 0, int(2**a + 2**b + 2**c)]], axis=0 - ) + events = np.append(events, [[q, 0, int(2**a + 2**b + 2**c)]], axis=0) for a, b in combinations(range(6), 2): equals = np.intersect1d(evs_tol[a], evs_tol[b]) diff --git a/mne_pipeline_hd/gui/function_widgets.py b/mne_pipeline_hd/gui/function_widgets.py index b7312ba..8936a2d 100644 --- a/mne_pipeline_hd/gui/function_widgets.py +++ b/mne_pipeline_hd/gui/function_widgets.py @@ -915,9 +915,9 @@ def populate_guitype_cmbx(self): def target_cmbx_changed(self, idx): if self.current_function: - self.add_pd_funcs.loc[ - self.current_function, "target" - ] = self.target_cmbx.itemText(idx) + self.add_pd_funcs.loc[self.current_function, "target"] = ( + self.target_cmbx.itemText(idx) + ) self.target_chkl.setPixmap(self.yes_icon.pixmap(QSize(16, 16))) self.check_func_setup() @@ -926,9 +926,9 @@ def tab_cmbx_changed(self, idx): self.populate_tab_cmbx() self.tab_cmbx.setCurrentIndex(idx) if self.current_function: - self.add_pd_funcs.loc[ - self.current_function, "tab" - ] = self.tab_cmbx.itemText(idx) + self.add_pd_funcs.loc[self.current_function, "tab"] = ( + self.tab_cmbx.itemText(idx) + ) self.tab_chkl.setPixmap(self.yes_icon.pixmap(QSize(16, 16))) self.check_func_setup() @@ -1339,9 +1339,9 @@ def load_selected_functions(self): param_key, "functions" ] += func_key else: - self.cf.add_pd_params.loc[ - param_key, "functions" - ] = func_key + self.cf.add_pd_params.loc[param_key, "functions"] = ( + func_key + ) else: self.cf.add_pd_params.loc[param_key, "functions"] = func_key else: diff --git a/mne_pipeline_hd/gui/loading_widgets.py b/mne_pipeline_hd/gui/loading_widgets.py index ef6cb83..d346d82 100644 --- a/mne_pipeline_hd/gui/loading_widgets.py +++ b/mne_pipeline_hd/gui/loading_widgets.py @@ -1834,13 +1834,13 @@ def get_file_tables(self, kind): for parameter in result_dict: if isinstance(result_dict[parameter], tuple): if result_dict[parameter][2]: - obj_pd.loc[ - obj_name, path_type - ] = "critical_conflict" + obj_pd.loc[obj_name, path_type] = ( + "critical_conflict" + ) else: - obj_pd.loc[ - obj_name, path_type - ] = "possible_conflict" + obj_pd.loc[obj_name, path_type] = ( + "possible_conflict" + ) def open_prog_dlg(self): # Create Progress-Dialog