Software

NeuroAnalyzer is written in pure Julia wherever possible. Binary dependencies (FFTW, HDF5, Cairo, OpenGL bindings, GTK, Git) are provided as Julia binary packages and installed automatically, so no system libraries are normally needed.

It is developed and tested on Linux, with additional test runs on ARM64 (Raspberry Pi), macOS (Intel and Apple silicon) and Windows 10/11. Other Julia-compatible systems such as FreeBSD should work but are untested - feedback from users on those platforms is very welcome.

Linux (e.g. Debian) is recommended for the best performance.

Julia version: the current stable release of Julia is required. NeuroAnalyzer is only tested against it, so older versions are not supported. The recommended way to install and update Julia is juliaup:

# Linux and macOS
curl -fsSL https://install.julialang.org | sh
juliaup update

On Windows, install Julia from the Microsoft Store or with winget install --name Julia --id 9NJNWW8PVKMN -e -s msstore.

Multi-threading: most NeuroAnalyzer functions process channels and epochs in parallel. Julia uses a single thread unless told otherwise, so start it with:

julia -t auto

or set the JULIA_NUM_THREADS environment variable (e.g. export JULIA_NUM_THREADS=auto). Check the number of threads with Threads.nthreads().

First installation: installing NeuroAnalyzer downloads its dependencies and precompiles them; this takes several minutes and several GB of disk space in the Julia depot (~/.julia). Loading the package afterwards takes a few seconds, and the first call of each function in a session includes its compilation time.

Optional system components

  • Plotting: interactive plots and GUIs use OpenGL (GLMakie) and require a graphics driver supporting OpenGL 3.3 or later; desktop systems normally have one. On a headless server (or over SSH without a display), run Julia inside a virtual X server:
sudo apt-get install xvfb
xvfb-run -s '-screen 0 1920x1080x24' julia -t auto
  • Serial devices (recorders and testers using a serial port): on Linux the user must be a member of the dialout group:
sudo usermod -aG dialout $USER

(log out and in again for the change to take effect).

  • Raspberry Pi GPIO (hardware buttons in the testers): requires the pigpiod daemon; if it is not found, the keyboard is used instead. Note that pigpio does not support the Raspberry Pi 5.

  • Editing montage files (edit_montage()): uses Notepad on Windows, TextEdit on macOS and the editor set in the $EDITOR environment variable on Linux (e.g. export EDITOR=nano).

Hardware

For typical processing workloads, the following hardware is recommended:

  • CPU: a quad-core processor at minimum; a CPU with 8 or more cores is strongly recommended, as NeuroAnalyzer uses multi-threading throughout. High-core-count workstation CPUs (e.g. AMD Threadripper, Intel Xeon) shorten batch processing of large datasets. NeuroAnalyzer is developed on an AMD Ryzen Threadripper 3960X (24 cores); see benchmarks.
  • RAM: 8 GB minimum; 16 GB or more for larger datasets (see below).
  • GPU: not used for computations; any graphics card with OpenGL 3.3 support is sufficient for plotting.
  • Storage: SSD for active datasets, HDD for backups. Required capacity depends on the size of your recordings.

Estimating memory: signals are stored as 64-bit floats, i.e. 8 bytes × channels × samples:

Recording Size in memory
19-channel EEG, 256 Hz, 20 minutes ≈ 47 MB
64-channel EEG, 1000 Hz, 1 hour ≈ 1.8 GB
306-channel MEG, 1000 Hz, 1 hour ≈ 8.8 GB

Functions without ! return a modified copy of the object, so plan for several times the size of the data (or use the in-place ! versions).

For large-scale pipelines, running NeuroAnalyzer across a computing cluster is worth considering - Julia has excellent native support for distributed and parallel processing.

Raspberry Pi users: a 64-bit operating system and a model with at least 4 GB of RAM (8 GB recommended) are required. Precompilation needs more memory than the default swap provides (100 MB on older Raspberry Pi OS releases). On Raspberry Pi OS using dphys-swapfile, to increase it:

  1. Edit /etc/dphys-swapfile and set CONF_SWAPSIZE to the desired size in MB, e.g. CONF_SWAPSIZE=2048 (sizes above 2048 MB also need CONF_MAXSWAP to be raised)
  2. Restart the swap service: sudo systemctl restart dphys-swapfile