py-neuromodulation 0.0.7__tar.gz → 0.1.0__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 (318) hide show
  1. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/.github/workflows/docs_pages.yml +2 -2
  2. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/.gitignore +17 -3
  3. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/PKG-INFO +18 -4
  4. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/README.rst +2 -0
  5. py_neuromodulation-0.1.0/docs/source/RMAP.rst +8 -0
  6. py_neuromodulation-0.1.0/docs/source/_static/Screenshot 2025-03-05 at 13.30.42.png +0 -0
  7. py_neuromodulation-0.1.0/docs/source/_static/Screenshot 2025-03-05 at 13.35.25.png +0 -0
  8. py_neuromodulation-0.1.0/docs/source/_static/channelselection.png +0 -0
  9. py_neuromodulation-0.1.0/docs/source/_static/decoding.png +0 -0
  10. py_neuromodulation-0.1.0/docs/source/_static/fileselection.png +0 -0
  11. py_neuromodulation-0.1.0/docs/source/_static/graphs.png +0 -0
  12. py_neuromodulation-0.1.0/docs/source/_static/lslselection.png +0 -0
  13. py_neuromodulation-0.1.0/docs/source/_static/pydantic.png +0 -0
  14. py_neuromodulation-0.1.0/docs/source/_static/settings.png +0 -0
  15. py_neuromodulation-0.1.0/docs/source/_static/sourceselection.png +0 -0
  16. py_neuromodulation-0.1.0/docs/source/api_documentation.rst +84 -0
  17. py_neuromodulation-0.1.0/docs/source/artifacts.rst +5 -0
  18. py_neuromodulation-0.1.0/docs/source/bandpower.rst +5 -0
  19. py_neuromodulation-0.1.0/docs/source/bispectra.rst +5 -0
  20. py_neuromodulation-0.1.0/docs/source/bursts.rst +5 -0
  21. py_neuromodulation-0.1.0/docs/source/channels.rst +5 -0
  22. py_neuromodulation-0.1.0/docs/source/coherence.rst +5 -0
  23. py_neuromodulation-0.1.0/docs/source/contributing.rst +87 -0
  24. py_neuromodulation-0.1.0/docs/source/database.rst +5 -0
  25. py_neuromodulation-0.1.0/docs/source/decode.rst +5 -0
  26. py_neuromodulation-0.1.0/docs/source/feature_reader.rst +5 -0
  27. py_neuromodulation-0.1.0/docs/source/fooof.rst +5 -0
  28. py_neuromodulation-0.1.0/docs/source/generator.rst +5 -0
  29. py_neuromodulation-0.1.0/docs/source/gui.rst +112 -0
  30. py_neuromodulation-0.1.0/docs/source/hjorth.rst +5 -0
  31. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/source/index.rst +1 -0
  32. py_neuromodulation-0.1.0/docs/source/io.rst +5 -0
  33. py_neuromodulation-0.1.0/docs/source/linelength.rst +5 -0
  34. py_neuromodulation-0.1.0/docs/source/logging.rst +5 -0
  35. py_neuromodulation-0.1.0/docs/source/mne_connectivity.rst +5 -0
  36. py_neuromodulation-0.1.0/docs/source/mne_filter.rst +5 -0
  37. py_neuromodulation-0.1.0/docs/source/mnelsl_player.rst +5 -0
  38. py_neuromodulation-0.1.0/docs/source/mnelsl_stream.rst +5 -0
  39. py_neuromodulation-0.1.0/docs/source/nolds.rst +5 -0
  40. py_neuromodulation-0.1.0/docs/source/normalization.rst +5 -0
  41. py_neuromodulation-0.1.0/docs/source/notch_filter.rst +5 -0
  42. py_neuromodulation-0.1.0/docs/source/oscillatory.rst +11 -0
  43. py_neuromodulation-0.1.0/docs/source/plots.rst +5 -0
  44. py_neuromodulation-0.1.0/docs/source/projection.rst +5 -0
  45. py_neuromodulation-0.1.0/docs/source/rereference.rst +5 -0
  46. py_neuromodulation-0.1.0/docs/source/resample.rst +5 -0
  47. py_neuromodulation-0.1.0/docs/source/settings.rst +5 -0
  48. py_neuromodulation-0.1.0/docs/source/sharpwaves.rst +5 -0
  49. py_neuromodulation-0.1.0/docs/source/stats.rst +5 -0
  50. py_neuromodulation-0.1.0/docs/source/stream.rst +5 -0
  51. py_neuromodulation-0.1.0/docs/source/types.rst +5 -0
  52. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/source/usage.rst +1 -1
  53. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/examples/plot_2_example_add_feature.py +11 -13
  54. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/examples/plot_4_example_gridPointProjection.py +1 -1
  55. py_neuromodulation-0.1.0/examples/plot_7_lsl_example.py +129 -0
  56. py_neuromodulation-0.1.0/gui_dev/.eslintrc.cjs +21 -0
  57. py_neuromodulation-0.1.0/gui_dev/.gitattributes +3 -0
  58. py_neuromodulation-0.1.0/gui_dev/.gitignore +21 -0
  59. py_neuromodulation-0.1.0/gui_dev/bun.lock +1904 -0
  60. py_neuromodulation-0.1.0/gui_dev/eslint.config.js +51 -0
  61. py_neuromodulation-0.1.0/gui_dev/index.html +13 -0
  62. py_neuromodulation-0.1.0/gui_dev/jsconfig.json +13 -0
  63. py_neuromodulation-0.1.0/gui_dev/package.json +49 -0
  64. py_neuromodulation-0.1.0/gui_dev/public/charite.svg +16 -0
  65. py_neuromodulation-0.1.0/gui_dev/scripts/wdyr.js +35 -0
  66. py_neuromodulation-0.1.0/gui_dev/src/App.jsx +88 -0
  67. py_neuromodulation-0.1.0/gui_dev/src/assets/fonts/figtree/Figtree-Italic-VariableFont_wght.ttf +0 -0
  68. py_neuromodulation-0.1.0/gui_dev/src/assets/fonts/figtree/Figtree-VariableFont_wght.ttf +0 -0
  69. py_neuromodulation-0.1.0/gui_dev/src/assets/fonts/figtree/OFL.txt +93 -0
  70. py_neuromodulation-0.1.0/gui_dev/src/assets/fonts/figtree/README.txt +77 -0
  71. py_neuromodulation-0.1.0/gui_dev/src/components/AppBar/index.js +1 -0
  72. py_neuromodulation-0.1.0/gui_dev/src/components/AppBar.jsx +65 -0
  73. py_neuromodulation-0.1.0/gui_dev/src/components/AppInfoModal.jsx +90 -0
  74. py_neuromodulation-0.1.0/gui_dev/src/components/BandPowerGraph.jsx +199 -0
  75. py_neuromodulation-0.1.0/gui_dev/src/components/CollapsibleBox.jsx +80 -0
  76. py_neuromodulation-0.1.0/gui_dev/src/components/DecodingGraph.jsx +340 -0
  77. py_neuromodulation-0.1.0/gui_dev/src/components/Drawer/index.js +1 -0
  78. py_neuromodulation-0.1.0/gui_dev/src/components/FileBrowser/FileBrowser.jsx +460 -0
  79. py_neuromodulation-0.1.0/gui_dev/src/components/FileBrowser/QuickAccess.jsx +104 -0
  80. py_neuromodulation-0.1.0/gui_dev/src/components/Graph/index.js +1 -0
  81. py_neuromodulation-0.1.0/gui_dev/src/components/HeatmapGraph.jsx +311 -0
  82. py_neuromodulation-0.1.0/gui_dev/src/components/PSDGraph.jsx +235 -0
  83. py_neuromodulation-0.1.0/gui_dev/src/components/RawDataGraph.jsx +324 -0
  84. py_neuromodulation-0.1.0/gui_dev/src/components/Settings/index.js +1 -0
  85. py_neuromodulation-0.1.0/gui_dev/src/components/Sidebar/Sidebar.jsx +137 -0
  86. py_neuromodulation-0.1.0/gui_dev/src/components/Sidebar/Sidebar.module.css +116 -0
  87. py_neuromodulation-0.1.0/gui_dev/src/components/Sidebar/index.js +1 -0
  88. py_neuromodulation-0.1.0/gui_dev/src/components/StatusBar/ResizeHandle.jsx +99 -0
  89. py_neuromodulation-0.1.0/gui_dev/src/components/StatusBar/ResizeHandle.module.css +25 -0
  90. py_neuromodulation-0.1.0/gui_dev/src/components/StatusBar/SocketStatus.jsx +64 -0
  91. py_neuromodulation-0.1.0/gui_dev/src/components/StatusBar/StatusBar.jsx +34 -0
  92. py_neuromodulation-0.1.0/gui_dev/src/components/StatusBar/StatusBar.module.css +41 -0
  93. py_neuromodulation-0.1.0/gui_dev/src/components/StatusBar/WebviewStatus.jsx +7 -0
  94. py_neuromodulation-0.1.0/gui_dev/src/components/StatusBar/index.js +1 -0
  95. py_neuromodulation-0.1.0/gui_dev/src/components/StatusBar/resize_handle.svg +4 -0
  96. py_neuromodulation-0.1.0/gui_dev/src/components/Switch/index.js +1 -0
  97. py_neuromodulation-0.1.0/gui_dev/src/components/TitledBox.jsx +35 -0
  98. py_neuromodulation-0.1.0/gui_dev/src/components/WindowButtons.jsx +46 -0
  99. py_neuromodulation-0.1.0/gui_dev/src/components/index.js +11 -0
  100. py_neuromodulation-0.1.0/gui_dev/src/components/utils.jsx +60 -0
  101. py_neuromodulation-0.1.0/gui_dev/src/main.jsx +20 -0
  102. py_neuromodulation-0.1.0/gui_dev/src/pages/Channels/Channels.jsx +244 -0
  103. py_neuromodulation-0.1.0/gui_dev/src/pages/Dashboard.jsx +103 -0
  104. py_neuromodulation-0.1.0/gui_dev/src/pages/Settings/Settings.jsx +393 -0
  105. py_neuromodulation-0.1.0/gui_dev/src/pages/Settings/components/FrequencyRange.jsx +165 -0
  106. py_neuromodulation-0.1.0/gui_dev/src/pages/Settings/components/OrderableLiteralListField.jsx +129 -0
  107. py_neuromodulation-0.1.0/gui_dev/src/pages/Settings/components/PrimitiveComponents.jsx +73 -0
  108. py_neuromodulation-0.1.0/gui_dev/src/pages/SourceSelection/DecodingModel.jsx +48 -0
  109. py_neuromodulation-0.1.0/gui_dev/src/pages/SourceSelection/FileSelector.jsx +125 -0
  110. py_neuromodulation-0.1.0/gui_dev/src/pages/SourceSelection/SourceSelection.jsx +61 -0
  111. py_neuromodulation-0.1.0/gui_dev/src/pages/SourceSelection/StreamParameters.jsx +74 -0
  112. py_neuromodulation-0.1.0/gui_dev/src/pages/SourceSelection/StreamSelector.jsx +191 -0
  113. py_neuromodulation-0.1.0/gui_dev/src/pages/index.js +4 -0
  114. py_neuromodulation-0.1.0/gui_dev/src/stores/appInfoStore.js +25 -0
  115. py_neuromodulation-0.1.0/gui_dev/src/stores/createStore.js +26 -0
  116. py_neuromodulation-0.1.0/gui_dev/src/stores/dragAndDropStore.js +18 -0
  117. py_neuromodulation-0.1.0/gui_dev/src/stores/index.js +7 -0
  118. py_neuromodulation-0.1.0/gui_dev/src/stores/sessionStore.js +359 -0
  119. py_neuromodulation-0.1.0/gui_dev/src/stores/settingsStore.js +128 -0
  120. py_neuromodulation-0.1.0/gui_dev/src/stores/socketStore.js +149 -0
  121. py_neuromodulation-0.1.0/gui_dev/src/stores/uiStore.js +53 -0
  122. py_neuromodulation-0.1.0/gui_dev/src/stores/webviewStore.js +51 -0
  123. py_neuromodulation-0.1.0/gui_dev/src/styles/reset.css +86 -0
  124. py_neuromodulation-0.1.0/gui_dev/src/theme.js +94 -0
  125. py_neuromodulation-0.1.0/gui_dev/src/utils/DataBuffer.js +63 -0
  126. py_neuromodulation-0.1.0/gui_dev/src/utils/FileInfo.js +137 -0
  127. py_neuromodulation-0.1.0/gui_dev/src/utils/FileManager.js +85 -0
  128. py_neuromodulation-0.1.0/gui_dev/src/utils/debounced_sync.js +49 -0
  129. py_neuromodulation-0.1.0/gui_dev/src/utils/index.js +1 -0
  130. py_neuromodulation-0.1.0/gui_dev/src/utils/utils.js +78 -0
  131. py_neuromodulation-0.1.0/gui_dev/vite.config.js +52 -0
  132. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/ConnectivityDecoding/_get_grid_whole_brain.py +0 -1
  133. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/ConnectivityDecoding/_helper_write_connectome.py +0 -2
  134. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/__init__.py +12 -4
  135. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/analysis/RMAP.py +3 -3
  136. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/analysis/decode.py +55 -2
  137. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/analysis/feature_reader.py +1 -0
  138. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/analysis/stats.py +3 -3
  139. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/default_settings.yaml +24 -17
  140. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/bandpower.py +65 -23
  141. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/bursts.py +9 -8
  142. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/coherence.py +7 -4
  143. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/feature_processor.py +4 -4
  144. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/fooof.py +7 -6
  145. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/mne_connectivity.py +25 -3
  146. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/oscillatory.py +5 -4
  147. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/sharpwaves.py +21 -0
  148. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/filter/kalman_filter.py +17 -6
  149. py_neuromodulation-0.1.0/py_neuromodulation/gui/__init__.py +3 -0
  150. py_neuromodulation-0.1.0/py_neuromodulation/gui/backend/app_backend.py +419 -0
  151. py_neuromodulation-0.1.0/py_neuromodulation/gui/backend/app_manager.py +345 -0
  152. py_neuromodulation-0.1.0/py_neuromodulation/gui/backend/app_pynm.py +244 -0
  153. py_neuromodulation-0.1.0/py_neuromodulation/gui/backend/app_socket.py +95 -0
  154. py_neuromodulation-0.1.0/py_neuromodulation/gui/backend/app_utils.py +306 -0
  155. py_neuromodulation-0.1.0/py_neuromodulation/gui/backend/app_window.py +202 -0
  156. py_neuromodulation-0.1.0/py_neuromodulation/gui/frontend/assets/Figtree-VariableFont_wght-CkXbWBDP.ttf +0 -0
  157. py_neuromodulation-0.1.0/py_neuromodulation/gui/frontend/assets/index-NbJiOU5a.js +300133 -0
  158. py_neuromodulation-0.1.0/py_neuromodulation/gui/frontend/assets/plotly-DTCwMlpS.js +23594 -0
  159. py_neuromodulation-0.1.0/py_neuromodulation/gui/frontend/charite.svg +16 -0
  160. py_neuromodulation-0.1.0/py_neuromodulation/gui/frontend/index.html +14 -0
  161. py_neuromodulation-0.1.0/py_neuromodulation/gui/window_api.py +115 -0
  162. py_neuromodulation-0.1.0/py_neuromodulation/lsl_api.cfg +3 -0
  163. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/processing/data_preprocessor.py +9 -2
  164. py_neuromodulation-0.1.0/py_neuromodulation/processing/filter_preprocessing.py +94 -0
  165. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/processing/normalization.py +32 -17
  166. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/processing/projection.py +2 -2
  167. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/processing/resample.py +6 -2
  168. py_neuromodulation-0.1.0/py_neuromodulation/run_gui.py +36 -0
  169. py_neuromodulation-0.1.0/py_neuromodulation/stream/__init__.py +9 -0
  170. py_neuromodulation-0.1.0/py_neuromodulation/stream/backend_interface.py +47 -0
  171. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/stream/data_processor.py +24 -3
  172. py_neuromodulation-0.1.0/py_neuromodulation/stream/mnelsl_player.py +194 -0
  173. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/stream/mnelsl_stream.py +9 -17
  174. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/stream/settings.py +80 -34
  175. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/stream/stream.py +82 -62
  176. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/utils/channels.py +1 -1
  177. py_neuromodulation-0.1.0/py_neuromodulation/utils/file_writer.py +110 -0
  178. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/utils/io.py +46 -5
  179. py_neuromodulation-0.1.0/py_neuromodulation/utils/perf.py +156 -0
  180. py_neuromodulation-0.1.0/py_neuromodulation/utils/pydantic_extensions.py +322 -0
  181. py_neuromodulation-0.1.0/py_neuromodulation/utils/types.py +177 -0
  182. py_neuromodulation-0.1.0/py_neuromodulation.code-workspace +40 -0
  183. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/pyproject.toml +42 -8
  184. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/conftest.py +5 -1
  185. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_bursts.py +4 -4
  186. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_coherence.py +14 -18
  187. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_lsl_stream.py +26 -11
  188. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_osc_features.py +2 -2
  189. py_neuromodulation-0.0.7/docs/source/api_documentation.rst +0 -51
  190. py_neuromodulation-0.0.7/docs/source/contributing.rst +0 -36
  191. py_neuromodulation-0.0.7/docs/source/nm_IO.rst +0 -5
  192. py_neuromodulation-0.0.7/docs/source/nm_RMAP.rst +0 -5
  193. py_neuromodulation-0.0.7/docs/source/nm_analysis.rst +0 -5
  194. py_neuromodulation-0.0.7/docs/source/nm_bursts.rst +0 -5
  195. py_neuromodulation-0.0.7/docs/source/nm_coherence.rst +0 -5
  196. py_neuromodulation-0.0.7/docs/source/nm_decode.rst +0 -5
  197. py_neuromodulation-0.0.7/docs/source/nm_define_nmchannels.rst +0 -5
  198. py_neuromodulation-0.0.7/docs/source/nm_features.rst +0 -5
  199. py_neuromodulation-0.0.7/docs/source/nm_filter.rst +0 -5
  200. py_neuromodulation-0.0.7/docs/source/nm_fooof.rst +0 -5
  201. py_neuromodulation-0.0.7/docs/source/nm_generator.rst +0 -5
  202. py_neuromodulation-0.0.7/docs/source/nm_hjorth.rst +0 -5
  203. py_neuromodulation-0.0.7/docs/source/nm_kalmanfilter.rst +0 -5
  204. py_neuromodulation-0.0.7/docs/source/nm_linelength.rst +0 -5
  205. py_neuromodulation-0.0.7/docs/source/nm_mne_connectivity.rst +0 -5
  206. py_neuromodulation-0.0.7/docs/source/nm_nolds.rst +0 -5
  207. py_neuromodulation-0.0.7/docs/source/nm_normalization.rst +0 -5
  208. py_neuromodulation-0.0.7/docs/source/nm_oscillatory.rst +0 -11
  209. py_neuromodulation-0.0.7/docs/source/nm_plots.rst +0 -5
  210. py_neuromodulation-0.0.7/docs/source/nm_projection.rst +0 -5
  211. py_neuromodulation-0.0.7/docs/source/nm_rereference.rst +0 -5
  212. py_neuromodulation-0.0.7/docs/source/nm_resample.rst +0 -5
  213. py_neuromodulation-0.0.7/docs/source/nm_run_analysis.rst +0 -5
  214. py_neuromodulation-0.0.7/docs/source/nm_settings.rst +0 -5
  215. py_neuromodulation-0.0.7/docs/source/nm_sharpwaves.rst +0 -5
  216. py_neuromodulation-0.0.7/docs/source/nm_stats.rst +0 -5
  217. py_neuromodulation-0.0.7/docs/source/nm_stream.rst +0 -5
  218. py_neuromodulation-0.0.7/docs/source/nm_stream_abc.rst +0 -5
  219. py_neuromodulation-0.0.7/examples/plot_7_lsl_example.py +0 -124
  220. py_neuromodulation-0.0.7/py_neuromodulation/processing/filter_preprocessing.py +0 -78
  221. py_neuromodulation-0.0.7/py_neuromodulation/stream/__init__.py +0 -3
  222. py_neuromodulation-0.0.7/py_neuromodulation/stream/mnelsl_player.py +0 -94
  223. py_neuromodulation-0.0.7/py_neuromodulation/utils/types.py +0 -251
  224. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/.github/workflows/python-publish.yml +0 -0
  225. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/.github/workflows/tests.yml +0 -0
  226. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/LICENSE +0 -0
  227. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/Makefile +0 -0
  228. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/make.bat +0 -0
  229. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/source/_static/CEBRA_embedding.png +0 -0
  230. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/source/_static/RMAP_figure.png +0 -0
  231. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/source/_static/css/RMAP_figure.png +0 -0
  232. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/source/_static/css/project-template.css +0 -0
  233. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/source/_templates/custom-class-template.rst +0 -0
  234. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/source/_templates/custom-module-template.rst +0 -0
  235. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/source/conf.py +0 -0
  236. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/docs/source/installation.rst +0 -0
  237. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/examples/README.rst +0 -0
  238. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/examples/example_cebra_decoding.html +0 -0
  239. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/examples/example_cebra_decoding.ipynb +0 -0
  240. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/examples/example_rmap.ipynb +0 -0
  241. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/examples/plot_3_example_sharpwave_analysis.py +0 -0
  242. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/examples/plot_5_example_rmap_computing.py +0 -0
  243. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/examples/plot_6_real_time_demo.py +0 -0
  244. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/examples/plot_8_cebra_example.py +0 -0
  245. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/ConnectivityDecoding/Automated Anatomical Labeling 3 (Rolls 2020).nii +0 -0
  246. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/ConnectivityDecoding/_get_grid_hull.m +0 -0
  247. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/ConnectivityDecoding/mni_coords_cortical_surface.mat +0 -0
  248. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/ConnectivityDecoding/mni_coords_whole_brain.mat +0 -0
  249. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/ConnectivityDecoding/rmap_func_all.nii +0 -0
  250. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/ConnectivityDecoding/rmap_struc.nii +0 -0
  251. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/analysis/__init__.py +0 -0
  252. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/analysis/plots.py +0 -0
  253. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/README +0 -0
  254. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/dataset_description.json +0 -0
  255. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/participants.json +0 -0
  256. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/participants.tsv +0 -0
  257. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/sub-testsub/ses-EphysMedOff/ieeg/sub-testsub_ses-EphysMedOff_space-mni_coordsystem.json +0 -0
  258. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/sub-testsub/ses-EphysMedOff/ieeg/sub-testsub_ses-EphysMedOff_space-mni_electrodes.tsv +0 -0
  259. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/sub-testsub/ses-EphysMedOff/ieeg/sub-testsub_ses-EphysMedOff_task-gripforce_run-0_channels.tsv +0 -0
  260. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/sub-testsub/ses-EphysMedOff/ieeg/sub-testsub_ses-EphysMedOff_task-gripforce_run-0_ieeg.eeg +0 -0
  261. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/sub-testsub/ses-EphysMedOff/ieeg/sub-testsub_ses-EphysMedOff_task-gripforce_run-0_ieeg.json +0 -0
  262. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/sub-testsub/ses-EphysMedOff/ieeg/sub-testsub_ses-EphysMedOff_task-gripforce_run-0_ieeg.vhdr +0 -0
  263. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/sub-testsub/ses-EphysMedOff/ieeg/sub-testsub_ses-EphysMedOff_task-gripforce_run-0_ieeg.vmrk +0 -0
  264. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/data/sub-testsub/ses-EphysMedOff/sub-testsub_ses-EphysMedOff_scans.tsv +0 -0
  265. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/__init__.py +0 -0
  266. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/bispectra.py +0 -0
  267. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/hjorth_raw.py +0 -0
  268. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/linelength.py +0 -0
  269. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/features/nolds.py +0 -0
  270. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/filter/__init__.py +0 -0
  271. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/filter/kalman_filter_external.py +0 -0
  272. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/filter/mne_filter.py +0 -0
  273. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/filter/notch_filter.py +0 -0
  274. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/grid_cortex.tsv +0 -0
  275. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/grid_subcortex.tsv +0 -0
  276. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/libpugixml.so.1.12 +0 -0
  277. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/linux/bionic_amd64/liblsl.1.16.2.so +0 -0
  278. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/linux/bookworm_amd64/liblsl.1.16.2.so +0 -0
  279. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/linux/focal_amd46/liblsl.1.16.2.so +0 -0
  280. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/linux/jammy_amd64/liblsl.1.16.2.so +0 -0
  281. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/linux/jammy_x86/liblsl.1.16.2.so +0 -0
  282. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/linux/noble_amd64/liblsl.1.16.2.so +0 -0
  283. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/macos/amd64/liblsl.1.16.2.dylib +0 -0
  284. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/macos/arm64/liblsl.1.16.0.dylib +0 -0
  285. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/windows/amd64/liblsl.1.16.2.dll +0 -0
  286. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/liblsl/windows/x86/liblsl.1.16.2.dll +0 -0
  287. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/plots/STN_surf.mat +0 -0
  288. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/plots/Vertices.mat +0 -0
  289. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/plots/faces.mat +0 -0
  290. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/plots/grid.mat +0 -0
  291. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/processing/__init__.py +0 -0
  292. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/processing/artifacts.py +0 -0
  293. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/processing/rereference.py +0 -0
  294. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/stream/generator.py +0 -0
  295. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/utils/__init__.py +0 -0
  296. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/utils/database.py +0 -0
  297. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/utils/keyboard.py +0 -0
  298. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/py_neuromodulation/utils/logging.py +0 -0
  299. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/__init__.py +0 -0
  300. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_all_examples.py +0 -0
  301. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_all_features.py +0 -0
  302. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_bispectra.py +0 -0
  303. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_database.py +0 -0
  304. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_feature_sampling_rates.py +0 -0
  305. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_fooof.py +0 -0
  306. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_initalization_offline_stream.py +0 -0
  307. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_nan_values.py +0 -0
  308. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_nm_filter.py +0 -0
  309. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_nm_resample.py +0 -0
  310. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_normalization_settings.py +0 -0
  311. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_notch_filter.py +0 -0
  312. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_preprocessing_filter.py +0 -0
  313. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_rereference.py +0 -0
  314. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_sampling.py +0 -0
  315. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_settings_change_after_init.py +0 -0
  316. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_sharpwave.py +0 -0
  317. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_target_channel_add.py +0 -0
  318. {py_neuromodulation-0.0.7 → py_neuromodulation-0.1.0}/tests/test_timing.py +0 -0
