From bb9010e0fbfc61a22550585eb5528a89a63f8ce6 Mon Sep 17 00:00:00 2001 From: Circle Ci Date: Tue, 7 Jan 2025 08:53:53 +0000 Subject: [PATCH] doc updates [skip ci] --- dev/.buildinfo | 2 +- .../auto_examples_python.zip | Bin 100564 -> 100564 bytes .../read_bids_datasets.zip | Bin 19834 -> 19834 bytes .../mark_bad_channels.zip | Bin 16471 -> 16471 bytes .../convert_mne_sample.zip | Bin 20477 -> 20477 bytes .../convert_nirs_to_bids.zip | Bin 16280 -> 16280 bytes .../convert_group_studies.zip | Bin 11180 -> 11180 bytes .../rename_brainvision_files.zip | Bin 8915 -> 8915 bytes .../auto_examples_jupyter.zip | Bin 155040 -> 155040 bytes .../bidspath.zip | Bin 17534 -> 17534 bytes .../convert_ieeg_to_bids.zip | Bin 47920 -> 47920 bytes .../update_bids_datasets.zip | Bin 11246 -> 11246 bytes .../create_bids_folder.zip | Bin 5678 -> 5678 bytes .../anonymize_dataset.zip | Bin 19666 -> 19666 bytes .../convert_eeg_to_bids.zip | Bin 21339 -> 21339 bytes .../convert_mri_and_trans.zip | Bin 27350 -> 27350 bytes .../convert_empty_room.zip | Bin 11978 -> 11978 bytes dev/_modules/index.html | 12 +- dev/_modules/mne_bids/copyfiles.html | 56 ++-- dev/_modules/mne_bids/dig.html | 66 ++--- dev/_modules/mne_bids/inspect.html | 68 ++--- dev/_modules/mne_bids/path.html | 204 +++++++-------- dev/_modules/mne_bids/read.html | 80 +++--- dev/_modules/mne_bids/report/_report.html | 62 ++--- dev/_modules/mne_bids/sidecar_updates.html | 40 +-- dev/_modules/mne_bids/stats.html | 20 +- dev/_modules/mne_bids/utils.html | 84 +++--- dev/_modules/mne_bids/write.html | 150 +++++------ dev/_static/documentation_options.js | 2 +- dev/_static/pygments.css | 242 +++++++++--------- dev/api.html | 12 +- dev/authors.html | 12 +- dev/auto_examples/anonymize_dataset.html | 80 +++--- dev/auto_examples/bidspath.html | 18 +- dev/auto_examples/convert_eeg_to_bids.html | 26 +- dev/auto_examples/convert_empty_room.html | 26 +- dev/auto_examples/convert_group_studies.html | 26 +- dev/auto_examples/convert_ieeg_to_bids.html | 28 +- dev/auto_examples/convert_mne_sample.html | 76 +++--- dev/auto_examples/convert_mri_and_trans.html | 32 +-- dev/auto_examples/convert_nirs_to_bids.html | 28 +- dev/auto_examples/create_bids_folder.html | 20 +- dev/auto_examples/mark_bad_channels.html | 22 +- dev/auto_examples/read_bids_datasets.html | 58 ++--- .../rename_brainvision_files.html | 20 +- dev/auto_examples/sg_execution_times.html | 48 ++-- dev/auto_examples/update_bids_datasets.html | 18 +- dev/contribute.html | 12 +- dev/generated/cli.html | 12 +- dev/generated/mne_bids.BIDSPath.html | 12 +- dev/generated/mne_bids.anonymize_dataset.html | 12 +- .../mne_bids.convert_montage_to_mri.html | 12 +- .../mne_bids.convert_montage_to_ras.html | 12 +- ...e_bids.copyfiles.copyfile_brainvision.html | 12 +- .../mne_bids.copyfiles.copyfile_bti.html | 12 +- .../mne_bids.copyfiles.copyfile_ctf.html | 12 +- .../mne_bids.copyfiles.copyfile_edf.html | 12 +- .../mne_bids.copyfiles.copyfile_eeglab.html | 12 +- .../mne_bids.copyfiles.copyfile_kit.html | 12 +- .../mne_bids.find_matching_paths.html | 12 +- .../mne_bids.get_anat_landmarks.html | 12 +- .../mne_bids.get_anonymization_daysback.html | 12 +- .../mne_bids.get_bids_path_from_fname.html | 12 +- dev/generated/mne_bids.get_datatypes.html | 12 +- .../mne_bids.get_entities_from_fname.html | 12 +- dev/generated/mne_bids.get_entity_vals.html | 12 +- .../mne_bids.get_head_mri_trans.html | 12 +- dev/generated/mne_bids.inspect_dataset.html | 14 +- .../mne_bids.make_dataset_description.html | 12 +- dev/generated/mne_bids.make_report.html | 12 +- dev/generated/mne_bids.mark_channels.html | 12 +- dev/generated/mne_bids.print_dir_tree.html | 12 +- dev/generated/mne_bids.read_raw_bids.html | 12 +- .../mne_bids.search_folder_for_text.html | 12 +- .../mne_bids.stats.count_events.html | 12 +- dev/generated/mne_bids.template_to_head.html | 12 +- .../mne_bids.update_anat_landmarks.html | 12 +- .../mne_bids.update_sidecar_json.html | 14 +- dev/generated/mne_bids.write_anat.html | 12 +- .../mne_bids.write_meg_calibration.html | 12 +- .../mne_bids.write_meg_crosstalk.html | 12 +- dev/generated/mne_bids.write_raw_bids.html | 12 +- dev/genindex.html | 12 +- dev/index.html | 12 +- dev/install.html | 12 +- dev/objects.inv | Bin 3709 -> 3709 bytes dev/py-modindex.html | 12 +- dev/search.html | 12 +- dev/searchindex.js | 2 +- dev/sg_execution_times.html | 48 ++-- dev/use.html | 16 +- dev/whats_new.html | 12 +- dev/whats_new_previous_releases.html | 12 +- 93 files changed, 1106 insertions(+), 1106 deletions(-) diff --git a/dev/.buildinfo b/dev/.buildinfo index ead6a6495..fcd22e3ec 100644 --- a/dev/.buildinfo +++ b/dev/.buildinfo @@ -1,4 +1,4 @@ # Sphinx build info version 1 # This file records the configuration used when building these files. When it is not found, a full rebuild will be done. -config: eae639d6f48449cb996a2fb66279b327 +config: 1e96f39d61659b04257a14cd680ab183 tags: 645f666f9bcd5a90fca523b33c5a78b7 diff --git a/dev/_downloads/07fcc19ba03226cd3d83d4e40ec44385/auto_examples_python.zip b/dev/_downloads/07fcc19ba03226cd3d83d4e40ec44385/auto_examples_python.zip index 416217b3fea65c249e8a4da759ed5e48b31c9e5d..2c1345bd8346bf8bb3406bd6850edc11209cb5cc 100644 GIT binary patch delta 271 zcmcaIk?qPvHr@blW)=|!5NL8!-^eR1$=vCtzFAwciJy5kkg-AIsXTKRkTJuGjJ^QD5m!e5 delta 271 zcmcaIk?qPvHr@blW)=|!5SXw=c_Xj1B=ht&%A2(%oA{a60vQ`Lp2{=N05WEHnDa5O z0WvOy8A>p(1~S<4)A+$6`E@t=nO6Wsy!x60nY)3E3-?)Nz~7IkPD_S0f_(=O@G$P z=ms)tx_%p@8OVU?8EuRXV3E~rj7}gIO#c9409`QMv>hk~GN+=Q(Gjd>4@d;)fa(81 R43KuG4xnO?$?YACz5p0TW4QnT diff --git a/dev/_downloads/268d987293d4ee80f1e0d3ca84cf1bd4/read_bids_datasets.zip b/dev/_downloads/268d987293d4ee80f1e0d3ca84cf1bd4/read_bids_datasets.zip index cfa8fce08c62a898bf9ef1189b97a09f98ff8b72..5278593f999eafa5d2433f6d5ee8254bb33c0585 100644 GIT binary patch delta 49 zcmex0i}BYiM&1B#W)=|!5U6%j-^j}D delta 49 zcmex6pYiW}M&1B#W)=|!5a?T@ypcCjj(Nfw<;|ILjE2lWfyuf44j_Ta8~l9%bA}I& diff --git a/dev/_downloads/4c4fb656ad2ed5296dbabd0c14fa2b02/convert_nirs_to_bids.zip b/dev/_downloads/4c4fb656ad2ed5296dbabd0c14fa2b02/convert_nirs_to_bids.zip index 9f62e2020df7891d50319134576bb109e499b9e4..a1de6be3d04c5ec0d7c6a57fe1a80511d29dd3d5 100644 GIT binary patch delta 47 xcmbPHKck*Ez?+#xgaHI*x~XsEbr)xz<)*$lTzr)}Gf-eMi@g&_V6vyZKL91`45a`7 delta 47 tcmbPHKck*Ez?+#xgaHIruTkE}>n_d=q&J6)uTlpwCbQT(foV^Be*j0U4s!qi diff --git a/dev/_downloads/5d54d38fa89e77a34bdfd9413b4fbe4f/convert_group_studies.zip b/dev/_downloads/5d54d38fa89e77a34bdfd9413b4fbe4f/convert_group_studies.zip index 9dd9d4a5004e2d7433e4e35b3bcbc325b87d590b..e244d26018569c510671cbc9e84bb137b18868ae 100644 GIT binary patch delta 47 xcmZ1zz9yVEz?+#xgaHIP-PAYoHt{oexv6iS#NQ~*3>26wrtJ(8m>i=W001BZ3~c}a delta 47 xcmZ1zz9yVEz?+#xgaHJmuTkE}+r-a2V~z6WN&Jn{%s_$3V%p9ifypu20RTX&4lMux diff --git a/dev/_downloads/6a5f0c10c42d095fdc0217cd0f22c214/rename_brainvision_files.zip b/dev/_downloads/6a5f0c10c42d095fdc0217cd0f22c214/rename_brainvision_files.zip index ee395d554b8f96726d69604980cfac6a45e9c1a6..9c88cbd2abd8e07e0c19d3ab7a0926aab56fbe37 100644 GIT binary patch delta 47 tcmccYdfAmXz?+#xgaHJ)+|)Pnn)5LO>CNtZZ-qgO$>vIKV7fsm7yu%P44wc0 delta 47 tcmccYdfAmXz?+#xgaHI*tWn;`YtF|Eq&K_sy%h#ACYvj{f$0XNU;slg4qgBN diff --git a/dev/_downloads/6f1e7a639e0699d6164445b55e6c116d/auto_examples_jupyter.zip b/dev/_downloads/6f1e7a639e0699d6164445b55e6c116d/auto_examples_jupyter.zip index aa3951baf74ab1b61f4cee77928201cd149d0cae..6599aa5d477f67ee4c1abe953d5cc5b7ad5b601a 100644 GIT binary patch delta 273 zcmZ3mn{&Z#PTl}-W)=|!5a@JM-^e>tjk(KBee+7SdTHjxK!&!HmkwB@BJZ^@^K76< zTGJkFFhh0SemOAX`I%g4=9xgL@E0tZ%nfep+v5TmFBmWb4cuNn;73$2>fh=ulrU`Z+9n<$kGC6^4oX#A@1QxgLe0Xks%ArJ#- R|8$O6pkko)(*t6e0suJ4SO)+A delta 273 zcmZ3mn{&Z#PTl}-W)=|!5SYG3c_Z&kHRc&>lsB(btCwcp3}k3KdFg;fD)L?nGp_-P zq&4l)1~XLG?U!R-3lw>NCRdtyHINbhf+dr=Z;kTyxIo4W2FySMw;MJwelr9q->$WV zF_4dW0+3aAi1EJxNW=Dq&x|Y7nO6W=+R{uD>_9rE?~7z|0@*m7If}^*sTVzLA?B%_&}L2j5HAI;F+^OAOlTfm|Vb$Yhr*RKnF}e U1Y&>`bHoA_1FfGP5X%$*0G9A%c>n+a diff --git a/dev/_downloads/701f5b32d08455f1c1e98b7ab1715881/bidspath.zip b/dev/_downloads/701f5b32d08455f1c1e98b7ab1715881/bidspath.zip index 09fc980b74d8fd7235947c4fca5a8ae1a42c0883..6b4b490d7929d9d04ce1b46c820b09696d05d111 100644 GIT binary patch delta 49 vcmey@!T7I(kvG7bnMH&F1ZKObZ{#(UU%ka?z?`sT@jY?;hJfyr}rIe`QwKiuUH0C}4k-Wt diff --git a/dev/_downloads/bdc50d7de6c227351cc05fc714c0362c/anonymize_dataset.zip b/dev/_downloads/bdc50d7de6c227351cc05fc714c0362c/anonymize_dataset.zip index 4ccde1e35ff527d290c8c6caef51935af37570cc..a3aa8818b3427abc43e22529fcafc8e63da95574 100644 GIT binary patch delta 49 zcmcaKlkw6_M&1B#W)=|!5SZ_GyP+kAWgW)cqR delta 49 zcmcaKlkw6_M&1B#W)=|!5LmlLc_Z&rdFIV)lsA8s_t9Yn3QTtKu?GoEZu9X00Ee^? AwEzGB diff --git a/dev/_downloads/c3986e0cfd29a19505f36bab33dcf723/convert_eeg_to_bids.zip b/dev/_downloads/c3986e0cfd29a19505f36bab33dcf723/convert_eeg_to_bids.zip index 4d590e1c40ccecf0d6bf991084cac350f1551884..ba4e9e3cbadb82d9e8e5b2d9e5da4663884bfcf3 100644 GIT binary patch delta 49 wcmcb;jPdp|M&1B#W)=|!5a@JM-^ja9ff-0|KBw@*5X6{#GRP53^9K6?0CC9=KL7v# delta 49 wcmcb;jPdp|M&1B#W)=|!5SYG3c_Z&W1!f?<`JBQJLl9%~$sk8C%^U0o0FrSK{{R30 diff --git a/dev/_downloads/d90b2c92d1a1159e30b2143cd51843b4/convert_mri_and_trans.zip b/dev/_downloads/d90b2c92d1a1159e30b2143cd51843b4/convert_mri_and_trans.zip index 4258a7f006ad200fdf49aef8fff3f3912918eb99..bc8390872227e11b924dc8d2984ffe532472637a 100644 GIT binary patch delta 49 zcmcb1mGRnDM&1B#W)=|!5a@DK-^e>xn|ZpM`sTIT6YQ9Q0+SuGoIwJU+p+=xbqNnm delta 49 zcmcb1mGRnDM&1B#W)=|!5SXz>c_Z&!ZRQnglsB){o?yoe6qxLgVdn%SUz?+#xgaHI*xv6jDP2*>t?WVrDjQ^kVdn%SUz?+#xgaHIruTkE}o5s()W{vXZGX8^d%s_$3R(cK~fyuRcz5rD#4;26a diff --git a/dev/_modules/index.html b/dev/_modules/index.html index 0c44b11e7..8bfea63db 100644 --- a/dev/_modules/index.html +++ b/dev/_modules/index.html @@ -7,7 +7,7 @@ - Overview: module code — MNE-BIDS 0.17.0.dev19+g41ce36a4 documentation + Overview: module code — MNE-BIDS 0.17.0.dev20+g18bd9739 documentation @@ -29,7 +29,7 @@ - + @@ -43,7 +43,7 @@ - + @@ -77,7 +77,7 @@ - + @@ -140,7 +140,7 @@ -

