Braindecode 1.5.0.dev172791986__tar.gz → 1.5.0.dev176208946__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (165) hide show
  1. {braindecode-1.5.0.dev172791986/braindecode.egg-info → braindecode-1.5.0.dev176208946}/PKG-INFO +1 -1
  2. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/__init__.py +1 -2
  3. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/bendr.py +28 -92
  4. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/summary.csv +0 -1
  5. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/util.py +1 -35
  6. braindecode-1.5.0.dev176208946/braindecode/version.py +1 -0
  7. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946/braindecode.egg-info}/PKG-INFO +1 -1
  8. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/api.rst +0 -1
  9. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/whats_new.rst +0 -19
  10. braindecode-1.5.0.dev172791986/braindecode/version.py +0 -1
  11. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/LICENSE.txt +0 -0
  12. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/MANIFEST.in +0 -0
  13. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/NOTICE.txt +0 -0
  14. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/README.rst +0 -0
  15. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/__init__.py +0 -0
  16. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/augmentation/__init__.py +0 -0
  17. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/augmentation/base.py +0 -0
  18. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/augmentation/functional.py +0 -0
  19. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/augmentation/transforms.py +0 -0
  20. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/classifier.py +0 -0
  21. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/__init__.py +0 -0
  22. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/base.py +0 -0
  23. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/bbci.py +0 -0
  24. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/bcicomp.py +0 -0
  25. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/bids/__init__.py +0 -0
  26. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/bids/datasets.py +0 -0
  27. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/bids/format.py +0 -0
  28. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/bids/hub.py +0 -0
  29. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/bids/hub_format.py +0 -0
  30. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/bids/hub_io.py +0 -0
  31. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/bids/hub_validation.py +0 -0
  32. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/bids/iterable.py +0 -0
  33. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/chb_mit.py +0 -0
  34. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/mne.py +0 -0
  35. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/moabb.py +0 -0
  36. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/nmt.py +0 -0
  37. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/registry.py +0 -0
  38. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/siena.py +0 -0
  39. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/sleep_physio_challe_18.py +0 -0
  40. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/sleep_physionet.py +0 -0
  41. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/tuh.py +0 -0
  42. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/utils.py +0 -0
  43. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datasets/xy.py +0 -0
  44. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datautil/__init__.py +0 -0
  45. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datautil/channel_utils.py +0 -0
  46. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datautil/hub_formats.py +0 -0
  47. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datautil/serialization.py +0 -0
  48. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/datautil/util.py +0 -0
  49. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/eegneuralnet.py +0 -0
  50. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/functional/__init__.py +0 -0
  51. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/functional/functions.py +0 -0
  52. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/functional/initialization.py +0 -0
  53. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/atcnet.py +0 -0
  54. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/attentionbasenet.py +0 -0
  55. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/attn_sleep.py +0 -0
  56. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/base.py +0 -0
  57. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/biot.py +0 -0
  58. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/brainmodule.py +0 -0
  59. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/cbramod.py +0 -0
  60. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/codebrain.py +0 -0
  61. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/config.py +0 -0
  62. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/contrawr.py +0 -0
  63. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/ctnet.py +0 -0
  64. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/deep4.py +0 -0
  65. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/deepsleepnet.py +0 -0
  66. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/dgcnn.py +0 -0
  67. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eegconformer.py +0 -0
  68. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eeginception_erp.py +0 -0
  69. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eeginception_mi.py +0 -0
  70. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eegitnet.py +0 -0
  71. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eegminer.py +0 -0
  72. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eegnet.py +0 -0
  73. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eegnex.py +0 -0
  74. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eegpt.py +0 -0
  75. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eegsimpleconv.py +0 -0
  76. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eegsym.py +0 -0
  77. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/eegtcnet.py +0 -0
  78. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/fbcnet.py +0 -0
  79. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/fblightconvnet.py +0 -0
  80. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/fbmsnet.py +0 -0
  81. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/hybrid.py +0 -0
  82. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/ifnet.py +0 -0
  83. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/interpolated.py +0 -0
  84. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/labram.py +0 -0
  85. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/luna.py +0 -0
  86. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/medformer.py +0 -0
  87. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/msvtnet.py +0 -0
  88. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/patchedtransformer.py +0 -0
  89. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/reve.py +0 -0
  90. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/sccnet.py +0 -0
  91. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/shallow_fbcsp.py +0 -0
  92. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/signal_jepa.py +0 -0
  93. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/sinc_shallow.py +0 -0
  94. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/sleep_stager_blanco_2020.py +0 -0
  95. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/sleep_stager_chambon_2018.py +0 -0
  96. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/sparcnet.py +0 -0
  97. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/sstdpn.py +0 -0
  98. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/syncnet.py +0 -0
  99. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/tcn.py +0 -0
  100. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/tidnet.py +0 -0
  101. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/tsinception.py +0 -0
  102. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/models/usleep.py +0 -0
  103. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/__init__.py +0 -0
  104. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/activation.py +0 -0
  105. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/attention.py +0 -0
  106. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/blocks.py +0 -0
  107. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/convolution.py +0 -0
  108. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/filter.py +0 -0
  109. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/interpolation.py +0 -0
  110. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/layers.py +0 -0
  111. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/linear.py +0 -0
  112. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/parametrization.py +0 -0
  113. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/stats.py +0 -0
  114. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/util.py +0 -0
  115. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/modules/wrapper.py +0 -0
  116. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/preprocessing/__init__.py +0 -0
  117. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/preprocessing/eegprep_preprocess.py +0 -0
  118. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/preprocessing/mne_preprocess.py +0 -0
  119. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/preprocessing/preprocess.py +0 -0
  120. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/preprocessing/util.py +0 -0
  121. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/preprocessing/windowers.py +0 -0
  122. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/regressor.py +0 -0
  123. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/samplers/__init__.py +0 -0
  124. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/samplers/base.py +0 -0
  125. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/samplers/ssl.py +0 -0
  126. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/training/__init__.py +0 -0
  127. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/training/callbacks.py +0 -0
  128. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/training/losses.py +0 -0
  129. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/training/scoring.py +0 -0
  130. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/util.py +0 -0
  131. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/visualization/__init__.py +0 -0
  132. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/visualization/confusion_matrices.py +0 -0
  133. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode/visualization/gradients.py +0 -0
  134. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode.egg-info/SOURCES.txt +0 -0
  135. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode.egg-info/dependency_links.txt +0 -0
  136. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode.egg-info/requires.txt +0 -0
  137. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/braindecode.egg-info/top_level.txt +0 -0
  138. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/Makefile +0 -0
  139. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/_templates/autosummary/class.rst +0 -0
  140. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/_templates/autosummary/class_in_subdir.rst +0 -0
  141. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/_templates/autosummary/function.rst +0 -0
  142. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/_templates/autosummary/function_in_subdir.rst +0 -0
  143. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/cite.rst +0 -0
  144. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/conf.py +0 -0
  145. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/help.rst +0 -0
  146. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/index.rst +0 -0
  147. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/install/install.rst +0 -0
  148. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/install/install_pip.rst +0 -0
  149. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/install/install_source.rst +0 -0
  150. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/categorization/attention.rst +0 -0
  151. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/categorization/channel.rst +0 -0
  152. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/categorization/convolution.rst +0 -0
  153. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/categorization/filterbank.rst +0 -0
  154. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/categorization/gnn.rst +0 -0
  155. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/categorization/interpretable.rst +0 -0
  156. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/categorization/lbm.rst +0 -0
  157. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/categorization/recurrent.rst +0 -0
  158. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/categorization/spd.rst +0 -0
  159. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/models.rst +0 -0
  160. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/models_categorization.rst +0 -0
  161. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/models_table.rst +0 -0
  162. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/models/models_visualization.rst +0 -0
  163. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/docs/sg_execution_times.rst +0 -0
  164. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/pyproject.toml +0 -0
  165. {braindecode-1.5.0.dev172791986 → braindecode-1.5.0.dev176208946}/setup.cfg +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: braindecode
