typos and pylance
This commit is contained in:
@@ -9,7 +9,6 @@ License: GPL-3.0
|
||||
|
||||
# Built-in imports
|
||||
import os
|
||||
from pathlib import Path
|
||||
from typing import Any
|
||||
|
||||
# External library imports
|
||||
@@ -27,7 +26,7 @@ from src.shared.shareddata import APP_NAME
|
||||
class ExportToCSVWidget(CSVUIMixin, FlaresBaseWidget):
|
||||
def __init__(
|
||||
self,
|
||||
haemo_dict: dict[str | Path, BaseRaw],
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
cha_dict: dict[str, DataFrame],
|
||||
df_ind_dict: dict[str, DataFrame],
|
||||
design_matrix_dict: dict[str, DataFrame],
|
||||
|
||||
@@ -7,8 +7,7 @@ Author: Tyler de Zeeuw
|
||||
License: GPL-3.0
|
||||
"""
|
||||
|
||||
# Built-in Imports
|
||||
from pathlib import Path
|
||||
# Built-in imports
|
||||
from typing import Any, cast
|
||||
|
||||
# External library imports
|
||||
@@ -69,7 +68,7 @@ DESCRIPTION = """\n1. Group Contrast 2D/3D (plot_2d_3d_contrasts_between_groups)
|
||||
class InterGroupBrainImageWidget(InterGroupUIMixin, FlaresBaseWidget):
|
||||
def __init__(
|
||||
self,
|
||||
haemo_dict: dict[str | Path, BaseRaw],
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
df_ind_dict: dict[str, DataFrame],
|
||||
design_matrix_dict: dict[str, DataFrame],
|
||||
contrast_results_dict: dict[str, dict[str, Any]],
|
||||
|
||||
@@ -8,7 +8,6 @@ License: GPL-3.0
|
||||
"""
|
||||
|
||||
# Built-in imports
|
||||
from pathlib import Path
|
||||
from typing import Any, cast
|
||||
|
||||
# External library imports
|
||||
@@ -147,7 +146,7 @@ class InterGroupStatsWidget(InterGroupUIMixin, FlaresBaseWidget):
|
||||
|
||||
def __init__(
|
||||
self,
|
||||
haemo_dict: dict[str | Path, BaseRaw],
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
cha_dict: dict[str, DataFrame],
|
||||
df_ind_dict: dict[str, DataFrame],
|
||||
design_matrix_dict: dict[str, DataFrame],
|
||||
|
||||
@@ -7,8 +7,7 @@ Author: Tyler de Zeeuw
|
||||
License: GPL-3.0
|
||||
"""
|
||||
|
||||
# Built-in Imports
|
||||
from pathlib import Path
|
||||
# Built-in imports
|
||||
from typing import Any, cast
|
||||
|
||||
# External library imports
|
||||
@@ -79,7 +78,7 @@ DESCRIPTION = """0. FIR Model Results (plot_fir_model_results)
|
||||
class IntraGroupBrainImageWidget(IntraGroupUIMixin, FlaresBaseWidget):
|
||||
def __init__(
|
||||
self,
|
||||
haemo_dict: dict[str | Path, BaseRaw],
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
cha_dict: dict[str, DataFrame],
|
||||
df_ind_dict: dict[str, DataFrame],
|
||||
design_matrix_dict: dict[str, DataFrame],
|
||||
|
||||
@@ -8,7 +8,6 @@ License: GPL-3.0
|
||||
"""
|
||||
|
||||
# Built-in imports
|
||||
from pathlib import Path
|
||||
from typing import Any, cast
|
||||
|
||||
# External library imports
|
||||
@@ -61,7 +60,7 @@ DESCRIPTION = """0. Beta-Series Correlation (run_group_functional_connectivity_b
|
||||
class IntraGroupFunctionalConnectivityWidget(IntraGroupUIMixin, FlaresBaseWidget):
|
||||
def __init__(
|
||||
self,
|
||||
haemo_dict: dict[str | Path, BaseRaw],
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
epochs_dict: dict[str, Epochs],
|
||||
group_dict: dict[str, str],
|
||||
) -> None:
|
||||
@@ -99,7 +98,11 @@ class IntraGroupFunctionalConnectivityWidget(IntraGroupUIMixin, FlaresBaseWidget
|
||||
min_participants = params.get("min_participants", 3)
|
||||
|
||||
run_group_functional_connectivity_betas(
|
||||
self.haemo_dict, selected_file_paths, selected_event, n_lines, vmin,
|
||||
self.haemo_dict,
|
||||
selected_file_paths,
|
||||
selected_event,
|
||||
n_lines,
|
||||
vmin,
|
||||
drift_model=drift_model,
|
||||
drift_order=drift_order,
|
||||
hrf_model=hrf_model,
|
||||
|
||||
@@ -8,7 +8,6 @@ License: GPL-3.0
|
||||
"""
|
||||
|
||||
# Built-in imports
|
||||
from pathlib import Path
|
||||
from typing import Any, cast
|
||||
|
||||
# External library imports
|
||||
@@ -159,7 +158,7 @@ DESCRIPTION = """0. ROI vs. Zero (run_roi_second_level_analysis)
|
||||
class IntraGroupStatsWidget(IntraGroupUIMixin, FlaresBaseWidget):
|
||||
def __init__(
|
||||
self,
|
||||
haemo_dict: dict[str | Path, BaseRaw],
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
cha_dict: dict[str, DataFrame],
|
||||
df_ind_dict: dict[str, DataFrame],
|
||||
design_matrix_dict: dict[str, DataFrame],
|
||||
@@ -240,6 +239,10 @@ class IntraGroupStatsWidget(IntraGroupUIMixin, FlaresBaseWidget):
|
||||
if correction_method == "None":
|
||||
correction_method = None
|
||||
|
||||
if not selected_event:
|
||||
print("Warning: No event condition selected for ROI analysis.")
|
||||
continue
|
||||
|
||||
if df_group.empty:
|
||||
print("No ROI data (df_ind) found for selected participants.")
|
||||
continue
|
||||
@@ -265,7 +268,6 @@ class IntraGroupStatsWidget(IntraGroupUIMixin, FlaresBaseWidget):
|
||||
else:
|
||||
all_cha_filtered = all_cha
|
||||
|
||||
|
||||
run_roi_second_level_analysis(
|
||||
df_roi_all=df_filtered,
|
||||
condition=selected_event,
|
||||
@@ -303,7 +305,6 @@ class IntraGroupStatsWidget(IntraGroupUIMixin, FlaresBaseWidget):
|
||||
print("Both ROI A and ROI B must be specified.")
|
||||
continue
|
||||
|
||||
print(min_subjects)
|
||||
run_roi_paired_contrast_analysis(
|
||||
df_roi_all=df_group,
|
||||
roi_pairs=(roi_a, roi_b),
|
||||
|
||||
@@ -8,7 +8,6 @@ License: GPL-3.0
|
||||
"""
|
||||
|
||||
# Built-in imports
|
||||
from pathlib import Path
|
||||
from typing import Any, cast
|
||||
|
||||
# External library imports
|
||||
@@ -69,7 +68,7 @@ PARAMETERIZED_INDEXES: dict[int, list[dict[str, Any]]] = {
|
||||
class ParticipantBrainViewerWidget(ParticipantUIMixin, FlaresBaseWidget):
|
||||
def __init__(
|
||||
self,
|
||||
haemo_dict: dict[str | Path, BaseRaw],
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
cha_dict: dict[str, DataFrame],
|
||||
) -> None:
|
||||
|
||||
|
||||
@@ -748,7 +748,7 @@ class ProcessOrchestrator(QObject):
|
||||
|
||||
def __init__(self,
|
||||
selected_files,
|
||||
haemo_dict: dict[str | Path, BaseRaw],
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
worker_func
|
||||
):
|
||||
|
||||
|
||||
@@ -7,8 +7,7 @@ Author: Tyler de Zeeuw
|
||||
License: GPL-3.0
|
||||
"""
|
||||
|
||||
# Built-in Imports
|
||||
from pathlib import Path
|
||||
# Built-in imports
|
||||
from typing import Any, cast
|
||||
|
||||
# External library imports
|
||||
@@ -81,7 +80,7 @@ DESCRIPTION = """0. Spectral Coherence (functional_connectivity_spectral_epochs)
|
||||
class ParticipantFunctionalConnectivityWidget(ParticipantUIMixin, FlaresBaseWidget):
|
||||
def __init__(
|
||||
self,
|
||||
haemo_dict: dict[str | Path, BaseRaw],
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
epochs_dict: dict[str, Epochs],
|
||||
) -> None:
|
||||
|
||||
|
||||
@@ -7,7 +7,7 @@ Author: Tyler de Zeeuw
|
||||
License: GPL-3.0
|
||||
"""
|
||||
|
||||
# Built-in Imports
|
||||
# Built-in imports
|
||||
import os.path as op
|
||||
from pathlib import Path
|
||||
from datetime import datetime
|
||||
@@ -26,7 +26,7 @@ from src.shared.shareddata import APP_NAME
|
||||
class ParticipantImageViewerWidget(FlaresBaseWidget):
|
||||
def __init__(
|
||||
self,
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
haemo_dict: dict[str, BaseRaw],
|
||||
fig_bytes_dict: dict[str, dict[str, bytes]]
|
||||
) -> None:
|
||||
|
||||
|
||||
Reference in New Issue
Block a user