@@ -24,13 +24,13 @@ jobs:
24
24
  - name: Set up Python with uv
25
25
  uses: drivendataorg/setup-python-uv-action@v1
26
26
  with:
27
- python-version: '3.10'
27
+ python-version: '3.11'
28
28
  cache: packages
29
29
  cache-dependency-path: pyproject.toml
30
30
 
31
31
  - name: Install dependencies
32
32
  run: |
33
- uv pip install .[docs]
33
+ pip install .[docs]
34
34
 
35
35
  - name: make the sphinx docs
36
36
  run: |
@@ -191,9 +191,23 @@ out_per
191
191
  # Profiler files
192
192
  /*.prof
193
193
  /profiling/*
194
-
194
+ # Test output
195
+ test_data/
196
+ # various lock files
197
+ package-lock.json
198
+ package-lock.json.bak
199
+ uv.lock
200
+ # temporarily ignore the frontend build
201
+ /gui_dev/dist
202
+ /gui/frontend
203
+ # Node modules
195
204
  gui_dev/node_modules/*
205
+ # LSL log file
206
+ lsllog.txt
207
+ #Old Bun binary lockfile
208
+ bun.lockb
196
209
  test/data/*
197
-
198
210
  uv.lock
199
- lsllog.txt
211
+
212
+ sub_SETTINGS.yaml
213
+ sub_SIDECAR.json
@@ -1,9 +1,11 @@
1
- Metadata-Version: 2.3
1
+ Metadata-Version: 2.4
2
2
  Name: py_neuromodulation
3
- Version: 0.0.7
3
+ Version: 0.1.0
4
4
  Summary: Real-time analysis of intracranial neurophysiology recordings.
5
- Project-URL: bugtracker, https://github.com/neuromodulation/py_neuromodulation/issues
6
- Project-URL: repository, https://github.com/neuromodulation/py_neuromodulation
5
+ Project-URL: Homepage, https://neuromodulation.github.io/py_neuromodulation/
6
+ Project-URL: Documentation, https://neuromodulation.github.io/py_neuromodulation/
7
+ Project-URL: Repository, https://github.com/neuromodulation/py_neuromodulation
8
+ Project-URL: Issues, https://github.com/neuromodulation/py_neuromodulation/issues
7
9
  Author-email: Timon Merk <timon.merk@charite.de>
8
10
  Maintainer: Timon Merk
9
11
  License: MIT License
@@ -34,7 +36,10 @@ Classifier: License :: OSI Approved :: MIT License
34
36
  Classifier: Programming Language :: Python
35
37
  Classifier: Topic :: Software Development :: Libraries :: Python Modules
36
38
  Requires-Python: >=3.11
39
+ Requires-Dist: cbor2>=5.6.4
40
+ Requires-Dist: fastapi
37
41
  Requires-Dist: fooof
42
+ Requires-Dist: imbalanced-learn
38
43
  Requires-Dist: joblib>=1.3.2
39
44
  Requires-Dist: llvmlite>=0.43.0
40
45
  Requires-Dist: matplotlib>=3.9.0
@@ -43,18 +48,25 @@ Requires-Dist: mne-bids>=0.8
43
48
  Requires-Dist: mne-connectivity
44
49
  Requires-Dist: mne-lsl>=1.2.0
45
50
  Requires-Dist: mrmr-selection
51
+ Requires-Dist: msgpack>=1.1.0
52
+ Requires-Dist: nibabel>=5.3.2
46
53
  Requires-Dist: nolds>=0.6.1
47
54
  Requires-Dist: numba>=0.60.0
48
55
  Requires-Dist: numpy>=1.21.2
56
+ Requires-Dist: numpy>=2.0.0
49
57
  Requires-Dist: pandas>=2.0.0
50
58
  Requires-Dist: pyarrow>=14.0.2
51
59
  Requires-Dist: pybispectra>=1.2.0
52
60
  Requires-Dist: pydantic>=2.7.3
53
61
  Requires-Dist: pyparrm
62
+ Requires-Dist: pywebview
54
63
  Requires-Dist: scikit-learn>=0.24.2
55
64
  Requires-Dist: scikit-optimize
56
65
  Requires-Dist: scipy>=1.7.1
57
66
  Requires-Dist: seaborn>=0.11
67
+ Requires-Dist: skops>=0.10.0
68
+ Requires-Dist: uvicorn[standard]>=0.30.6
69
+ Requires-Dist: uvloop; platform_system != 'Windows'
58
70
  Provides-Extra: dev
59
71
  Requires-Dist: notebook; extra == 'dev'
60
72
  Requires-Dist: pytest-cov; extra == 'dev'
@@ -81,6 +93,8 @@ Description-Content-Type: text/x-rst
81
93
  py_neuromodulation
82
94
  ==================
83
95
 
96
+ Documentation: https://neuromodulation.github.io/py_neuromodulation/
97
+
84
98
  Analyzing neural data can be a troublesome, trial and error prone,
85
99
  and beginner unfriendly process. *py_neuromodulation* allows using a simple
86
100
  interface for extraction of established neurophysiological features and includes commonly applied pre -and postprocessing methods.
@@ -1,6 +1,8 @@
1
1
  py_neuromodulation
2
2
  ==================
3
3
 
4
+ Documentation: https://neuromodulation.github.io/py_neuromodulation/
5
+
4
6
  Analyzing neural data can be a troublesome, trial and error prone,
5
7
  and beginner unfriendly process. *py_neuromodulation* allows using a simple
6
8
  interface for extraction of established neurophysiological features and includes commonly applied pre -and postprocessing methods.
@@ -0,0 +1,8 @@
1
+ RMAP
2
+ ====
3
+
4
+ .. autoclass:: analysis.RMAP.ConnectivityChannelSelector
5
+ :members:
6
+
7
+ .. autoclass:: analysis.RMAP.RMAPCross_Val_ChannelSelector
8
+ :members:
@@ -0,0 +1,84 @@
1
+ API Documentation
2
+ =================
3
+
4
+
5
+ Analysis
6
+ --------
7
+
8
+ .. toctree::
9
+ :maxdepth: 4
10
+
11
+ decode
12
+ feature_reader
13
+ plots
14
+ RMAP
15
+ stats
16
+
17
+
18
+ Feature Classes
19
+ ---------------
20
+
21
+ .. toctree::
22
+ :maxdepth: 4
23
+
24
+ bispectra
25
+ bursts
26
+ coherence
27
+ fooof
28
+ hjorth
29
+ linelength
30
+ mne_connectivity
31
+ nolds
32
+ oscillatory
33
+ sharpwaves
34
+ bandpower
35
+
36
+
37
+ Filter
38
+ ------
39
+
40
+ .. toctree::
41
+ :maxdepth: 4
42
+
43
+ mne_filter
44
+ notch_filter
45
+
46
+
47
+ Processing
48
+ ----------
49
+
50
+ .. toctree::
51
+ :maxdepth: 4
52
+
53
+ artifacts
54
+ normalization
55
+ projection
56
+ rereference
57
+ resample
58
+
59
+
60
+ stream
61
+ ------
62
+
63
+ .. toctree::
64
+ :maxdepth: 4
65
+
66
+ generator
67
+ mnelsl_player
68
+ mnelsl_stream
69
+ settings
70
+ stream
71
+
72
+
73
+ utils
74
+ -----
75
+
76
+ .. toctree::
77
+ :maxdepth: 4
78
+
79
+ channels
80
+ database
81
+ io
82
+ logging
83
+ types
84
+
@@ -0,0 +1,5 @@
1
+ artifacts
2
+ =========
3
+
4
+ .. autoclass:: processing.artifacts.PARRMArtifactRejection
5
+ :members:
@@ -0,0 +1,5 @@
1
+ bandpower
2
+ =========
3
+
4
+ .. autoclass:: features.bandpower.BandPower
5
+ :members:
@@ -0,0 +1,5 @@
1
+ bispectra
2
+ =========
3
+
4
+ .. autoclass:: features.bispectra.Bispectra
5
+ :members:
@@ -0,0 +1,5 @@
1
+ bursts
2
+ ======
3
+
4
+ .. autoclass:: features.bursts.Bursts
5
+ :members:
@@ -0,0 +1,5 @@
1
+ channels
2
+ ========
3
+
4
+ .. automodule:: utils.channels
5
+ :members:
@@ -0,0 +1,5 @@
1
+ coherence
2
+ =========
3
+
4
+ .. autoclass:: features.coherence.Coherence
5
+ :members:
@@ -0,0 +1,87 @@
1
+ Contribution Guide
2
+ ==================
3
+
4
+ Welcome to the contributing guide of py_neuromodulation! We are very happy that you are interested in our project.
5
+
6
+ In general we recommend placing questions and issues in the `GitHub issue tracker <https://github.com/neuromodulation/py_neuromodulation/issues>`_.
7
+
8
+ For code formatting we use `ruff <https://docs.astral.sh/ruff/formatter/>`_.
9
+
10
+ For code development, we recommend using the package manager `uv <https://docs.astral.sh/uv/getting-started/installation/>`_.
11
+
12
+ To setup the python environment, type
13
+
14
+ ::
15
+
16
+ uv python install 3.11
17
+ uv venv
18
+
19
+
20
+ Depending on your operating system, activate the rye virtual environment:
21
+
22
+ ::
23
+
24
+ . .venv/bin/activate
25
+
26
+ And install the pyproject.toml dependencies:
27
+
28
+ ::
29
+
30
+ then sync the environment with
31
+
32
+ ::
33
+
34
+ uv sync
35
+
36
+ To install the documentation dependencies use pip:
37
+
38
+ ::
39
+
40
+ uv pip install -e .[docs]
41
+
42
+
43
+ GUI development
44
+ ---------------
45
+
46
+ Backend
47
+ ~~~~~~~
48
+
49
+
50
+ The GUI is setup as a react application with a `FastAPI <https://fastapi.tiangolo.com/>`_ backend with a `uvicorn <https://www.uvicorn.org/>`_ server.
51
+ The ``gui/backend/app_manager.py`` is the main entry point for the GUI backend. Here multiple tasks are defined and started using python `multiprocessing`.
52
+ In debug mode, `vite <https://vite.dev/>`_ is within ``gui/backend/app_manager.run_vite`` used to serve the frontend. In a subprocess ``bun run dev`` is called.
53
+ In production mode ``gui/backend/app_manager.run_backend`` directly serves the frontend from the `gui/frontend` directory, if `debug=False`.
54
+ Uvicorn (``gui/backend/app_manager.run_uvicorn``) runs an ASGI server, which deploys the FastAPI backend (``gui/backend/app_backend.PyNMBackend``).
55
+ Within the backend, multiple `get` and `post` routes are setup to interact with the frontend.
56
+
57
+ .. raw:: html
58
+
59
+ <br>
60
+
61
+ A *py_neuromodulation* state object is defined within the ``gui/backend/app_pynm.PyNMState`` class.
62
+ The state is initialized at the beginning of each App launch, and the settings and channels of the `nm.stream` are then modified during runtime.
63
+ Importantly, a ``stream.backend_interface`` is defined which creates an `asyncio` loop to interact with the `nm.stream` object.
64
+ Python `multiprocessing.Queue` objects are used for frontend communication, for starting or stopping the stream, or sending data to the frontend through websockets.
65
+ Within the ``gui/backend/app_socket.WebSocketManger``, the computed features and raw values are first serialized through `CBOR <https://cbor2.readthedocs.io/en/latest/usage.html>`_ and then sent to the frontend.
66
+
67
+ Frontend
68
+ ~~~~~~~~
69
+
70
+ The frontend is a `react <https://react.dev/>`_ application, which is stored in the `gui_dev` directory.
71
+ There are session, settings and socket `zustand <https://zustand-demo.pmnd.rs/>`_ stores.
72
+ Additionally, different pages and components are defined. `Plotly <https://plotly.com/javascript/>`_ is used for real-time dashboard visualization.
73
+
74
+ For GUI build, `bun <https://bun.sh/package-manager>`_ can be used to build the package. It is then saved into the `gui/frontend` directory.
75
+
76
+ Building the GUI in *gui_dev* folder:
77
+
78
+ ::
79
+
80
+ bun run build
81
+
82
+ Additionally, the script ``run_gui.py`` can be modified to be in `dev` mode:
83
+
84
+ ::
85
+
86
+ App(dev=True).launch()
87
+
@@ -0,0 +1,5 @@
1
+ database
2
+ ========
3
+
4
+ .. autoclass:: utils.database.NMDatabase
5
+ :members:
@@ -0,0 +1,5 @@
1
+ decode
2
+ ======
3
+
4
+ .. autoclass:: analysis.decode.Decoder
5
+ :members:
@@ -0,0 +1,5 @@
1
+ feature_reader
2
+ ==============
3
+
4
+ .. autoclass:: analysis.feature_reader.FeatureReader
5
+ :members:
@@ -0,0 +1,5 @@
1
+ fooof
2
+ =====
3
+
4
+ .. autoclass:: features.fooof.FooofAnalyzer
5
+ :members:
@@ -0,0 +1,5 @@
1
+ generator
2
+ =========
3
+
4
+ .. autoclass:: stream.generator.RawDataGenerator
5
+ :members:
@@ -0,0 +1,112 @@
1
+ GUI
2
+ ===
3
+
4
+ In this section we will explain the setup and use of the *py_neuromodulation* GUI.
5
+ First, the GUI dependencies can be installed with `uv`:
6
+
7
+ .. code-block:: bash
8
+
9
+ uv pip install -e .[gui]
10
+
11
+ The GUI can be started by running the following command:
12
+
13
+ .. code-block:: bash
14
+
15
+ run_gui
16
+
17
+ The ``run_gui`` command also starts a LabStreamingLayer stream from the `py_neuromodulation/data/` example directory.
18
+ The GUI is a react application, that can then be accessed via the browser at the following address:
19
+
20
+ .. code-block:: bash
21
+
22
+ http://localhost:50001
23
+
24
+ The GUI is divided into three main sections:
25
+ * **Source selection**: Data input which could be:
26
+ * offline stored file, e.g. in `mne.io.read_raw <https://mne.tools/1.8/generated/mne.io.read_raw.html>`_ format or a simply `.txt` or `.npy` file
27
+ * a `LabStreamingLayer <https://labstreaminglayer.org/#/>`_ stream
28
+ * **channel selection**: Definition of re-referencing, usage, target selection for the list of available channels
29
+ * **Feature selection**: Choosing the features for computation with the corresponding parameters
30
+
31
+ The source selection is shown in the following image:
32
+
33
+ .. image:: ../_static/sourceselection.png
34
+ :alt: GUI
35
+ :align: center
36
+
37
+ When clicking on the `SELECT FILE` button, a file dialog will open, where the user can select the file to be loaded:
38
+
39
+ .. image:: ../_static/fileselection.png
40
+ :alt: GUI
41
+ :align: center
42
+
43
+ Internally, available meta data such as sampling rate, line noise, available channel names will be read and a stream initialized.
44
+ Alternatively, the user can select a LabStreamingLayer stream by clicking on the upper `LSL STREAM` button. The available streams will be shown in a menu:
45
+
46
+ .. image:: ../_static/lslselection.png
47
+ :alt: GUI
48
+ :align: center
49
+
50
+ Clicking on the row of the desired stream will initialize then a stream with the read sampling rate, channel names and default settings.
51
+ A `.skops` decoding model, such as an openly-published `movement decoding model <https://zenodo.org/records/10794370>`_ can be loaded by clicking on the `LOAD MODEL` button.
52
+
53
+ Next, by selecting `SELECT CHANNELS`, the user is directed to the channel selection section:
54
+
55
+ .. image:: ../_static/channelselection.png
56
+ :alt: GUI
57
+ :align: center
58
+
59
+ Here the channel names, re-referencing, `mne supported types <https://mne.tools/stable/generated/mne.pick_types.html>`_ and target selection can be defined.
60
+ Next, by clicking on `SETTINGS`, the user is directed to the feature selection:
61
+
62
+ .. image:: ../_static/settings.png
63
+ :alt: GUI
64
+ :align: center
65
+
66
+ Here, many pre-processing, feature estimation and post-processing settings can be defined.
67
+ The main settings
68
+
69
+ * `sampling rate features [Hz]`
70
+ * `segment length features [ms]`
71
+
72
+ are defined the upper left section.
73
+ Additionally, frequency bands can be modified, added or deleted.
74
+ Once the settings are modified, they are internally validated for potential errors which would then be displayed:
75
+
76
+ .. image:: ../_static/pydantic.png
77
+ :alt: GUI
78
+ :align: center
79
+
80
+ Once the settings are correct, the user can click `SAVE & RUN STREAM` to jump to the stream control and feature visualization panel.
81
+ Here, different graphs can be selected by clicking on the corresponding graph list:
82
+
83
+ * `Raw data`
84
+ * `PSD plot`
85
+ * `Heatmap`
86
+ * `Band power graph`
87
+ * `Decoding graph`
88
+
89
+ When clicking on `RUN STREAM`, the stream will start and the selected features will be computed in real-time.
90
+ In the terminal the feature computation is logged, and features and raw signals are displayed in the GUI:
91
+
92
+ .. image:: ../_static/graphs.png
93
+ :alt: GUI
94
+ :align: center
95
+
96
+ Additionally, a heatmap with selected features can be displayed with the decoded model output:
97
+
98
+ .. image:: ../_static/decoding.png
99
+ :alt: GUI
100
+ :align: center
101
+
102
+ .. raw:: html
103
+
104
+ <br>
105
+
106
+ In the :doc:`contributing </contributing>` section we explain in further detail the GUI setup.
107
+
108
+ Known issues
109
+ ~~~~~~~~~~~~
110
+
111
+ Currently the GUI dashboard for live feature visualization is not fully functional with too many selected channels and PSD features.
112
+ The websocket connection will then be broken off and no further features will be visualized, but the backend *nm.stream* will still be running, and raw data continued to be processed and saved.
@@ -0,0 +1,5 @@
1
+ hjorth
2
+ ======
3
+
4
+ .. autoclass:: features.hjorth_raw.Hjorth
5
+ :members:
@@ -13,6 +13,7 @@ The *py_neuromodulation* toolbox allows for real time capable feature estimation
13
13
  installation
14
14
  usage
15
15
  auto_examples/index
16
+ gui
16
17
  api_documentation
17
18
  contributing
18
19
 
@@ -0,0 +1,5 @@
1
+ io
2
+ ==
3
+
4
+ .. automodule:: utils.io
5
+ :members:
@@ -0,0 +1,5 @@
1
+ linelength
2
+ ==========
3
+
4
+ .. autoclass:: features.linelength.LineLength
5
+ :members:
@@ -0,0 +1,5 @@
1
+ logging
2
+ =======
3
+
4
+ .. autoclass:: utils.logging.NMLogger
5
+ :members:
@@ -0,0 +1,5 @@
1
+ mne_connectivity
2
+ ================
3
+
4
+ .. autoclass:: features.mne_connectivity.MNEConnectivity
5
+ :members:
@@ -0,0 +1,5 @@
1
+ mne_filter
2
+ ==========
3
+
4
+ .. autoclass:: filter.mne_filter.MNEFilter
5
+ :members:
@@ -0,0 +1,5 @@
1
+ mnelsl_player
2
+ ==============
3
+
4
+ .. autoclass:: stream.mnelsl_player.LSLOfflinePlayer
5
+ :members:
@@ -0,0 +1,5 @@
1
+ mnelsl_stream
2
+ =============
3
+
4
+ .. autoclass:: stream.mnelsl_stream.LSLStream
5
+ :members:
@@ -0,0 +1,5 @@
1
+ nolds
2
+ =====
3
+
4
+ .. autoclass:: features.nolds.Nolds
5
+ :members:
@@ -0,0 +1,5 @@
1
+ normalization
2
+ =============
3
+
4
+ .. autoclass:: processing.normalization.Normalizer
5
+ :members:
@@ -0,0 +1,5 @@
1
+ notch_filter
2
+ ============
3
+
4
+ .. autoclass:: filter.notch_filter.NotchFilter
5
+ :members:
@@ -0,0 +1,11 @@
1
+ oscillatory
2
+ ===========
3
+
4
+ .. autoclass:: features.oscillatory.FFT
5
+ :members:
6
+
7
+ .. autoclass:: features.oscillatory.Welch
8
+ :members:
9
+
10
+ .. autoclass:: features.oscillatory.STFT
11
+ :members:
@@ -0,0 +1,5 @@
1
+ plots
2
+ =====
3
+
4
+ .. autoclass:: analysis.plots.NM_Plot
5
+ :members:
@@ -0,0 +1,5 @@
1
+ projection
2
+ ==========
3
+
4
+ .. autoclass:: processing.projection.Projection
5
+ :members:
@@ -0,0 +1,5 @@
1
+ rereference
2
+ ===========
3
+
4
+ .. autoclass:: processing.rereference.ReReferencer
5
+ :members:
@@ -0,0 +1,5 @@
1
+ resample
2
+ ========
3
+
4
+ .. autoclass:: processing.resample.Resampler
5
+ :members:
@@ -0,0 +1,5 @@
1
+ settings
2
+ ========
3
+
4
+ .. autoclass:: stream.settings.NMSettings
5
+ :members:
@@ -0,0 +1,5 @@
1
+ sharpwaves
2
+ ==========
3
+
4
+ .. autoclass:: features.sharpwaves.SharpwaveAnalyzer
5
+ :members:
@@ -0,0 +1,5 @@
1
+ stats
2
+ =====
3
+
4
+ .. automodule:: analysis.stats
5
+ :members:
@@ -0,0 +1,5 @@
1
+ Stream
2
+ ======
3
+
4
+ .. autoclass:: stream.stream.Stream
5
+ :members: