move import

This commit is contained in:
2025-08-19 14:30:05 -07:00
parent 391b42df50
commit b3470e6c96

View File

@@ -24,6 +24,7 @@ from multiprocessing import Queue
from typing import Any, Optional, cast, Literal, Iterator, Union from typing import Any, Optional, cast, Literal, Iterator, Union
# External library imports # External library imports
import h5py
import pywt # type: ignore import pywt # type: ignore
import qtpy # type: ignore import qtpy # type: ignore
import xlrd # type: ignore import xlrd # type: ignore
@@ -1919,7 +1920,6 @@ def run_GLM_analysis(data: BaseRaw, design_matrix: DataFrame) -> RegressionResul
def calculate_dpf(file_path): def calculate_dpf(file_path):
# order is hbo / hbr # order is hbo / hbr
import h5py
with h5py.File(file_path, 'r') as f: with h5py.File(file_path, 'r') as f:
wavelengths = f['/nirs/probe/wavelengths'][:] wavelengths = f['/nirs/probe/wavelengths'][:]
print("Wavelengths (nm):", wavelengths) print("Wavelengths (nm):", wavelengths)