Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Deprecated deep learning #666

Open
wants to merge 14 commits into
base: develop
Choose a base branch
from
Open
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
2 changes: 0 additions & 2 deletions docs/source/pipelines.rst
Original file line number Diff line number Diff line change
Expand Up @@ -44,5 +44,3 @@ Base & Utils
utils_deep_model.EEGNet
utils_deep_model.EEGNet_TC
utils_deep_model.TCN_block
utils_pytorch.BraindecodeDatasetLoader
utils_pytorch.InputShapeSetterEEG
1 change: 1 addition & 0 deletions docs/source/whats_new.rst
Original file line number Diff line number Diff line change
Expand Up @@ -27,6 +27,7 @@ Bugs

API changes
~~~~~~~~~~~
- Removing the braindecode module from inside moabb (:gh:`666` by `Bruno Aristimunha`_ )

Version - 1.1.1 (Stable - PyPi)
---------------------------------
Expand Down
24 changes: 0 additions & 24 deletions moabb/pipelines/__init__.py
Original file line number Diff line number Diff line change
Expand Up @@ -26,18 +26,11 @@ def __getattr__(name):
"EEGNet",
"TCN_block",
}
utils_pytorch_classes = {
"InputShapeSetterEEG",
"BraindecodeDatasetLoader",
"get_shape_from_baseconcat",
}

if name in deep_learning_classes and _check_if_tensorflow_installed():
return _import_class(name, ".deep_learning")
elif name in utils_deep_model_classes and _check_if_tensorflow_installed():
return _import_class(name, ".utils_deep_model")
elif name in utils_pytorch_classes and _check_if_braindecode_installed():
return _import_class(name, ".utils_pytorch")

raise AttributeError(f"Module '{__name__}' has no attribute '{name}'")

Expand Down Expand Up @@ -77,20 +70,3 @@ def _check_if_tensorflow_installed():
"\033[0m", # This resets the color back to normal
)
return False


def _check_if_braindecode_installed():
try:
import braindecode

return True
except ModuleNotFoundError:
warn(
"Braindecode is not installed. "
"You won't be able to use these braindecode functions if you "
"attempt to do so. \n"
"\033[94m" # This is the ANSI escape code for blue
"pip install braindecode"
"\033[0m", # This resets the color back to normal
)
return False
171 changes: 0 additions & 171 deletions moabb/pipelines/utils_pytorch.py

This file was deleted.

Loading
Loading