MNE-BIDS 0.17.0.dev19+g41ce36a4 documentation

+

MNE-BIDS 0.17.0.dev20+g18bd9739 documentation

@@ -529,7 +529,7 @@

All modules for which code is available

diff --git a/dev/_modules/mne_bids/copyfiles.html b/dev/_modules/mne_bids/copyfiles.html index 98615674e..8d8da3d2d 100644 --- a/dev/_modules/mne_bids/copyfiles.html +++ b/dev/_modules/mne_bids/copyfiles.html @@ -7,7 +7,7 @@ - mne_bids.copyfiles — MNE-BIDS 0.17.0.dev19+g41ce36a4 documentation + mne_bids.copyfiles — MNE-BIDS 0.17.0.dev20+g18bd9739 documentation @@ -29,7 +29,7 @@ - + @@ -43,7 +43,7 @@ - + @@ -77,7 +77,7 @@ - + @@ -140,7 +140,7 @@ -

MNE-BIDS 0.17.0.dev19+g41ce36a4 documentation

+

MNE-BIDS 0.17.0.dev20+g18bd9739 documentation

@@ -492,22 +492,22 @@

Source code for mne_bids.copyfiles

 # Authors: The MNE-BIDS developers
 # SPDX-License-Identifier: BSD-3-Clause
 
