Skip to content

PhysioNet eegmmidb downloads stall/timeout for PhysionetMI — document s3://physionet-open + s5cmd fast lane #1245

Closed

Description

@bruAristimunha

Problem: PhysioNet eegmmidb downloads stall / timeout, blocking PhysionetMI

In a large MOABB rerun (MI LHRH/RHF/ALL, 109 subjects x 14 runs), PhysionetMI downloads from https://physionet.org/files/eegmmidb/1.0.0/ are the long pole:

  • throughput 10-40 kB/s per file (2.6 MB EDFs taking minutes each)
  • frequent requests.exceptions.ConnectionError: HTTPSConnectionPool(host='physionet.org', port=443): Read timed out at 50-90% of file
  • pooch (MNE data_dl) does not resume, so each timeout restarts the file from zero
  • 109 subjects x ~8 runs needed for MI tasks = days at this rate; 6+ warm/ML Jobs died on this in our campaign

Log sample (Voyager, MOABB 1.8.0dev0, PhysionetMI via data_dl):

Downloading data from 'https://physionet.org/files/eegmmidb/1.0.0/S065/S065R08.edf' ...
  33%|...| 868k/2.60M [00:41<01:56, 14.9kB/s]
  ...
requests.exceptions.ConnectionError: HTTPSConnectionPool(host='physionet.org', port=443): Read timed out.

Related: #1084 (nemar-py re-host). PhysionetMI.nemar_id = "on004362" publishes no sourcedata manifest, so NEMAR-first (MOABB_DOWNLOAD_PROVIDER=auto) falls back to upstream for this dataset.

Fast lane that works: s3://physionet-open + s5cmd

The AWS Open Data mirror is byte-identical EDFs in the same layout MNE expects:

  • s3://physionet-open/eegmmidb/1.0.0/S001/S001R01.edf (+ .event) — 3059 objects total
  • destination MNE-eegbci-data/files/eegmmidb/1.0.0/S001/S001R01.edf — exact match, pooch then sees files as complete and skips re-download

One Job with 256 workers:

s5cmd --no-sign-request sync --size-only \
  "s3://physionet-open/eegmmidb/1.0.0/*" \
  $MNE_DATA/MNE-eegbci-data/files/eegmmidb/1.0.0/

This saturated the link where physionet.org gave 10-40 kB/s. Note: OpenNeuro ds004362 is BIDS .set, NOT drop-in for the current loader — physionet-open is the one to use.

Proposal

  1. Document the S3 fast lane for PhysionetMI (and other physionet-hosted sets) in docs + dataset docstring
  2. Optionally: PhysionetMI (and data_dl generally) tries s3://physionet-open mirror first / falls back to https://physionet.org, or a MOABB_S3_MIRROR=1 env flag that pre-seeds via s5cmd/aws-cli when available
  3. Long term: NEMAR sourcedata for on004362 (see Update moabb to use nemar-py as we finish to re-host the datasets #1084) would make this moot for provider=auto/nemar

Environment

  • MOABB 1.8.0dev0 (f88fb85), mne 1.13.2, sklearn 1.9.1, pyriemann 0.12
  • Voyager Kubernetes, group Ceph, s5cmd v2.2.2, aws-cli/2.37.9
  • Campaign: MOABB paper resubmission rerun (MI LHRH/RHF/ALL + SSVEP, EA normalization)

Happy to PR the docs + optional mirror flag if maintainers agree on approach.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions