-
Notifications
You must be signed in to change notification settings - Fork 0
Commit
This commit does not belong to any branch on this repository, and may belong to a fork outside of the repository.
Merge pull request #6 from individual-brain-charting/fetch_raw_preproc
Fetching raw and preprocessed data is now possible. Also adds databases for all ibc datasets on ebrains with consistent columns/info
- Loading branch information
Showing
7 changed files
with
893 additions
and
614 deletions.
There are no files selected for viewing
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Original file line number | Diff line number | Diff line change |
---|---|---|
@@ -1,17 +1,17 @@ | ||
import ibc_api.utils as ibc | ||
|
||
# Returns a link that takes you to EBRAINS login page and stores an access token locally | ||
ibc.authenticate() | ||
|
||
# Fetch info on all available files | ||
# Load as a pandas dataframe and save as ibc_data/available_{data_type}.csv | ||
# Load as a pandas dataframe and save as ibc_data/available_{data_type}.csv | ||
db = ibc.get_info(data_type="volume_maps") | ||
|
||
# Keep statistic maps for sub-08, for task-Discount | ||
filtered_db = ibc.filter_data(db, subject_list=["sub-08"], task_list=["Discount"]) | ||
filtered_db = ibc.filter_data(db, subject_list=["08"], task_list=["Discount"]) | ||
|
||
# Authenticate with EBRAINS before downloading | ||
# Returns a link that takes you to EBRAINS login page and stores an access token locally | ||
ibc.authenticate() | ||
|
||
# Download all statistic maps for sub-08, task-Discount | ||
# Saved under ibc_data/resulting_smooth_maps/sub-08/task-Discount | ||
# Also creates ibc_data/downloaded_volume_maps.csv | ||
# which contains downloaded file paths and time of download | ||
downloaded_db = ibc.download_data(filtered_db, organise_by='task') | ||
# Download all statistic maps for sub-08, task-Discount | ||
# Also creates ibc_data/downloaded_volume_maps.csv | ||
# which contains local file paths and time of download | ||
downloaded_db = ibc.download_data(filtered_db) |
Oops, something went wrong.