Utilizing bonsai.scripting.python to reactively log messages using a python gui during onix data acquisition #2530
-
|
Hey all! I'm trying to use the python scripting module to be able to log events during onix experiments for a research lab I'm in. I'm having a little trouble with it, and a little trouble understanding how bonsai interacts with my python scripts. The main goal I'm trying to achieve is as follows:
I'm not attached to my python file, so if it needs to be fully revamped to fit with the workflow, that's fine by me. Here's what my workflow currently looks like. I've done a lot of experimenting and I'm still trying to figure out how exactly to get it to work the way I want. I have the take until also listening to the button as a temporary placeholder while I figure out the python aspect. I will change it to stop listening when i run the final eval on the strand with the button (or find a better way to check if the message is submitted) And here's the XML: |
Beta Was this translation helpful? Give feedback.
Replies: 1 comment
-
Beta Was this translation helpful? Give feedback.


I encourage you to give the native GUI package a try. I would avoid using the python scripting package, especially in workflows that rely high frequency data acquisition as it is the case with yours. Managing the GIL is notoriously annoying, and it will easily add bottlenecks to your workflow.