Skip to content
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
3 changes: 2 additions & 1 deletion .github/workflows/docs.yml
Original file line number Diff line number Diff line change
Expand Up @@ -80,9 +80,10 @@ jobs:
run: |
python - <<'PY'
import whobpyt
from whobpyt.datasets.fetchers import fetch_egmomi2023, fetch_egmomi2025,fetch_egtmseeg, fetch_egismail2025
from whobpyt.datasets.fetchers import fetch_egmomi2023, fetch_egmomi2025, fetch_egtmseeg, fetch_egismail2025
fetch_egmomi2023()
fetch_egmomi2025()
fetch_egtmseeg()
fetch_egismail2025()
PY

Expand Down
4 changes: 2 additions & 2 deletions examples/eg__tmseeg.py
Original file line number Diff line number Diff line change
Expand Up @@ -25,7 +25,7 @@
from whobpyt.models.jansen_rit import JansenRitModel,JansenRitParams
from whobpyt.run import ModelFitting
from whobpyt.optimization.custom_cost_JR import CostsJR
from whobpyt.datasets.fetchers import fetch_momi2023
from whobpyt.datasets.fetchers import fetch_egtmseeg

# Python Packages used for processing and displaying given analytical data (supported for .mat and Google Drive files)
import numpy as np
Expand All @@ -43,7 +43,7 @@

# %%
# Download and load example data
data_dir = fetch_momi2023()
data_dir = fetch_egtmseeg()

# %%
# Load EEG data
Expand Down
13 changes: 5 additions & 8 deletions whobpyt/datasets/fetchers.py
Original file line number Diff line number Diff line change
Expand Up @@ -173,15 +173,12 @@ def fetch_egtmseeg(dest_folder=None, redownload=False):

# If the folder does not exist, create it and download the files
if not os.path.isdir(dest_folder):

os.makedirs(dest_folder)

os.makedirs(dest_folder)
os.chdir(dest_folder)

dlcode = osf_folder_url
pull_file(dlcode, file_name, download_method='wget')

os.chdir(cwd)
for file_code, file_name in files_dict.items():
dlcode = osf_url_pfx + '/' + file_code
pull_file(dlcode, file_name, download_method='wget')
os.chdir(cwd) # go back to where we started

return dest_folder

Expand Down