Data
module for loading fMRI data and features and the like
load_fmri(story, subject)
Load fMRI data. Return ndarray with shape [time, voxels].
Source code in src/encoders/data.py
249 250 251 252 253 254 255 256 257 258 259 260 261 |
|
load_textgrid(story)
Loads {story}.TextGrid from 'ds003020/derivative/TextGrids' folder.
Parameters:
Name | Type | Description | Default |
---|---|---|---|
|
str
|
Story to load |
required |
Returns:
Type | Description |
---|---|
dict
|
Dictionary with keys 'phone' and 'word', each containing a dataframe with phone and word onset times, respectfully. |
Source code in src/encoders/data.py
222 223 224 225 226 227 228 229 230 231 232 233 234 235 236 237 238 239 240 241 242 243 244 245 246 |
|
load_wav(story)
Load wav file. Return ndarray with shape [samples, channels].
Source code in src/encoders/data.py
30 31 32 33 34 35 36 37 38 39 40 41 |
|