osl-ephys 2.0.0__py2.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.
- osl_ephys/__init__.py +40 -0
- osl_ephys/glm/README.md +3 -0
- osl_ephys/glm/__init__.py +6 -0
- osl_ephys/glm/glm_base.py +995 -0
- osl_ephys/glm/glm_epochs.py +386 -0
- osl_ephys/glm/glm_spectrum.py +1367 -0
- osl_ephys/maxfilter/README.md +141 -0
- osl_ephys/maxfilter/__init__.py +10 -0
- osl_ephys/maxfilter/maxfilter.py +775 -0
- osl_ephys/preprocessing/README.md +114 -0
- osl_ephys/preprocessing/__init__.py +10 -0
- osl_ephys/preprocessing/batch.py +1245 -0
- osl_ephys/preprocessing/ica_label.py +289 -0
- osl_ephys/preprocessing/mne_wrappers.py +831 -0
- osl_ephys/preprocessing/osl_wrappers.py +924 -0
- osl_ephys/preprocessing/plot_ica.py +1405 -0
- osl_ephys/report/README.md +31 -0
- osl_ephys/report/__init__.py +8 -0
- osl_ephys/report/preproc_report.py +1556 -0
- osl_ephys/report/src_report.py +499 -0
- osl_ephys/report/templates/raw_subject_panel.html +208 -0
- osl_ephys/report/templates/raw_summary_panel.html +89 -0
- osl_ephys/report/templates/src_subject_panel.html +142 -0
- osl_ephys/report/templates/src_summary_panel.html +129 -0
- osl_ephys/report/templates/subject_report.html +161 -0
- osl_ephys/report/templates/summary_report.html +92 -0
- osl_ephys/source_recon/README.md +3 -0
- osl_ephys/source_recon/__init__.py +6 -0
- osl_ephys/source_recon/batch.py +432 -0
- osl_ephys/source_recon/beamforming.py +1351 -0
- osl_ephys/source_recon/parcellation/__init__.py +6 -0
- osl_ephys/source_recon/parcellation/files/Glasser50_space-MNI152NLin6_res-8x8x8.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/Glasser52_binary_space-MNI152NLin6_res-8x8x8.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/HarvOxf-sub-Schaefer100-combined-2mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/HarvOxf-sub-Schaefer100-combined-2mm_4d.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/HarvOxf-sub-Schaefer100-combined-2mm_4d_ds8.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/HarvardOxford-sub-prob-bin-2mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/MNI152_T1_2mm_brain.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/MNI152_T1_8mm_brain.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/Schaefer2018_100Parcels_7Networks_order_FSLMNI152_2mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/Schaefer2018_100Parcels_7Networks_order_FSLMNI152_2mm_4d.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/Schaefer2018_100Parcels_7Networks_order_FSLMNI152_2mm_4d_ds8.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/WTA_fMRI_parcellation_ds2mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/WTA_fMRI_parcellation_ds8mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/aal_cortical_merged_8mm_stacked.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/dk_cortical.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/dk_full.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/fMRI_parcellation_ds2mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/fMRI_parcellation_ds8mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/fmri_d100_parcellation_with_PCC_reduced_2mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/fmri_d100_parcellation_with_PCC_reduced_2mm_ss5mm_ds8mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/fmri_d100_parcellation_with_PCC_tighterMay15_v2_2mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/fmri_d100_parcellation_with_PCC_tighterMay15_v2_6mm_exclusive.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/fmri_d100_parcellation_with_PCC_tighterMay15_v2_8mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/giles_39_binary.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/reduced_hcp-mmp_2mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/files/reduced_hcp-mmp_8mm.nii.gz +0 -0
- osl_ephys/source_recon/parcellation/nii.py +131 -0
- osl_ephys/source_recon/parcellation/parcellation.py +980 -0
- osl_ephys/source_recon/rhino/__init__.py +10 -0
- osl_ephys/source_recon/rhino/coreg.py +1105 -0
- osl_ephys/source_recon/rhino/forward_model.py +325 -0
- osl_ephys/source_recon/rhino/fsl_utils.py +84 -0
- osl_ephys/source_recon/rhino/polhemus.py +466 -0
- osl_ephys/source_recon/rhino/surfaces.py +569 -0
- osl_ephys/source_recon/rhino/utils.py +1318 -0
- osl_ephys/source_recon/sign_flipping.py +380 -0
- osl_ephys/source_recon/wrappers.py +1073 -0
- osl_ephys/tests/__init__.py +0 -0
- osl_ephys/tests/test_00_package_canary.py +76 -0
- osl_ephys/tests/test_batch_api.py +75 -0
- osl_ephys/tests/test_batch_preproc.py +144 -0
- osl_ephys/tests/test_file_handling.py +196 -0
- osl_ephys/tests/test_glm.py +41 -0
- osl_ephys/tests/test_parallel.py +82 -0
- osl_ephys/utils/README.md +3 -0
- osl_ephys/utils/__init__.py +16 -0
- osl_ephys/utils/create_neuromag306_info.py +98 -0
- osl_ephys/utils/file_handling.py +217 -0
- osl_ephys/utils/logger.py +161 -0
- osl_ephys/utils/misc.py +30 -0
- osl_ephys/utils/neuromag306_info.yml +1548 -0
- osl_ephys/utils/opm.py +347 -0
- osl_ephys/utils/package.py +44 -0
- osl_ephys/utils/parallel.py +79 -0
- osl_ephys/utils/run_func.py +38 -0
- osl_ephys/utils/simulate.py +233 -0
- osl_ephys/utils/simulation_config/megin_template_info.fif +0 -0
- osl_ephys/utils/simulation_config/reduced_mvar_params_grad.npy +0 -0
- osl_ephys/utils/simulation_config/reduced_mvar_params_mag.npy +0 -0
- osl_ephys/utils/simulation_config/reduced_mvar_pcacomp_grad.npy +0 -0
- osl_ephys/utils/simulation_config/reduced_mvar_pcacomp_mag.npy +0 -0
- osl_ephys/utils/simulation_config/reduced_mvar_residcov_grad.npy +0 -0
- osl_ephys/utils/simulation_config/reduced_mvar_residcov_mag.npy +0 -0
- osl_ephys/utils/spmio/__init__.py +1 -0
- osl_ephys/utils/spmio/_data.py +132 -0
- osl_ephys/utils/spmio/_events.py +153 -0
- osl_ephys/utils/spmio/_spmmeeg_utils.py +19 -0
- osl_ephys/utils/spmio/spmmeeg.py +245 -0
- osl_ephys/utils/study.py +155 -0
- osl_ephys/utils/version_utils.py +64 -0
- osl_ephys-2.0.0.dist-info/LICENSE +23 -0
- osl_ephys-2.0.0.dist-info/METADATA +140 -0
- osl_ephys-2.0.0.dist-info/RECORD +107 -0
- osl_ephys-2.0.0.dist-info/WHEEL +6 -0
- osl_ephys-2.0.0.dist-info/entry_points.txt +6 -0
- osl_ephys-2.0.0.dist-info/top_level.txt +1 -0
osl_ephys/__init__.py
ADDED
|
@@ -0,0 +1,40 @@
|
|
|
1
|
+
#!/usr/bin/python
|
|
2
|
+
|
|
3
|
+
# --------------------------------------------------------
|
|
4
|
+
# If user hasn't configured NumExpr environment the an irritating low-level log
|
|
5
|
+
# is generated. We supress it by setting a default value of 8 if not already
|
|
6
|
+
# set.
|
|
7
|
+
#
|
|
8
|
+
# https://numexpr.readthedocs.io/projects/NumExpr3/en/latest/user_guide.html#threadpool-configuration
|
|
9
|
+
# https://github.com/pydata/numexpr/blob/7c2ef387d81cd450e8220fe4174cf46ec559994c/numexpr/utils.py#L118
|
|
10
|
+
|
|
11
|
+
import os
|
|
12
|
+
if 'NUMEXPR_MAX_THREADS' not in os.environ:
|
|
13
|
+
os.environ['NUMEXPR_MAX_THREADS'] = '8'
|
|
14
|
+
|
|
15
|
+
# Some modules are chatty by default when a logger is on - set log-levels to
|
|
16
|
+
# WARNING on setup
|
|
17
|
+
import logging
|
|
18
|
+
logging.getLogger("asyncio").setLevel(logging.WARNING)
|
|
19
|
+
logging.getLogger("matplotlib").setLevel(logging.WARNING)
|
|
20
|
+
logging.getLogger("PIL").setLevel(logging.WARNING)
|
|
21
|
+
|
|
22
|
+
# Feels like there should be a better solution for this. How do we setup a
|
|
23
|
+
# logger which only produces OSL outputs?!
|
|
24
|
+
|
|
25
|
+
# --------------------------------------------------------
|
|
26
|
+
# Main importing - set module structure here
|
|
27
|
+
|
|
28
|
+
from . import utils # noqa: F401, F403
|
|
29
|
+
from . import preprocessing # noqa: F401, F403
|
|
30
|
+
from . import maxfilter # noqa: F401, F403
|
|
31
|
+
from . import report # noqa: F401, F403
|
|
32
|
+
from . import source_recon # noqa: F401, F403
|
|
33
|
+
from . import glm # noqa: F401, F403
|
|
34
|
+
|
|
35
|
+
# --------------------------------------------------------
|
|
36
|
+
osl_logger = logging.getLogger(__name__)
|
|
37
|
+
osl_logger.debug('osl-ephys main init complete')
|
|
38
|
+
|
|
39
|
+
# --------------------------------------------------------
|
|
40
|
+
__version__ = '2.0.0'
|
osl_ephys/glm/README.md
ADDED