3
- Version: 1.5.0.dev172791986
3
+ Version: 1.5.0.dev176208946
4
4
  Summary: Deep learning software to decode EEG, ECG or MEG signals
5
5
  Author-email: Robin Tibor Schirrmeister <robintibor@gmail.com>, Bruno Aristimunha Pinto <b.aristimunha@gmail.com>, Alexandre Gramfort <agramfort@meta.com>
6
6
  Maintainer-email: Alexandre Gramfort <agramfort@meta.com>, Bruno Aristimunha Pinto <b.aristimunha@gmail.com>, Robin Tibor Schirrmeister <robintibor@gmail.com>
@@ -4,7 +4,7 @@ from .atcnet import ATCNet
4
4
  from .attentionbasenet import AttentionBaseNet
5
5
  from .attn_sleep import AttnSleep
6
6
  from .base import EEGModuleMixin
7
- from .bendr import BENDR, InterpolatedBENDR
7
+ from .bendr import BENDR
8
8
  from .biot import BIOT, InterpolatedBIOT
9
9
  from .brainmodule import BrainModule
10
10
  from .cbramod import CBraMod
@@ -99,7 +99,6 @@ __all__ = [
99
99
  "FBMSNet",
100
100
  "HybridNet",
101
101
  "IFNet",
102
- "InterpolatedBENDR",
103
102
  "InterpolatedBIOT",
104
103
  "InterpolatedLaBraM",
105
104
  "InterpolatedModel",
@@ -1,60 +1,12 @@
1
1
  import copy
2
2
 
3
- import numpy as np
4
3
  import torch
5
4
  from einops.layers.torch import Rearrange
6
5
  from torch import nn
6
+ from torch.nn.utils.parametrize import register_parametrization
7
7
 
8
8
  from braindecode.models.base import EEGModuleMixin
9
-
10
- # The 20 channels used to pre-train BENDR, in the order expected by the
11
- # `braindecode/braindecode-bendr` checkpoint. The first 19 entries are the
12
- # EEG channels taken verbatim from `dn3.transforms.instance.To1020.EEG_20_div`
13
- # (https://github.com/SPOClab-ca/dn3/blob/master/dn3/transforms/instance.py).
14
- # Their positions come from MNE's ``standard_1005`` montage (T5/T6 are
15
- # legacy names that share positions with P7/P8 there).
16
- #
17
- # The 20th entry is ``SCALE``, a relative-amplitude statistic (not an
18
- # electrode) appended by ``To1020(include_scale_ch=True)`` during
19
- # pre-training. Since it has no physical position, the ``loc`` below is
20
- # the centroid of the 19 EEG positions — purely a placeholder so that
21
- # :class:`~braindecode.modules.ChannelInterpolationLayer` (used by
22
- # :class:`InterpolatedBENDR`) can build a valid spline interpolation
23
- # matrix. It is NOT the SCALE the pre-training pipeline computes
24
- # (which is an RMS-like amplitude via ``dn3.MappingDeep1010``); users
25
- # who need a faithful SCALE must compute it themselves and feed 20
26
- # channels to :class:`BENDR` directly.
27
- _BENDR_TARGET_CHS_TUPLES: list[tuple[str, tuple[float, float, float]]] = [
28
- ("FP1", (-0.0294367, +0.0839171, -0.0069900)), # standard_1005
29
- ("FP2", (+0.0298723, +0.0848959, -0.0070800)), # standard_1005
30
- ("F7", (-0.0702629, +0.0424743, -0.0114200)), # standard_1005
31
- ("F3", (-0.0502438, +0.0531112, +0.0421920)), # standard_1005
32
- ("FZ", (+0.0003122, +0.0585120, +0.0664620)), # standard_1005
33
- ("F4", (+0.0518362, +0.0543048, +0.0408140)), # standard_1005
34
- ("F8", (+0.0730431, +0.0444217, -0.0120000)), # standard_1005
35
- ("T7", (-0.0841611, -0.0160187, -0.0093460)), # standard_1005
36
- ("C3", (-0.0653581, -0.0116317, +0.0643580)), # standard_1005
37
- ("CZ", (+0.0004009, -0.0091670, +0.1002440)), # standard_1005
38
- ("C4", (+0.0671179, -0.0109003, +0.0635800)), # standard_1005
39
- ("T8", (+0.0850799, -0.0150203, -0.0094900)), # standard_1005
40
- ("T5", (-0.0724343, -0.0734527, -0.0024870)), # standard_1005 (= P7)
41
- ("P3", (-0.0530073, -0.0787878, +0.0559400)), # standard_1005
42
- ("PZ", (+0.0003247, -0.0811150, +0.0826150)), # standard_1005
43
- ("P4", (+0.0556667, -0.0785602, +0.0565610)), # standard_1005
44
- ("T6", (+0.0730557, -0.0730683, -0.0025400)), # standard_1005 (= P8)
45
- ("O1", (-0.0294134, -0.1124490, +0.0088390)), # standard_1005
46
- ("O2", (+0.0298426, -0.1121560, +0.0088000)), # standard_1005
47
- (
48
- "SCALE",
49
- (+0.0006439, -0.0131942, +0.0278448),
50
- ), # centroid of the 19 EEG positions (placeholder; see comment above)
51
- ]
52
-
53
- _BENDR_TARGET_CHS_INFO: list[dict] = [
54
- {"ch_name": ch, "kind": "eeg", "loc": np.asarray(loc, dtype=float)}
55
- for ch, loc in _BENDR_TARGET_CHS_TUPLES
56
- ]
57
- BENDR_CHANNEL_ORDER: list[str] = [ch for ch, _ in _BENDR_TARGET_CHS_TUPLES]
9
+ from braindecode.modules.parametrization import MaxNormParametrize
58
10
 
59
11
 
60
12
  class BENDR(EEGModuleMixin, nn.Module):
@@ -243,6 +195,15 @@ class BENDR(EEGModuleMixin, nn.Module):
243
195
  The contextualizer is still created (to allow loading pretrained weights) but is not
244
196
  used in the forward pass. Requires input length of at least
245
197
  ``4 * product(enc_downsample)`` samples (384 with default downsampling of 96x).
198
+ n_chans_pretrained : int or None, default=None
199
+ Number of input channels the pretrained weights expect (20 for the official BENDR
200
+ checkpoint). When set and ``n_chans != n_chans_pretrained``, a 1x1 Conv1d with
201
+ max-norm constraint projects from ``n_chans`` to ``n_chans_pretrained`` before the
202
+ encoder. This allows fine-tuning pretrained BENDR on datasets with arbitrary channel
203
+ counts. When using ``from_pretrained``, pass ``strict=False`` since the checkpoint
204
+ will not contain ``channel_projection`` weights.
205
+ chan_proj_max_norm : float, default=1.0
206
+ Max-norm constraint value for the channel projection weights.
246
207
  """
247
208
 
248
209
  def __init__(
@@ -270,6 +231,8 @@ class BENDR(EEGModuleMixin, nn.Module):
270
231
  start_token=-5, # Value for start token embedding
271
232
  final_layer=True, # Whether to include the final linear layer
272
233
  encoder_only=False, # If True, bypass contextualizer and use 4-chunk pooling
234
+ n_chans_pretrained=None, # Expected input channels of pretrained weights
235
+ chan_proj_max_norm=1.0, # Max-norm for channel projection weights
273
236
  ):
274
237
  super().__init__(
275
238
  n_outputs=n_outputs,
@@ -283,34 +246,25 @@ class BENDR(EEGModuleMixin, nn.Module):
283
246
  # Keep these parameters if needed later, otherwise they are captured by the mixin
284
247
  del n_outputs, n_chans, chs_info, n_times, input_window_seconds, sfreq
285
248
 
286
- # If the user supplies chs_info, require it to match BENDR_CHANNEL_ORDER
287
- # exactly (case-insensitive). Arbitrary channel sets should go through
288
- # InterpolatedBENDR — same pattern as Labram / InterpolatedLaBraM.
289
- # When chs_info is absent (the usual n_chans=20 path, incl.
290
- # from_pretrained), no check is performed.
291
- try:
292
- _chs_info = self.chs_info
293
- except ValueError:
294
- _chs_info = None
295
- if _chs_info is not None:
296
- user_names = [ch["ch_name"] for ch in _chs_info] # type: ignore[index]
297
- canonical = BENDR_CHANNEL_ORDER
298
- if [n.lower() for n in user_names] != [n.lower() for n in canonical]:
299
- raise ValueError(
300
- f"BENDR requires chs_info to match BENDR_CHANNEL_ORDER exactly "
301
- f"({len(canonical)} channels, specific order; last is 'SCALE'). "
302
- f"Got {len(user_names)} channel(s). For arbitrary channel sets, "
303
- f"use InterpolatedBENDR "
304
- f"(from braindecode.models import InterpolatedBENDR)."
305
- )
306
-
307
249
  self.encoder_h = encoder_h
308
250
  self.contextualizer_hidden = contextualizer_hidden
309
251
  self.include_final_layer = final_layer
310
252
  self.encoder_only = encoder_only
311
253
 
254
+ # Channel projection for pretrained weight compatibility
255
+ encoder_n_chans = self.n_chans
256
+ if n_chans_pretrained is not None and self.n_chans != n_chans_pretrained:
257
+ conv = nn.Conv1d(self.n_chans, n_chans_pretrained, 1, bias=False)
258
+ register_parametrization(
259
+ conv, "weight", MaxNormParametrize(chan_proj_max_norm)
260
+ )
261
+ self.channel_projection = conv
262
+ encoder_n_chans = n_chans_pretrained
263
+ else:
264
+ self.channel_projection = None
265
+
312
266
  self.encoder = _ConvEncoderBENDR(
313
- in_features=self.n_chans,
267
+ in_features=encoder_n_chans,
314
268
  encoder_h=encoder_h,
315
269
  dropout=drop_prob,
316
270
  projection_head=projection_head,
@@ -354,6 +308,8 @@ class BENDR(EEGModuleMixin, nn.Module):
354
308
  self._build_head(n_outputs)
355
309
 
356
310
  def forward(self, x, return_features=False):
311
+ if self.channel_projection is not None:
312
+ x = self.channel_projection(x)
357
313
  encoded = self.encoder(x)
358
314
  # encoded: [batch_size, encoder_h, n_encoded_times]
359
315
 
@@ -596,23 +552,3 @@ class _BENDRContextualizer(nn.Module):
596
552
  # x: [batch_size, in_features, seq_len + 1]
597
553
 
598
554
  return x
599
-
600
-
601
- # -----------------------------------------------------------------------------
602
- # InterpolatedBENDR — experimental channel-interpolation variant of BENDR
603
- # -----------------------------------------------------------------------------
604
- # Wraps :class:`BENDR` with an MNE-backed channel-interpolation layer that
605
- # projects arbitrary user ``chs_info`` to the canonical 20-channel BENDR
606
- # input (:data:`_BENDR_TARGET_CHS_INFO` — the 19 pre-training EEG channels
607
- # plus a ``SCALE`` placeholder at the centroid of those 19 positions).
608
- # Frozen by default; set ``trainable=True`` to fine-tune the projection.
609
- #
610
- # NOTE: the ``SCALE`` target has no physical position, so the row of the
611
- # interpolation matrix that produces it is a spatial spline of the user's
612
- # EEG channels — *not* the dn3 ``MappingDeep1010`` RMS statistic the
613
- # checkpoint saw during pre-training. Expect degraded zero-shot transfer
614
- # from the SCALE channel; downstream fine-tuning should still work.
615
-
616
- from braindecode.models.interpolated import InterpolatedModel # noqa: E402
617
-
618
- InterpolatedBENDR = InterpolatedModel(BENDR, _BENDR_TARGET_CHS_INFO)
@@ -49,7 +49,6 @@ LUNA,General,"Classification,Embedding",128,"n_chans, n_times, sfreq, chs_info",
49
49
  MEDFormer,General,Classification,250,"n_chans, n_outputs, n_times",5313924,"MEDFormer(n_chans=22, n_outputs=4, n_times=1000)","Foundation Model,Convolution"
50
50
  REVE,General,Classification,200,"n_outputs, n_times, n_chans",69481476,"REVE(n_times=1000, n_outputs=4, n_chans=19)","Foundation Model,Attention/Transformer"
51
51
  DGCNN,Emotion Recognition,Classification,128,"n_chans, n_outputs, n_times, chs_info",1037385,"DGCNN(n_chans=62, n_outputs=4, n_times=128)","Graph Neural Network,Channel"
52
- InterpolatedBENDR,General,"Classification,Embedding",250,"chs_info, n_outputs, n_times",157143101,"InterpolatedBENDR(chs_info=<user>, n_outputs=4, n_times=1000)","Foundation Model,Convolution,Channel"
53
52
  InterpolatedBIOT,"Sleep Staging, Epilepsy",Classification,200,"chs_info, n_outputs, n_times, sfreq",3184101,"InterpolatedBIOT(chs_info=<user>, n_outputs=5, sfreq=200, n_times=6000)","Foundation Model,Channel"
54
53
  InterpolatedLaBraM,General,"Classification, Embedding",200,"chs_info, n_outputs, n_times",5866196,"InterpolatedLaBraM(chs_info=<user>, n_outputs=4, n_times=1000)","Convolution,Foundation Model,Channel"
55
54
  InterpolatedSignalJEPA,"Motor Imagery, ERP, SSVEP",Embedding,128,"chs_info",3456882,"InterpolatedSignalJEPA(chs_info=<user>)","Convolution,Channel,Foundation Model"
@@ -240,28 +240,6 @@ def _get_labram_chs_info() -> list[dict]:
240
240
  return result
241
241
 
242
242
 
243
- def _get_bendr_chs_info() -> list[dict]:
244
- """Return the 20-channel canonical chs_info for BENDR with 12-element locs.
245
-
246
- Same lazy-import rationale as :func:`_get_labram_chs_info`. The last entry
247
- is the ``SCALE`` amplitude-statistic placeholder (see
248
- ``braindecode.models.bendr``).
249
- """
250
- import numpy as np
251
-
252
- from braindecode.models.bendr import _BENDR_TARGET_CHS_INFO
253
-
254
- result = []
255
- for ch in _BENDR_TARGET_CHS_INFO:
256
- loc3 = np.asarray(ch["loc"], dtype=float)
257
- loc12 = np.zeros(12, dtype=float)
258
- loc12[:3] = loc3[:3]
259
- result.append(
260
- {"ch_name": ch["ch_name"], "kind": ch["kind"], "loc": loc12.tolist()}
261
- )
262
- return result
263
-
264
-
265
243
  models_mandatory_parameters: list[
266
244
  tuple[str, list[SigArgName], dict[SigArgName, Any] | None | Any]
267
245
  ] = [
@@ -341,19 +319,7 @@ models_mandatory_parameters: list[
341
319
  ("PBT", ["n_chans", "n_outputs", "n_times"], None),
342
320
  ("SSTDPN", ["n_chans", "n_outputs", "n_times", "sfreq"], None),
343
321
  ("BrainModule", ["n_chans", "n_outputs", "n_times", "sfreq"], None),
344
- (
345
- "BENDR",
346
- ["n_chans", "n_outputs", "n_times"],
347
- # Callable: BENDR now requires chs_info to match BENDR_CHANNEL_ORDER
348
- # when supplied; deferred to avoid a circular import (util.py is loaded
349
- # by base.py before bendr.py).
350
- lambda: {"chs_info": _get_bendr_chs_info()},
351
- ),
352
- (
353
- "InterpolatedBENDR",
354
- ["chs_info", "n_outputs", "n_times"],
355
- {"chs_info": _chs_info_4ch}, # MNE interpolation needs >=4 channels
356
- ),
322
+ ("BENDR", ["n_chans", "n_outputs", "n_times"], None),
357
323
  ("LUNA", ["n_chans", "n_times", "n_outputs"], None),
358
324
  ("MEDFormer", ["n_chans", "n_outputs", "n_times"], None),
359
325
  (
@@ -0,0 +1 @@
1
+ __version__ = "1.5.0.dev176208946"
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: braindecode
3
- Version: 1.5.0.dev172791986
3
+ Version: 1.5.0.dev176208946
4
4
  Summary: Deep learning software to decode EEG, ECG or MEG signals
5
5
  Author-email: Robin Tibor Schirrmeister <robintibor@gmail.com>, Bruno Aristimunha Pinto <b.aristimunha@gmail.com>, Alexandre Gramfort <agramfort@meta.com>
6
6
  Maintainer-email: Alexandre Gramfort <agramfort@meta.com>, Bruno Aristimunha Pinto <b.aristimunha@gmail.com>, Robin Tibor Schirrmeister <robintibor@gmail.com>
@@ -157,7 +157,6 @@ interface for all EEG models and can derive variable names when needed.
157
157
  FBLightConvNet
158
158
  FBMSNet
159
159
  IFNet
160
- InterpolatedBENDR
161
160
  InterpolatedBIOT
162
161
  InterpolatedLaBraM
163
162
  InterpolatedModel
@@ -48,14 +48,6 @@ Enhancements
48
48
  :class:`braindecode.models.InterpolatedSignalJEPA`, and
49
49
  :class:`braindecode.models.InterpolatedBIOT` for the corresponding
50
50
  pre-trained models. (:gh:`993` by `Pierre Guetschel`_)
51
- - Add a tutorial walking through the experimental ``Interpolated*`` family
52
- (:ref:`channel-interpolation-tutorial`): failure mode of the vanilla
53
- backbones on non-canonical channel sets, one-line fix via
54
- :class:`braindecode.models.InterpolatedLaBraM` /
55
- :class:`braindecode.models.InterpolatedBIOT` /
56
- :class:`braindecode.models.InterpolatedSignalJEPA`, side-by-side
57
- visualisation of the ``name_match`` vs ``always`` interpolation matrices,
58
- and the ``trainable=True`` flag. (:gh:`994` by `Pierre Guetschel`_)
59
51
  - Mark deterministic index buffers (:class:`braindecode.models.BIOT` encoder's
60
52
  ``index`` and :class:`braindecode.models.REVE`'s position ``embedding`` bank)
61
53
  as non-persistent. They are rebuilt from ``__init__`` arguments on every
@@ -70,17 +62,6 @@ API and behavior changes
70
62
  convention: boolean masks use ``True`` to **ignore** a position (previously
71
63
  ``True`` meant keep). The scaling factor is now ``1/sqrt(head_dim)`` instead of
72
64
  ``1/sqrt(emb_size)``. (:gh:`902`)
73
- - :class:`braindecode.models.BENDR`: remove the ``n_chans_pretrained`` /
74
- ``chan_proj_max_norm`` parameters and the ``channel_projection`` layer; hard-code
75
- the 20 pre-training channels as ``_BENDR_TARGET_CHS_TUPLES``. The official
76
- ``braindecode/braindecode-bendr`` checkpoint has been re-uploaded flat so
77
- ``from_pretrained`` now loads its 99 weights (previously 0 of 99 matched
78
- silently). Also ships :class:`braindecode.models.InterpolatedBENDR`, the
79
- :func:`~braindecode.models.InterpolatedModel` wrapper that accepts arbitrary
80
- user ``chs_info`` and projects to the canonical 20 BENDR channels (the
81
- ``SCALE`` target has no physical position, so its interpolation row is a
82
- spatial spline of the user's EEG — not the dn3 amplitude statistic).
83
- (:gh:`992` by `Pierre Guetschel`_)
84
65
  - :class:`braindecode.models.Labram` now requires ``chs_info`` to match
85
66
  ``LABRAM_CHANNEL_ORDER`` exactly (128 channels, canonical order). The
86
67
  ``on_unknown_chs`` parameter and the forward-time ``ch_names`` argument are
@@ -1 +0,0 @@
1
- __version__ = "1.5.0.dev172791986"