MCPcopy Index your code
hub / github.com/brain-workshop/brainworkshop

github.com/brain-workshop/brainworkshop @v5.0.3

Chat with this repo
repository ↗ · DeepWiki ↗ · release v5.0.3 ↗ · + Follow
246 symbols 685 edges 2 files 5 documented · 2%
What it actually does AI analysis from the code graph — generated when you open this
loading…
README

Build status

BrainWorkshop 5

PS: If you appreciated this work, please star the repository. It helps others find this repository

What is this?

This is a fork of the popular brain training software BrainWorkshop

Since there has not been a release in 3 years, I decided to get it working on Python 2+3 in additon to making many changes and improvements.

Version 5 is technically in Beta, although it is expected to be more stable compared to the original project and work with modern Python and Pyglet

Downloads

  • Windows: https://github.com/brain-workshop/brainworkshop/releases

New in this release:

  • Elements on the screen scale depending on the window size, making it much more usable if you have a hidpi monitor.
  • Using a widescreen resolution causes items on the screen to be placed/scale properly
  • Fullscreen mode sets the resolution of the screen automatically
  • Font size scales based on window size
  • Positioning of items also scales with window size
  • Window position and font size are determined with one function to do scaling, thereby making it easier in the future to make adjustments
  • Set fonts differently for serif and for monospace fonts, eventually to allow them to be configurable.
  • Now compatible with Python 3
  • Fixed issues with at least three modules not loading. This was due to being renamed or their semantics changing. Fixed in a way to maintain Python 2 compatibility.
  • Fix alignment of the polygons/icons in the grid due to changes to division in Python 3
  • Compatible with both Python 2 and Python 3!
  • Fixed crash with text.Label not recognizing halign; use align instead since halign is deprecated. Though to avoid breaking anything, we try align first and if that fails we fall back to using halign
  • Fix many more crashes and issues of Brain Workshop failing to launch

Notes:

  • You need pyglet installed for this to work.

Python 3

If you are having issues launching BrainWorkshop even if you have pyglet, future, past and libfuturize modules installed, follow these steps first: 1. Copy the following folders into the brainworkshop folder: past, future and libfuturize. You can get those here: https://github.com/PythonCharmers/python-future 2. Copy the pyglet module into a pyglet folder. You can get pyglet here: http://www.pyglet.org/

Python 2

  • You need pyglet, urllib3

Start of Old Readme

Brain Workshop: a Dual N-Back game in Python

Thank you for downloading Brain Workshop. Please visit the Brain Workshop web site for help & instructions!

From the main screen, press W to open the web site. Pressing H will open the Help & Tutorial page.

Or visit: http://brainworkshop.sourceforge.net

Configuration options are available in the file 'config.ini' in the data folder. This file is created when the program is first launched. Windows users can access this file via the 'Configuration' item in the Brain Workshop group in the Start Menu. Mac OS X users will need to right-click on the brainworkshop icon, select "Show Package Contents", and browse to Contents/MacOS/data/.

Let us know if you have any comments or suggestions:

plhosk@gmail.com jtoomim@jtoomim.org

Enjoy!


*** NOTE TO LINUX AND SOURCE-CODE USERS: ***

Python 2.5 or later is required to run Brain Workshop on Linux. Python 2.4 may also work as long as the python-ctypes package is installed. [Note: Windows versions and Mac OS X .app bundled versions of Brain Workshop have python included.]

The latest version of python can be downloaded here: http://www.python.org/download/releases/

Music support requires AVBin (highly recommended!) AVBin is included in binary distributions of Brain Workshop, but source code users will want to download AVBin here: http://code.google.com/p/avbin/

Detailed instructions and links for Mac OS X, Linux and win32 source installation are available on the Brain Workshop web site:

http://brainworkshop.sourceforge.net

Change Log:

4.8.1: * Bugfix release. Text shows up properly on Menu screens with BLACK_BACKGROUND=True. Bug in graphing code fixed which caused some stats.txt files to not be graphable. Option added to remove post- session feedback (requested by a researcher). Daily session counter fixed. Trials per session at startup fixed.

4.8: * Changed config.ini file format. Existing config.ini files will be renamed and replaced. Users will have to migrate their customizations manually. * Added Multi-stim modes, whereby objects appear in two to four places in the 3x3 grid at the same time. Objects can be differentiated either by image or by color. * Added Crab modes. In crab modes, you have to reverse every N stimuli when matching, so that in 3-back, if the stimuli you saw were the first line below, then you would be matching them against the second line, like thus: ABCDEFGHIJKLMNO ---CBAFEDIHGLKJ * Full support for multiple users and/or profiles. This lets you easily keep separate statistics for different settings (for example, with different timings or with JAEGGI_SCORING in the config file) or for different users. * Added an "interference" setting, whereby a certain percentage of the time Brain Workshop will generate trials designed to be particularly tricky, such as by making the current stimulus match the stimulus (n-1), (n+1), or (2n) trials ago, or (in multi-stim mode) by swapping the positions of the stimuli (n) trials ago. * New mode-, sound-, and user-selection screens. * Changed how often matches are generated for modes other than Dual N-back. * Made Brain Workshop ask for donations, by default every 100 sessions. You should do as the program asks. (This behavior can be changed in the config.ini file.) * Trial-by-trial session data are now recorded to disk in Python's pickle format in the USERNAME-sessions.dat files. * Changed how scores are calculated in graphing; the percentage of items correct now affects the exact score in addition to the N-back level. * All of the music files and some of the other media files have been removed for copyright reasons and replaced with free alternatives.

4.7: * Added Dual Audio n-back modes. Go to the Sound Selection screen to choose the sound set and channel (left, right, center) for each sound stimulus. * Number of trials per session now increases automatically with higher n-back levels. The calculation can be adjusted from the config file. * Timing resolution has been increased to 0.1 seconds, with a maximum speed of 0.3 seconds per trial. * Toggling Manual Mode no longer reverts to default settings. * Title screen graphic is now colored inversely when a black background is selected. * Stats file may be specified on the command line with --statsfile, complementing the --configfile command line parameter. * Comments may be added to the stats file on separate lines beginning with the # character.

4.5: * First release with Quad N-Back and other new modes * Includes various other improvements.

4.41: * The size of the field with the FIELD_EXPAND option was decreased slightly.

4.4: * Novice Mode was renamed to Jaeggi Mode. * Jaeggi Mode will activate certain options to emulate the appearance of the software used in the original study. Two configuration options were added to control this behavior. [Note: to see the new config options, delete your current config file and relaunch Brain Workshop to generate a fresh config.] * The data and res directories can now be specified on the command line using the --datadir and --resdir parameters (contributed by Timo Juhani Lindfors timo.lindfors@iki.fi). * The daily rollover hour for stats can now be specified in the config file. * A bug was fixed where certain trials would not show up in the list if the program was launched between midnight and 4 AM. * A setting to skip the title screen was added to the config file. * The grid lines and crosshairs can be toggled in the config file. * A setting was added to select rounded or sharp corners for the solid-color squares. * A setting was added to expand the size of the field to fill the screen. * Arithmetic Mode: The acceptable decimal answers can be set in the config file. * Three new music clips were added. * The Clear Stats key (Control-C) is working again.

4.3: * Variable n-back levels can be used with any game mode by pressing V in the Choose Game Mode screen. * Sounds for the auditory n-back task can be selected by pressing S. * Letter N-Back renamed to Combination N-Back. * New Morse Code sounds can be used with any n-back mode. For the ultimate challenge try using Morse Code with Dual, Tri or Quad Combination N-Back. Press J to open a Morse Code reference page. * Average n-back indicator will only count sessions specific to the current game mode. * Progress graphs now start from 1.0 on the vertical axis to give a better overall picture. * The cutoff for daily averages is is now 4:00 AM instead of midnight. * Music and applause is stopped when entering the progress graph to avoid sound skipping. (The sound may not stop in Linux due to driver limitations.) * Config file changes: The starting N-Back mode and game speed is now separately adjustable for each game mode, and some colors can be customized. Variable N-Back can also be set as default. [Note: to see the new config options, delete your current config file and relaunch Brain Workshop to generate a fresh config.]