-import os
-import os.path as op
-import re
-import shutil as sh
-from pathlib import Path
+import os
+import os.path as op
+import re
+import shutil as sh
+from pathlib import Path
 
-import numpy as np
-from mne.io import anonymize_info, read_raw_bdf, read_raw_brainvision, read_raw_edf
-from mne.utils import logger, verbose
-from scipy.io import loadmat, savemat
+import numpy as np
+from mne.io import anonymize_info, read_raw_bdf, read_raw_brainvision, read_raw_edf
+from mne.utils import logger, verbose
+from scipy.io import loadmat, savemat
 
-from mne_bids.path import BIDSPath, _mkdir_p, _parse_ext
-from mne_bids.utils import _check_anonymize, _get_mrk_meas_date, warn
+from mne_bids.path import BIDSPath, _mkdir_p, _parse_ext
+from mne_bids.utils import _check_anonymize, _get_mrk_meas_date, warn
 
 
-def _copytree(src, dst, **kwargs):
+def _copytree(src, dst, **kwargs):
     """See: https://github.com/jupyterlab/jupyterlab/pull/5150."""
     try:
         sh.copytree(src, dst, **kwargs)
@@ -518,7 +518,7 @@ 

Source code for mne_bids.copyfiles

             raise
 
 
-def _get_brainvision_encoding(vhdr_file):
+def _get_brainvision_encoding(vhdr_file):
     """Get the encoding of .vhdr and .vmrk files.
 
     Parameters
@@ -548,7 +548,7 @@ 

Source code for mne_bids.copyfiles

     return enc
 
 
-def _get_brainvision_paths(vhdr_path):
+def _get_brainvision_paths(vhdr_path):
     """Get the .eeg/.dat and .vmrk file paths from a BrainVision header file.
 
     Parameters
