Task-based behavior control experiment

BeHive for the KloostermanLab (NERF, Belgium)

USE-CASE

6/25/20222 min read

BeHive is a specialized project developed to meet the automation needs of the Kloosterman Lab, focusing on the control of their maze using two distinct types of hardware: Doors and food delivery mechanisms. The intricacy of this automation lies in its reliance on animal behavior and the experimental paradigm.

To accommodate the diverse requirements of individual experimenters, a crucial first step was the implementation of a flexible plugin system. This system enables experimenters to easily describe their unique paradigms, seamlessly integrating them into the application without necessitating alterations to the core components such as the GUI and logging functionalities.

The architectural design of the code prioritizes the segregation of responsibilities, separating the code for hardware control, GUI, and custom tasks. Each component adheres to a defined interface and is registered with a class name in a centralized registry. Users can then assemble these components using a configuration file that precisely outlines the desired actions, events, and tasks. The flexibility of the system is exemplified by the myriad combinations possible, all conforming to a standardized interface layer.

Objects are instantiated independently upon parsing the configuration file. Events and actions instances are dynamically created using an observer-factory pattern, establishing a system where they can either notify or be notified by the primary custom task, facilitating the prompt processing of events and the execution of actions on the actuators.

This custom task, modeled as a state-transition graph, encapsulates a series of trials represented by nodes, each with success or failure outcomes determined by the preceding trials. This intricate structure enables the seamless processing of events and the execution of actions on the actuators, guided by the logic embedded in the state-transition graph.

Both events and actions seamlessly handle communication with various hardware components, ensuring a streamlined workflow.

The view is compartmentalized into two parts, featuring a general dashboard for configuring the file, entering user details, and monitoring experiment results. Once a configuration file is loaded, the custom-task specific section of the dashboard updates to display the status of all hardware components in the experimental setup, including battery levels and food supplies.

In conclusion, the implementation of this software has significantly enhanced our research endeavors, empowering three researchers to concurrently engage in experiments across three rooms for a span of three years. The seamless automation of the entire experiment process not only contributed to improved reproducibility across days and experimenters but also afforded researchers valuable free time. With the need for manual button-pushing eliminated, researchers could redirect their focus to observing camera feeds, fostering a more efficient and streamlined research environment. The success of this software underscores its pivotal role in advancing experimental methodologies and optimizing resource utilization within our research facility.

Publications that used this software:

  • Awake hippocampal replay is not required for short-term memory (pre-print), Lies Deceuninck, Fabian Kloosterman