Skip to content
Tomas Ukkonen edited this page Mar 18, 2024 · 39 revisions

resonanz.exe is a command-line utility to be used together with Interaxon Muse 1. It can be downloaded from this release: https://github.com/cslr/resonanz/releases/tag/v0.60.

Commands to do audiovisual neurostimulation are:

  • muse-io.exe --osc osc.udp://127.0.0.1:4545 (connect Muse to computer and send data/OSCs to UDP 4545 port)
  • alternatively you can use Mind Monitor app in a phone to connect to Muse headband and send UDP OSC packets to 4545 port and IP address of the computer.
  • resonanz --measure --picture-dir=/c/msys64/home/Tomas/cc0pictures/unplash.com/ --model-dir=model/ (measure EEG responses to keywords, pictures and sounds, you have to measure responses for 1-2 hours to have enough data)
  • resonanz --optimize --picture-dir=/c/msys64/home/Tomas/cc0pictures/unplash.com/ --model-dir=model/ (optimize models to predict how EEG changes given stimulus, it can take hours to optimize models)
  • resonanz --program --picture-dir=/c/msys64/home/Tomas/cc0pictures/unplash.com/ --model-dir=model/ --target=1,-1,-1,-1,-1,-1,0 --loop (steer nervous system towards max delta, min spectral entropy => sleep)

Tranquility

Newer version of the software is tranquility. It currently don't use picture stimulation but flashing screen (40 Hz was noticed to reduce alzheimer symptoms in medical research). It supports Mind Monitor App to send OSC packets to Windows or Linux program which contains also EEG-data (udp packets to port 4545). Mind Monitor App supports newer Interaxon Muse devices. Compile tranquility using "Makefile -f Makefile.linux/win32 tranquility".

https://github.com/cslr/resonanz/releases/tag/v0.91

Commands to use tranquility are:

  • tranquility --measure --model-dir=model (measure EEG responses to keywords, visuals and sounds, you have to measure responses for 20-40 minutes to have enough data)
  • tranquility --optimize --model-dir=model (optimize models to predict how EEG changes given stimulus, it can take days to optimize models)
  • tranquility --program --model-dir=model --target=1,-1,-1,-1,-1,-1,0,-1,-1 --loop (steer nervous system towards max delta, min spectral entropy => sleep [spectral entropy minimization currently don't work well])

With one test person and single 20min measurements, effects to CNS are somewhat random but typically one gets 2-10% change to target simple EEG values (like just alpha waves for relaxation) into the right direction. With more complex targets results are close to 0%. Further work is to try to measure brain responses from multiple persons and try to find more general and reliable model for predicting brain responses.

Tranquility now has intelligence related target variables (phase shift and phase slope index), maximizing them may in theory improve logical intelligence/thinking somewhat. Currently effects to those variables by stimulation are small, typically 2-3%.

Tranquility models brain measurements as (sum of independent) process(es) which evolves by itself and is altered by stimulation. Recurrent neural network is SLOW to optimize but should give higher quality results.

For speed, tranquility currently uses only quite-wide recurrent 5-layer residual ReLU neural network and not larger one.

TODO

  • Update neural network code to use deep learning method and use 20 layer residual neural network instead of shorter wider one, this requires some tinkering of the parameters
  • tranquility support for archive of pictures using deep neural network autoencoder features which are used to predict response to picture stimulation, (use single recurrent model for pictures with input picture feature vector).
  • Emotiv Insight support (Emotiv SDK costs about 5000 USD)
  • own free mobile phone app (Muse, android/iphone) to send EEG measurement OSC-packets to computer

Here is example of generated picture stream (pushes toward same state as an EEG response to music) which should cause relaxedness (https://youtu.be/oPFCxLSF6XI):

Example of video

CONTACT

Tomas Ukkonen [tomas.ukkonen@iki.fi]

If you wish to further the development consider donating equipment (Insight, Emotiv NM8, more pro-grear (many EEG channels), others..).

Clone this wiki locally