@@ -609,7 +609,7 @@ 

Source code for mne_bids.copyfiles

 
 
[docs] -def copyfile_ctf(src, dest): +def copyfile_ctf(src, dest): """Copy and rename CTF files to a new location. Parameters @@ -660,7 +660,7 @@

Source code for mne_bids.copyfiles

 
 
[docs] -def copyfile_kit(src, dest, subject_id, session_id, task, run, _init_kwargs): +def copyfile_kit(src, dest, subject_id, session_id, task, run, _init_kwargs): """Copy and rename KIT files to a new location. Parameters @@ -740,7 +740,7 @@

Source code for mne_bids.copyfiles

 
 
 
-def _replace_file(fname, pattern, replace):
+def _replace_file(fname, pattern, replace):
     """Overwrite file, replacing end of lines matching pattern with replace."""
     new_content = []
     for line in open(fname):
@@ -753,7 +753,7 @@ 

Source code for mne_bids.copyfiles

         fout.writelines(new_content)
 
 
-def _anonymize_brainvision(vhdr_file, date):
+def _anonymize_brainvision(vhdr_file, date):
     """Anonymize vmrk and vhdr files in place using `date` datetime object."""
     _, vmrk_file = _get_brainvision_paths(vhdr_file)
 
@@ -771,7 +771,7 @@ 

Source code for mne_bids.copyfiles

 
[docs] @verbose -def copyfile_brainvision(vhdr_src, vhdr_dest, anonymize=None, verbose=None): +def copyfile_brainvision(vhdr_src, vhdr_dest, anonymize=None, verbose=None): """Copy a BrainVision file triplet to a new location and repair links. The BrainVision file format consists of three files: @@ -887,7 +887,7 @@

Source code for mne_bids.copyfiles

 
 
[docs] -def copyfile_edf(src, dest, anonymize=None): +def copyfile_edf(src, dest, anonymize=None): """Copy an EDF, EDF+, or BDF file to a new location, optionally anonymize. .. warning:: EDF/EDF+/BDF files contain two fields for recording dates: @@ -1013,7 +1013,7 @@

Source code for mne_bids.copyfiles

 
 
[docs] -def copyfile_eeglab(src, dest): +def copyfile_eeglab(src, dest): """Copy an EEGLAB file to a new location. If the EEGLAB ``.set`` file comes with an accompanying ``.fdt`` binary file @@ -1098,7 +1098,7 @@

Source code for mne_bids.copyfiles

 
 
[docs] -def copyfile_bti(raw, dest): +def copyfile_bti(raw, dest): """Copy BTi data. Parameters @@ -1176,7 +1176,7 @@

Source code for mne_bids.copyfiles

 
   
diff --git a/dev/_modules/mne_bids/dig.html b/dev/_modules/mne_bids/dig.html
index d22a8fde4..8825b8609 100644
--- a/dev/_modules/mne_bids/dig.html
+++ b/dev/_modules/mne_bids/dig.html
@@ -7,7 +7,7 @@
   
     
     
-    mne_bids.dig — MNE-BIDS 0.17.0.dev19+g41ce36a4 documentation
+    mne_bids.dig — MNE-BIDS 0.17.0.dev20+g18bd9739 documentation
   
   
   
@@ -29,7 +29,7 @@
   
 
 
-    
+    
     
     
     
@@ -43,7 +43,7 @@
   
 
 
-    
+    
     
     
     
@@ -77,7 +77,7 @@
 
   
   
-  
+  
 
   
   
@@ -140,7 +140,7 @@
   
   
   
-    

MNE-BIDS 0.17.0.dev19+g41ce36a4 documentation

+

MNE-BIDS 0.17.0.dev20+g18bd9739 documentation

@@ -486,20 +486,20 @@

Source code for mne_bids.dig

 # Authors: The MNE-BIDS developers
 # SPDX-License-Identifier: BSD-3-Clause
 
-import json
-import os.path as op
-import re
-import warnings
-from collections import OrderedDict
-from pathlib import Path
+import json
+import os.path as op
+import re
+import warnings
+from collections import OrderedDict
+from pathlib import Path
 
-import mne
-import numpy as np
-from mne.io.constants import FIFF
-from mne.io.pick import _picks_to_idx
-from mne.utils import _check_option, _validate_type, get_subjects_dir, logger
+import mne
+import numpy as np
+from mne.io.constants import FIFF
+from mne.io.pick import _picks_to_idx
+from mne.utils import _check_option, _validate_type, get_subjects_dir, logger
 
-from mne_bids.config import (
+from mne_bids.config import (
     ALLOWED_SPACES,
     BIDS_COORD_FRAME_DESCRIPTIONS,
     BIDS_COORDINATE_UNITS,
@@ -509,9 +509,9 @@ 

Source code for mne_bids.dig

     MNE_STR_TO_FRAME,
     MNE_TO_BIDS_FRAMES,
 )
-from mne_bids.path import BIDSPath
-from mne_bids.tsv_handler import _from_tsv
-from mne_bids.utils import (
+from mne_bids.path import BIDSPath
+from mne_bids.tsv_handler import _from_tsv
+from mne_bids.utils import (
     _import_nibabel,
     _scale_coord_to_meters,
     _write_json,
@@ -523,7 +523,7 @@ 

Source code for mne_bids.dig

 data_dir = Path(__file__).parent / "data"
 
 
-def _handle_electrodes_reading(electrodes_fname, coord_frame, coord_unit):
+def _handle_electrodes_reading(electrodes_fname, coord_frame, coord_unit):
     """Read associated electrodes.tsv and populate raw.
 
     Handle xyz coordinates and coordinate frame of each channel.
@@ -532,7 +532,7 @@ 

Source code for mne_bids.dig

     electrodes_dict = _from_tsv(electrodes_fname)
     ch_names_tsv = electrodes_dict["name"]
 
-    def _float_or_nan(val):
+    def _float_or_nan(val):
         if val == "n/a":
             return np.nan
         else:
@@ -556,7 +556,7 @@ 

Source code for mne_bids.dig

     return montage
 
 
-def _handle_coordsystem_reading(coordsystem_fpath, datatype):
+def _handle_coordsystem_reading(coordsystem_fpath, datatype):
     """Read associated coordsystem.json.
 
     Handle reading the coordinate frame and coordinate unit
@@ -585,7 +585,7 @@ 

Source code for mne_bids.dig

     return coord_frame, coord_unit
 
 
-def _get_impedances(raw, names):
+def _get_impedances(raw, names):
     """Get the impedance values in kOhm from raw.impedances."""
     if not hasattr(raw, "impedances"):  # pragma: no cover
         return ["n/a"] * len(names)
@@ -602,7 +602,7 @@ 

Source code for mne_bids.dig

     return impedances
 
 
-def _write_electrodes_tsv(raw, fname, datatype, overwrite=False):
+def _write_electrodes_tsv(raw, fname, datatype, overwrite=False):
     """Create an electrodes.tsv file and save it.
 
     Parameters
@@ -691,7 +691,7 @@ 

Source code for mne_bids.dig

     _write_tsv(fname, data, overwrite=True)
 
 
-def _write_optodes_tsv(raw, fname, overwrite=False, verbose=True):
+def _write_optodes_tsv(raw, fname, overwrite=False, verbose=True):
     """Create a optodes.tsv file and save it.
 
     Parameters
@@ -757,7 +757,7 @@ 

Source code for mne_bids.dig

     _write_tsv(fname, ch_data, overwrite, verbose)
 
 
-def _write_coordsystem_json(
+def _write_coordsystem_json(
     *,
     raw,
     unit,
@@ -869,7 +869,7 @@ 

Source code for mne_bids.dig

     _write_json(fname, fid_json, overwrite=True)
 
 
-def _write_dig_bids(bids_path, raw, montage=None, acpc_aligned=False, overwrite=False):
+def _write_dig_bids(bids_path, raw, montage=None, acpc_aligned=False, overwrite=False):
     """Write BIDS formatted DigMontage from Raw instance.
 
     Handles coordsystem.json and electrodes.tsv writing
@@ -1008,7 +1008,7 @@ 

Source code for mne_bids.dig

     )
 
 
-def _read_dig_bids(electrodes_fpath, coordsystem_fpath, datatype, raw):
+def _read_dig_bids(electrodes_fpath, coordsystem_fpath, datatype, raw):
     """Read MNE-Python formatted DigMontage from BIDS files.
 
     Handles coordinatesystem.json and electrodes.tsv reading
@@ -1102,7 +1102,7 @@ 

Source code for mne_bids.dig

 
[docs] @verbose -def template_to_head(info, space, coord_frame="auto", unit="auto", verbose=None): +def template_to_head(info, space, coord_frame="auto", unit="auto", verbose=None): """Transform a BIDS standard template montage to the head coordinate frame. Parameters @@ -1196,7 +1196,7 @@

Source code for mne_bids.dig

 
[docs] @verbose -def convert_montage_to_ras(montage, subject, subjects_dir=None, verbose=None): +def convert_montage_to_ras(montage, subject, subjects_dir=None, verbose=None): """Convert a montage from surface RAS (m) to scanner RAS (m). Parameters @@ -1238,7 +1238,7 @@

Source code for mne_bids.dig

 
[docs] @verbose -def convert_montage_to_mri(montage, subject, subjects_dir=None, verbose=None): +def convert_montage_to_mri(montage, subject, subjects_dir=None, verbose=None): """Convert a montage from scanner RAS (m) to surface RAS (m). Parameters @@ -1322,7 +1322,7 @@

Source code for mne_bids.dig

 
   
diff --git a/dev/_modules/mne_bids/inspect.html b/dev/_modules/mne_bids/inspect.html
index d4b0712e1..537fb84a1 100644
--- a/dev/_modules/mne_bids/inspect.html
+++ b/dev/_modules/mne_bids/inspect.html
@@ -7,7 +7,7 @@
   
     
     
-    mne_bids.inspect — MNE-BIDS 0.17.0.dev19+g41ce36a4 documentation
+    mne_bids.inspect — MNE-BIDS 0.17.0.dev20+g18bd9739 documentation
   
   
   
@@ -29,7 +29,7 @@
   
 
 
-    
+    
     
     
     
@@ -43,7 +43,7 @@
   
 
 
-    
+    
     
     
     
@@ -77,7 +77,7 @@
 
   
   
-  
+  
 
   
   
@@ -140,7 +140,7 @@
   
   
   
-    

MNE-BIDS 0.17.0.dev19+g41ce36a4 documentation

+

MNE-BIDS 0.17.0.dev20+g18bd9739 documentation

@@ -486,24 +486,24 @@

Source code for mne_bids.inspect

 # Authors: The MNE-BIDS developers
 # SPDX-License-Identifier: BSD-3-Clause
 
-from pathlib import Path
+from pathlib import Path
 
-import mne
-import numpy as np
-from mne.preprocessing import annotate_amplitude
-from mne.utils import logger, verbose
-from mne.viz import use_browser_backend
+import mne
+import numpy as np
+from mne.preprocessing import annotate_amplitude
+from mne.utils import logger, verbose
+from mne.viz import use_browser_backend
 
-from mne_bids import mark_channels, read_raw_bids
-from mne_bids.config import ALLOWED_DATATYPE_EXTENSIONS
-from mne_bids.read import _from_tsv, _read_events
-from mne_bids.write import _events_tsv
+from mne_bids import mark_channels, read_raw_bids
+from mne_bids.config import ALLOWED_DATATYPE_EXTENSIONS
+from mne_bids.read import _from_tsv, _read_events
+from mne_bids.write import _events_tsv
 
 
 
[docs] @verbose -def inspect_dataset( +def inspect_dataset( bids_path, find_flat=True, l_freq=None, @@ -610,11 +610,11 @@

Source code for mne_bids.inspect

 _global_vars = dict(raw_fig=None, dialog_fig=None, mne_close_key=None)
 
 
-def _inspect_raw(*, bids_path, l_freq, h_freq, find_flat, show_annotations):
+def _inspect_raw(*, bids_path, l_freq, h_freq, find_flat, show_annotations):
     """Raw data inspection."""
     # Delay the import
-    import matplotlib
-    import matplotlib.pyplot as plt
+    import matplotlib
+    import matplotlib.pyplot as plt
 
     extra_params = dict()
     if bids_path.extension == ".fif":
@@ -650,7 +650,7 @@ 

Source code for mne_bids.inspect

 
     # Add our own event handlers so that when the MNE Raw Browser is being
     # closed, our dialog box will pop up, asking whether to save changes.
-    def _handle_close(event):
+    def _handle_close(event):
         mne_raw_fig = event.canvas.figure
         # Bads alterations are only transferred to `inst` once the figure is
         # closed; Annotation changes are immediately reflected in `inst`
@@ -675,7 +675,7 @@ 

Source code for mne_bids.inspect

         )
         _global_vars["raw_fig"] = None
 
-    def _keypress_callback(event):
+    def _keypress_callback(event):
         if event.key == _global_vars["mne_close_key"]:
             _handle_close(event)
 
@@ -700,7 +700,7 @@ 

Source code for mne_bids.inspect

     _global_vars["mne_close_key"] = fig.mne.close_key
 
 
-def _annotations_almost_equal(old_annotations, new_annotations):
+def _annotations_almost_equal(old_annotations, new_annotations):
     """Allow for a tiny bit of floating point precision loss."""
     if (
         np.array_equal(old_annotations.description, new_annotations.description)
@@ -713,7 +713,7 @@ 

Source code for mne_bids.inspect

         return False
 
 
-def _save_annotations(*, annotations, bids_path):
+def _save_annotations(*, annotations, bids_path):
     # Attach the new Annotations to our raw data so we can easily convert them
     # to events, which will be stored in the *_events.tsv sidecar.
     extra_params = dict()
@@ -748,7 +748,7 @@ 

Source code for mne_bids.inspect

         events_tsv_fname.unlink()
 
 
-def _save_raw_if_changed(
+def _save_raw_if_changed(
     *, old_bads, new_bads, flat_chans, old_annotations, new_annotations, bids_path
 ):
     """Save bad channel selection if it has been changed.
@@ -820,13 +820,13 @@ 

Source code for mne_bids.inspect

     )
 
 
-def _save_raw_dialog_box(*, bads, bad_descriptions, annotations, bids_path):
+def _save_raw_dialog_box(*, bads, bad_descriptions, annotations, bids_path):
     """Display a dialog box asking whether to save the changes."""
     # Delay the imports
-    import matplotlib
-    import matplotlib.pyplot as plt
-    from matplotlib.widgets import Button
-    from mne.viz.utils import figure_nobar
+    import matplotlib
+    import matplotlib.pyplot as plt
+    from matplotlib.widgets import Button
+    from mne.viz.utils import figure_nobar
 
     title = "Save changes?"
     message = "You have modified "
@@ -890,7 +890,7 @@ 

Source code for mne_bids.inspect

     fig.dont_save_button = dont_save_button
 
     # Define callback functions.
-    def _save_callback(event):
+    def _save_callback(event):
         plt.close(event.canvas.figure)  # Close dialog
         _global_vars["dialog_fig"] = None
 
@@ -899,11 +899,11 @@ 

Source code for mne_bids.inspect

         if annotations is not None:
             _save_annotations(annotations=annotations, bids_path=bids_path)
 
-    def _dont_save_callback(event):
+    def _dont_save_callback(event):
         plt.close(event.canvas.figure)  # Close dialog
         _global_vars["dialog_fig"] = None
 
-    def _keypress_callback(event):
+    def _keypress_callback(event):
         if event.key in ["enter", "return"]:
             _save_callback(event)
         elif event.key == _global_vars["mne_close_key"]:
@@ -921,7 +921,7 @@ 

Source code for mne_bids.inspect

     _global_vars["dialog_fig"] = fig
 
 
-def _save_bads(*, bads, descriptions, bids_path):
+def _save_bads(*, bads, descriptions, bids_path):
     """Update the set of channels marked as bad.
 
     Parameters
@@ -977,7 +977,7 @@ 

Source code for mne_bids.inspect

 
   
diff --git a/dev/_modules/mne_bids/path.html b/dev/_modules/mne_bids/path.html
index 79548b0de..a06e02022 100644
--- a/dev/_modules/mne_bids/path.html
+++ b/dev/_modules/mne_bids/path.html
@@ -7,7 +7,7 @@
   
     
     
-    mne_bids.path — MNE-BIDS 0.17.0.dev19+g41ce36a4 documentation
+    mne_bids.path — MNE-BIDS 0.17.0.dev20+g18bd9739 documentation
   
   
   
@@ -29,7 +29,7 @@
   
 
 
-    
+    
     
     
     
@@ -43,7 +43,7 @@
   
 
 
-    
+    
     
     
     
@@ -77,7 +77,7 @@
 
   
   
-  
+  
 
   
   
@@ -140,7 +140,7 @@
   
   
   
-    

MNE-BIDS 0.17.0.dev19+g41ce36a4 documentation

+

MNE-BIDS 0.17.0.dev20+g18bd9739 documentation

@@ -486,23 +486,23 @@

Source code for mne_bids.path

 # Authors: The MNE-BIDS developers
 # SPDX-License-Identifier: BSD-3-Clause
 
-import glob
-import inspect
-import json
-import os
-import re
-import shutil as sh
-from copy import deepcopy
-from datetime import datetime
-from io import StringIO
-from os import path as op
-from pathlib import Path
-from textwrap import indent
-
-import numpy as np
-from mne.utils import _check_fname, _validate_type, logger, verbose
-
-from mne_bids.config import (
+import glob
+import inspect
+import json
+import os
+import re
+import shutil as sh
+from copy import deepcopy
+from datetime import datetime
+from io import StringIO
+from os import path as op
+from pathlib import Path
+from textwrap import indent
+
+import numpy as np
+from mne.utils import _check_fname, _validate_type, logger, verbose
+
+from mne_bids.config import (
     ALLOWED_DATATYPE_EXTENSIONS,
     ALLOWED_DATATYPES,
     ALLOWED_FILENAME_EXTENSIONS,
@@ -513,8 +513,8 @@ 

Source code for mne_bids.path

     ENTITY_VALUE_TYPE,
     reader,
 )
-from mne_bids.tsv_handler import _drop, _from_tsv, _to_tsv
-from mne_bids.utils import (
+from mne_bids.tsv_handler import _drop, _from_tsv, _to_tsv
+from mne_bids.utils import (
     _check_empty_room_basename,
     _check_key_val,
     _ensure_tuple,
@@ -523,7 +523,7 @@ 

Source code for mne_bids.path

 )
 
 
-def _find_empty_room_candidates(bids_path):
+def _find_empty_room_candidates(bids_path):
     """Get matching empty-room file for an MEG recording."""
     # Check whether we have a BIDS root.
     bids_root = bids_path.root
@@ -584,8 +584,8 @@ 

Source code for mne_bids.path

     return candidates
 
 
-def _find_matched_empty_room(bids_path):
-    from mne_bids import read_raw_bids  # avoid circular import.
+def _find_matched_empty_room(bids_path):
+    from mne_bids import read_raw_bids  # avoid circular import.
 
     candidates = _find_empty_room_candidates(bids_path)
 
@@ -659,7 +659,7 @@ 

Source code for mne_bids.path

 
 
[docs] -class BIDSPath: +class BIDSPath: """A BIDS path object. BIDS filename prefixes have one or more pieces of metadata in them. They @@ -810,7 +810,7 @@

Source code for mne_bids.path

     functional MRI paths.
     """
 
-    def __init__(
+    def __init__(
         self,
         subject=None,
         session=None,
@@ -867,7 +867,7 @@ 

Source code for mne_bids.path

         )
 
     @property
-    def entities(self):
+    def entities(self):
         """Return dictionary of the BIDS entities."""
         return {
             "subject": self.subject,
@@ -883,7 +883,7 @@ 

Source code for mne_bids.path

         }
 
     @property
-    def basename(self):
+    def basename(self):
         """Path basename."""
         basename = []
         for key, val in self.entities.items():
@@ -905,7 +905,7 @@ 

Source code for mne_bids.path

         return basename
 
     @property
-    def directory(self):
+    def directory(self):
         """Get the BIDS parent directory.
 
         If ``subject``, ``session`` and ``datatype`` are set, then they will be
@@ -933,136 +933,136 @@ 

Source code for mne_bids.path

         return Path(data_path)
 
     @property
-    def subject(self) -> str | None:
+    def subject(self) -> str | None:
         """The subject ID."""
         return self._subject
 
     @subject.setter
-    def subject(self, value):
+    def subject(self, value):
         self.update(subject=value)
 
     @property
-    def session(self) -> str | None:
+    def session(self) -> str | None:
         """The acquisition session."""
         return self._session
 
     @session.setter
-    def session(self, value):
+    def session(self, value):
         self.update(session=value)
 
     @property
-    def task(self) -> str | None:
+    def task(self) -> str | None:
         """The experimental task."""
         return self._task
 
     @task.setter
-    def task(self, value):
+    def task(self, value):
         self.update(task=value)
 
     @property
-    def run(self) -> str | None:
+    def run(self) -> str | None:
         """The run number."""
         return self._run
 
     @run.setter
-    def run(self, value):
+    def run(self, value):
         self.update(run=value)
 
     @property
-    def acquisition(self) -> str | None:
+    def acquisition(self) -> str | None:
         """The acquisition parameters."""
         return self._acquisition
 
     @acquisition.setter
-    def acquisition(self, value):
+    def acquisition(self, value):
         self.update(acquisition=value)
 
     @property
-    def processing(self) -> str | None:
+    def processing(self) -> str | None:
         """The processing label."""
         return self._processing
 
     @processing.setter
-    def processing(self, value):
+    def processing(self, value):
         self.update(processing=value)
 
     @property
-    def recording(self) -> str | None:
+    def recording(self) -> str | None:
         """The recording name."""
         return self._recording
 
     @recording.setter
-    def recording(self, value):
+    def recording(self, value):
         self.update(recording=value)
 
     @property
-    def space(self) -> str | None:
+    def space(self) -> str | None:
         """The coordinate space for an anatomical or sensor position file."""
         return self._space
 
     @space.setter
-    def space(self, value):
+    def space(self, value):
         self.update(space=value)
 
     @property
-    def description(self) -> str | None:
+    def description(self) -> str | None:
         """The description entity."""
         return self._description
 
     @description.setter
-    def description(self, value):
+    def description(self, value):
         self.update(description=value)
 
     @property
-    def suffix(self) -> str | None:
+    def suffix(self) -> str | None:
         """The filename suffix."""
         return self._suffix
 
     @suffix.setter
-    def suffix(self, value):
+    def suffix(self, value):
         self.update(suffix=value)
 
     @property
-    def root(self) -> Path | None:
+    def root(self) -> Path | None:
         """The root directory of the BIDS dataset."""
         return self._root
 
     @root.setter
-    def root(self, value):
+    def root(self, value):
         self.update(root=value)
 
     @property
-    def datatype(self) -> str | None:
+    def datatype(self) -> str | None:
         """The BIDS data type, e.g. ``'anat'``, ``'meg'``, ``'eeg'``."""
         return self._datatype
 
     @datatype.setter
-    def datatype(self, value):
+    def datatype(self, value):
         self.update(datatype=value)
 
     @property
-    def split(self) -> str | None:
+    def split(self) -> str | None:
         """The split of the continuous recording file for ``.fif`` data."""
         return self._split
 
     @split.setter
-    def split(self, value):
+    def split(self, value):
         self.update(split=value)
 
     @property
-    def extension(self) -> str | None:
+    def extension(self) -> str | None:
         """The extension of the filename, including a leading period."""
         return self._extension
 
     @extension.setter
-    def extension(self, value):
+    def extension(self, value):
         self.update(extension=value)
 
-    def __str__(self):
+    def __str__(self):
         """Return the string representation of the path."""
         return str(self.fpath.as_posix())
 
-    def __repr__(self):
+    def __repr__(self):
         """Representation in the style of `pathlib.Path`."""
         root = self.root.as_posix() if self.root is not None else None
 
@@ -1073,21 +1073,21 @@ 

Source code for mne_bids.path

             f"basename: {self.basename})"
         )
 
-    def __fspath__(self):
+    def __fspath__(self):
         """Return the string representation for any fs functions."""
         return str(self.fpath)
 
-    def __eq__(self, other):
+    def __eq__(self, other):
         """Compare str representations."""
         return str(self) == str(other)
 
-    def __ne__(self, other):
+    def __ne__(self, other):
         """Compare str representations."""
         return str(self) != str(other)
 
 
[docs] - def copy(self): + def copy(self): """Copy the instance. Returns @@ -1100,7 +1100,7 @@

Source code for mne_bids.path

 
 
[docs] - def mkdir(self, exist_ok=True): + def mkdir(self, exist_ok=True): """Create the directory structure of the BIDS path. Parameters @@ -1121,7 +1121,7 @@

Source code for mne_bids.path

 
[docs] @verbose - def rm(self, *, safe_remove=True, verbose=None): + def rm(self, *, safe_remove=True, verbose=None): """Safely delete a set of files from a BIDS dataset. Deleting a scan that conforms to the bids-validator will @@ -1290,7 +1290,7 @@

Source code for mne_bids.path

 
 
     @property
-    def fpath(self):
+    def fpath(self):
         """Full filepath for this BIDS file.
 
         Getting the file path consists of the entities passed in
@@ -1371,7 +1371,7 @@ 

Source code for mne_bids.path

 
 
[docs] - def update(self, *, check=None, **kwargs): + def update(self, *, check=None, **kwargs): """Update inplace BIDS entity key/value pairs in object. ``run`` and ``split`` are auto-converted to have two @@ -1506,7 +1506,7 @@

Source code for mne_bids.path

 
 
[docs] - def match(self, *, ignore_json=True, ignore_nosub=False, check=False): + def match(self, *, ignore_json=True, ignore_nosub=False, check=False): """Get a list of all matching paths in the root directory. Performs a recursive search, starting in ``.root`` (if set), based on @@ -1553,7 +1553,7 @@

Source code for mne_bids.path

         return bids_paths
- def _check(self): + def _check(self): """Deep check or not of the instance.""" self.basename # run basename to check validity of arguments @@ -1628,7 +1628,7 @@

Source code for mne_bids.path

 
[docs] @verbose - def find_empty_room(self, use_sidecar_only=False, *, verbose=None): + def find_empty_room(self, use_sidecar_only=False, *, verbose=None): """Find the corresponding empty-room file of an MEG recording. This will only work if the ``.root`` attribute of the @@ -1704,7 +1704,7 @@

Source code for mne_bids.path

 
 
[docs] - def get_empty_room_candidates(self): + def get_empty_room_candidates(self): """Get the list of empty-room candidates for the given file. Returns @@ -1722,7 +1722,7 @@

Source code for mne_bids.path

 
 
[docs] - def find_matching_sidecar(self, suffix=None, extension=None, *, on_error="raise"): + def find_matching_sidecar(self, suffix=None, extension=None, *, on_error="raise"): """Get the matching sidecar JSON path. Parameters @@ -1752,7 +1752,7 @@

Source code for mne_bids.path

 
 
     @property
-    def meg_calibration_fpath(self):
+    def meg_calibration_fpath(self):
         """Find the matching Elekta/Neuromag/MEGIN fine-calibration file.
 
         This requires that at least ``root`` and ``subject`` are set, and that
@@ -1784,7 +1784,7 @@ 

Source code for mne_bids.path

         return path
 
     @property
-    def meg_crosstalk_fpath(self):
+    def meg_crosstalk_fpath(self):
         """Find the matching Elekta/Neuromag/MEGIN crosstalk file.
 
         This requires that at least ``root`` and ``subject`` are set, and that
@@ -1817,7 +1817,7 @@ 

Source code for mne_bids.path

 
 
 
-def _get_matching_bidspaths_from_filesystem(bids_path):
+def _get_matching_bidspaths_from_filesystem(bids_path):
     """Get matching file paths for a BIDSPath.
 
     Assumes suffix and/or extension is not provided.
@@ -1861,7 +1861,7 @@ 

Source code for mne_bids.path

     return matching_paths
 
 
-def _check_non_sub_ses_entity(bids_path):
+def _check_non_sub_ses_entity(bids_path):
     """Check existence of non subject/session entities in BIDSPath."""
     if (
         bids_path.task
@@ -1876,7 +1876,7 @@ 

Source code for mne_bids.path

     return False
 
 
-def _print_lines_with_entry(file, entry, folder, is_tsv, line_numbers, outfile):
+def _print_lines_with_entry(file, entry, folder, is_tsv, line_numbers, outfile):
     """Print the lines that contain the entry.
 
     Parameters
@@ -1920,7 +1920,7 @@ 

Source code for mne_bids.path

             print(f"    {line}", file=outfile)
 
 
-def _truncate_tsv_line(line, lim=10):
+def _truncate_tsv_line(line, lim=10):
     """Truncate a line to the specified number of characters."""
     return "".join(
         [
@@ -1932,7 +1932,7 @@ 

Source code for mne_bids.path

 
 
[docs] -def search_folder_for_text( +def search_folder_for_text( entry, folder, extensions=(".json", ".tsv"), line_numbers=True, return_str=False ): """Find any particular string entry in the text files of a folder. @@ -1984,7 +1984,7 @@

Source code for mne_bids.path

 
 
 
-def _check_max_depth(max_depth):
+def _check_max_depth(max_depth):
     """Check that max depth is a proper input."""
     msg = "`max_depth` must be a positive integer or None"
     if not isinstance(max_depth, int | type(None)):
@@ -2000,7 +2000,7 @@ 

Source code for mne_bids.path