|
845 | 845 |
|
846 | 846 | # BIDS Validator
|
847 | 847 |
|
| 848 | +.boxed-content[ |
848 | 849 | The machine-readable structure makes validation possible:
|
849 | 850 |
|
850 |
| -```bash |
851 |
| -$ deno run -A jsr:@bids/validator /data/bids/openneuro/ds000228 |
852 |
| - [WARNING] JSON_KEY_RECOMMENDED A JSON file is missing a key listed as recommended. |
853 |
| - DatasetType |
854 |
| - /dataset_description.json |
| 851 | +``` bash |
| 852 | +$ bids-validator . |
| 853 | + |
| 854 | + |
| 855 | + 1: [WARN] The recommended file /README is very small. Please consider expanding it with additional information about the dataset. (code: 213 - README_FILE_SMALL) |
| 856 | + ./README |
| 857 | + |
| 858 | + Please visit https://neurostars.org/search?q=README_FILE_SMALL for existing conversations about this issue. |
| 859 | + |
| 860 | + Summary: Available Tasks: Available Modalities: |
| 861 | + 96 Files, 6.63GB Mixed-stimuli, positive-control task MRI |
| 862 | + 5 - Subjects Resting-state fMRI |
| 863 | + 1 - Session |
| 864 | + |
| 865 | + |
| 866 | + If you have any questions, please post on https://neurostars.org/tags/bids. |
| 867 | +``` |
| 868 | + |
| 869 | +.center[ |
| 870 | +## https://bids-standard.github.io/bids-validator/ |
| 871 | +]] |
| 872 | + |
| 873 | +--- |
| 874 | + |
| 875 | +# BIDS Validator |
| 876 | + |
| 877 | +.boxed-content[ |
| 878 | +Once all warnings and errors are addressed: |
| 879 | + |
| 880 | +``` bash |
| 881 | +$ bids-validator . |
| 882 | + |
855 | 883 |
|
856 |
| - GeneratedBy |
857 |
| - /dataset_description.json |
| 884 | +This dataset appears to be BIDS compatible. |
| 885 | + Summary: Available Tasks: Available Modalities: |
| 886 | + 96 Files, 6.63GB Mixed-stimuli, positive-control task MRI |
| 887 | + 5 - Subjects Resting-state fMRI |
| 888 | + 1 - Session |
858 | 889 |
|
859 |
| - SourceDatasets |
860 |
| - /dataset_description.json |
861 | 890 |
|
862 |
| - Please visit https://neurostars.org/search?q=JSON_KEY_RECOMMENDED for existing |
863 |
| - conversations about this issue. |
864 |
| -... |
| 891 | + If you have any questions, please post on https://neurostars.org/tags/bids. |
865 | 892 | ```
|
866 | 893 |
|
867 | 894 | .center[
|
868 | 895 | ## https://bids-standard.github.io/bids-validator/
|
| 896 | +]] |
| 897 | + |
| 898 | +--- |
| 899 | + |
| 900 | +# Sharing through OpenNeuro |
| 901 | + |
| 902 | +.boxed-content[ |
| 903 | +.center[[https://openneuro.org/datasets/ds005454/versions/1.0.0](https://openneuro.org/datasets/ds005454/versions/1.0.0)] |
| 904 | + |
| 905 | +<iframe src="https://openneuro.org/datasets/ds005454/versions/1.0.0" width="100%" height="500px" style="border: 0" /> |
869 | 906 | ]
|
870 | 907 |
|
871 | 908 | ---
|
|
876 | 913 | # BIDS Applications
|
877 | 914 |
|
878 | 915 | ---
|
879 |
| - |
880 | 916 | A common specification of neuroimaging datasets affords queries for and
|
881 | 917 | adaptation to the available data.
|
882 |
| - |
883 | 918 | --
|
884 |
| - |
| 919 | +.boxed-content[ |
885 | 920 | Queryable (meta)data allows a very simple protocol for a
|
886 | 921 | [BIDS App](https://bids-apps.neuroimaging.io/apps/):
|
887 | 922 |
|
|
892 | 927 | .footnote[
|
893 | 928 | \* Note that `participant` is an analysis level. Apps may also operate
|
894 | 929 | at the `run`, `session` or `group` levels.
|
895 |
| -] |
| 930 | +]] |
896 | 931 |
|
897 | 932 | --
|
898 | 933 |
|
| 934 | +.boxed-content[ |
899 | 935 | ## Examples
|
900 | 936 |
|
901 | 937 | **MRIQC**
|
902 | 938 |
|
903 | 939 | ```Bash
|
904 | 940 | mriqc /data/bids/openneuro/ds000228 /data/processed/ds000228-mriqc group
|
905 | 941 | ```
|
906 |
| - |
| 942 | +] |
907 | 943 | --
|
908 | 944 |
|
| 945 | +.boxed-content[ |
909 | 946 | **fMRIPrep**
|
910 | 947 |
|
911 | 948 | ```Bash
|
912 | 949 | fmriprep /data/bids/openneuro/ds000228 /data/processed/ds000228-fmriprep \
|
913 | 950 | participant --participant-label pixar001
|
914 | 951 | ```
|
915 |
| - |
| 952 | +] |
916 | 953 | ---
|
917 | 954 |
|
918 | 955 | .pull-left[
|
|
1071 | 1108 |
|
1072 | 1109 | # PyBIDS
|
1073 | 1110 |
|
| 1111 | +.boxed-content[ |
1074 | 1112 | A common specification of neuroimaging datasets affords queries for and
|
1075 | 1113 | adaptation to the available data.
|
1076 | 1114 |
|
|
1094 | 1132 | 'suffix': 'bold',
|
1095 | 1133 | 'task': 'rest'}
|
1096 | 1134 | ```
|
1097 |
| - |
| 1135 | +] |
1098 | 1136 | ---
|
1099 | 1137 |
|
1100 |
| -# PyBIDS - Derivatives |
| 1138 | +# PyBIDS | Derivatives |
1101 | 1139 |
|
| 1140 | +.boxed-content[ |
1102 | 1141 | PyBIDS layouts support BIDS derivatives:
|
1103 | 1142 |
|
1104 | 1143 | ```Python
|
1105 |
| ->>> fmri_derivs = BIDSLayout('/my_dataset-fmriprep', config=['bids', 'derivatives'], validate=False) |
| 1144 | +>>> fmri_derivs = BIDSLayout( |
| 1145 | +... '/my_dataset-fmriprep', |
| 1146 | +... config=['bids', 'derivatives'], |
| 1147 | +... validate=False, |
| 1148 | +... ) |
1106 | 1149 | >>> spaces = fmri_derivs.get_spaces(desc='preproc', suffix='bold')
|
1107 | 1150 | >>> spaces
|
1108 | 1151 | ['MNI152NLin2009cAsym']
|
1109 | 1152 | ```
|
1110 |
| - |
| 1153 | +] |
1111 | 1154 | --
|
1112 | 1155 |
|
| 1156 | +.boxed-content[ |
1113 | 1157 | It is also possible to provide your own config:
|
1114 | 1158 |
|
1115 | 1159 | ```Python
|
1116 | 1160 | >>> import niworkflows
|
1117 | 1161 | >>> nipreps_config = niworkflows.data.load('nipreps.json')
|
1118 |
| ->>> fmri_derivs = BIDSLayout('/my_dataset-fmriprep, config=[nipreps_config], validate=False) |
| 1162 | +>>> fmri_derivs = BIDSLayout('/my_dataset-fmriprep', config=[nipreps_config], validate=False) |
| 1163 | +``` |
| 1164 | +] |
| 1165 | +--- |
| 1166 | + |
| 1167 | +# PyBIDS | Large datasets |
| 1168 | + |
| 1169 | +.boxed-content[ |
| 1170 | +<br /> |
| 1171 | +.larger[*BIDS Apps* can spend long time indexing if they rely on *PyBIDS* ] |
| 1172 | +.no-bullet[ |
| 1173 | +* <i class="fa-solid fa-circle-right"></i> **create a cache**: |
| 1174 | +] |
| 1175 | + |
| 1176 | +```Bash |
| 1177 | +$ pybids layout --reset-db --no-validate --index-metadata . /my_dataset/.bids-index/ |
1119 | 1178 | ```
|
1120 | 1179 |
|
| 1180 | +.larger[And then inform your *BIDS App*.] |
| 1181 | + |
| 1182 | +<br /> |
| 1183 | + |
| 1184 | +In the case of *MRIQC* and *fMRIPrep*, point the `--bids-database-dir` argument to the newly created cache: |
| 1185 | + |
| 1186 | +```Bash |
| 1187 | +$ mriqc /data/input /derivatives/output participant [OPTIONS] \ |
| 1188 | + --bids-database-dir /my_dataset/.bids-index/ |
| 1189 | +``` |
| 1190 | + |
| 1191 | +```Bash |
| 1192 | +$ fmriprep /data/input /derivatives/output participant [OPTIONS] \ |
| 1193 | + --bids-database-dir /my_dataset/.bids-index/ |
| 1194 | +``` |
| 1195 | + |
| 1196 | +] |
| 1197 | + |
1121 | 1198 | ---
|
| 1199 | + |
1122 | 1200 | template: newsection
|
1123 | 1201 |
|
1124 | 1202 | # Conclusion
|
|
0 commit comments