def _data_path(path=None):
    """Get path to local copy of PC18 dataset."""
    key = "PC18_DATASET_PATH"
    name = "PC18_DATASET_SLEEP"
    path = _get_path(path, key, name)
    subdirs = os.listdir(path)
    if "training" in subdirs or "test" in subdirs:  # the specified path is
        # already at the training and test folders level
        return path
    else:
        return op.join(path, "pc18-sleep-data")
Get path to local copy of PC18 dataset.
braindecode/datasets/sleep_physio_challe_18.py