4.22: * There's a new title screen. * Launching in Novice Mode will no longer cause a crash. * Progress graph: date axis will no longer skip days. * Progress graph: data points are now indicated with a dot. * Num pad should now work properly with Arithmetic N-Back modes. * Difficulty of Dual Variable N-Back has been increased slightly.

4.2: * Added new mode to stretch working memory: Dual Variable N-Back. The n-back level is displayed in the center and changes randomly every 3 seconds. * Added single-task n-back modes: Position N-Back and Audio N-Back. * Default config file is no longer packaged with the download so upgrading to this version won't overwrite existing configuration settings. The config file config.ini will be created if necessary when BW is launched for the first time. * OpenAL is now the default sound driver in Linux if available. If you're having sound problems, it may help to install the python-openal package. * There's no longer any need to install pyglet on Mac OS X or Linux. It's now included with the source distribution.

4.12: * Fixed level increase threshold in Novice mode * Novice mode now generates 4 visual matches, 4 audio matches and 2 simultaneous matches, matching the formula used in the original study.

4.11: * Fixed level decrease threshold in Novice mode * Added a configuration option to use the pre-4.1 flat squares * Two changes to Novice Mode to eliminate the last of the differences compared to the original study protocol: 1. Exactly 6 position and 6 audio matches are now generated each session 2. The score for the session is set as the lowest of the two individual modality scores (visual & audio).

4.1: * The squares in Dual & Triple N-Back have a new look. * Individual scores for each input category (position, sound, etc) are shown in the graph screen. * The number of sessions below 50% required to trigger a level decrease has been changed from 1 to 3. * New piano sounds are available in the config file to test your tonal memory. * Pressing the ESC key during a session will return you to the main screen instead of quitting the program.

4.04: - Added the division operation to the Arithmetic N-Back modes. Use the period key '.' to insert a decimal point. Each of the operations (add, subtract, multiply, divide) can be turned off or on in any combination in the config file. - Fixed a bug where if you had just advanced to a new level and quit BW, the next time you restarted you would be back at the previous level. - Added config option to play music in Manual mode.

4.03: - Added new number sounds (0-13). Either the letters or the numbers will be chosen randomly at the start of each session. - The female voice sounds are now selected by default. - Added two new game modes, Dual Arithmetic N-Back and Triple Arithmetic N-Back. Press N from the main screen to access the extra game modes.

4.02: - Fixed sound driver selection in Linux. - A few minor changes related to Arithmetic N-Back mode.

4.0: - New game mode: Arithmetic N-Back (see tutorial for details) - Optional Novice mode (aka BT mode) emulates the original study protocol. - New NATO Phonetic Alphabet sounds (alpha, bravo, charlie, etc). The old sounds are still available as an option. - Keep track of your daily progress with the new graphing feature. - Export your history of daily n-back averages to a text file for easy pasting into a spreadsheet. - Adaptive level-changing model ensures you're always playing at the right level. - Keyboard keys can now be redefined. - Feedback for missed cues is displayed. - Feedback can be turned off in the config file if desired. - Text can be hidden during gameplay to reduce distractions. - Optional full-screen mode for a larger, distracti

Core symbols most depended-on inside this repo

calc_fontsize
called by 49
brainworkshop.py
update
called by 37
brainworkshop.py
get_data_dir
called by 27
brainworkshop.py
scale_to_width
called by 23
brainworkshop.py
draw
called by 22
brainworkshop.py
close
called by 21
brainworkshop.py
width_center
called by 18
brainworkshop.py
from_top_edge
called by 16
brainworkshop.py

Shape

Method 144
Function 59
Class 43

Languages

Python100%

Modules by API surface

brainworkshop.py246 symbols

For agents

$ claude mcp add brainworkshop \
  -- python -m otcore.mcp_server <graph>

⬇ download graph artifact