Here is a diagram of the automatic training system we've been devloping for the dynamic foraging task (those blue arrows on top of our existing foraging behavior pipeline)
This repo is the red circle in the diagram. It will be running on Code Ocean and do the following things (very similar to mTrack):
- Define the training curriculum (mTrack's "Regimen")
- Retrieve data for each mouse from the behavioral master table (
df_behavior
on S3 that stores session-wise metrics) - Evaluate daily performance based on the curriculum and make decisions of the next training stage (stored in
df_manager
) - Push the decisions back to S3 by uploading
df_manager
, from which our python GUI can access and automatically set the training parameters on the next day.
- Task schema defines schema for training parameters
- Curriculum schema defines schema for the curriculum, especially the
evaluate_transitions
method - Auto train manager fetches data from
df_behavior
and updatesdf_manager
(or "tables" on any other database) - Curriculum manager manages all available pre-generated curriculums (on any S3 bucket).
- Design the curriculum, i.e., all training stages and transition rules.
- Here is an example curriculum for the dynamic foraging task.
- Here is automatically generated json file
- Here are automatically rendered diagrams for stage transitions rules and parameters (click the images to try the hover feature 😊)
rules | parameters |
---|---|
-
Create
AutoTrainManager
and connect it to the behavior databasedf_behavior
. -
Feed all necessary metrics to
Auto train manager
and let it run. -
To add other tasks, users should add their own task and curriculum schemas.
- Demo notebook for the curriculum schema.
- Demo notebook for a full automation workflow (auto train manager)
- Demo notebook for the curriculum manager
System upgrade checklist
- Upgrade all training rigs
- Upgrade CO capsule (terminate all running workers and start a new one)
- Upgrade streamlit app
See this thread