moabb.set_download_provider#

moabb.set_download_provider(provider)[source]#

Choose where MOABB fetches dataset files from.

Many datasets are mirrored on NEMAR, which also republishes the original pre-BIDS distribution under sourcedata/. Pinning the provider to "nemar" makes downloads reproducible and immune to upstream hosts that are slow, rate-limited, behind a bot gate, or retired – at the cost of failing outright, rather than silently falling back, when NEMAR cannot serve a dataset.

The provider governs where download() fetches from; loading then serves files from the fetched NEMAR store before the URL-derived layout (pinning "upstream" opts loading out as well).

Parameters:

provider (str | None) – One of "auto" (default), "nemar", or "upstream". Passing None restores the default.

Raises:

ValueError – If provider is not a recognised value.

Notes

The choice is stored in the MNE config as MOABB_DOWNLOAD_PROVIDER and can also be set for a single run via the environment variable of the same name, which takes precedence.