brainprep.utils.utils: Module that contains some utility functions.¶
Module that contains some utility functions.
Functions¶
|
Scan the folder containing a BIDS file and verify that the run entity associated with the file appears exactly once among all matching files. |
|
Coerce a value into a list when the expected type annotation indicates a list or tuple. |
|
Recursively convert values to pathlib.Path based on expected type annotations. |
|
Return the closest parent directory whose name matches target. |
Return the index of the first stack frame outside the |
|
|
Generate a deterministic identifier and a 5-digit short code from a filename. |
|
Parse BIDS entities and modality from a filename or path with validation. |
|
Infers the corresponding JSON sidecar file for a given NIfTI image file. |