AllenInstitute / AllenInstitute/AllenSDK

Create BehaviorOphysSession class

Open
#2,154 0 comments 0 reactions 0 assignees View on GitHub

Nobody has claimed this yet.

braintv enhancement
Dominant language
Jupyter Notebook
Stars
398
Forks
163
PR merge metrics
No merged PRs in 30d

Description

We currently instantiate behavior sessions via BehaviorSession class but instantiate behavior-ophys experiments via BehaviorOphysExperiment class. Since an ophys session can have multiple ophys experiments, it would make sense to create an BehaviorOphysSession class which has a list of BehaviorOphysExperiment.

This would fix an issue which is that ophys_session_id is currently a property of BehaviorOphysExperimentMetadata, when it should be a property of the session, rather than the experiment.

This design is somewhat related to the differences in Mesoscope vs Scientifica (many-to-one vs one-to-one). To take this on, would need to ensure that all tests, and notebooks and Visual Behavior group GLM notebooks would still work.

Before spending a lot of time on this, need to document the planned design, and get it reviewed by team.

Validation criteria:

  • BehaviorOphysSession class exists, which has list of BehaviorOphysExperiment
  • Can instantiate via ophys_experiment_id (current behavior) or ophys_session_id
  • Attributes at the session level should be moved from experiment level to here (one example is ophys_session_id, another is imaging_plane_group_count
  • published notebooks have been updated and demonstrate they work
  • Visual Behavior representative reports that their critical code still works

Contributor guide

Open the contributing guide

First steps

  1. Read the whole issue, then the project's contributing guide.
  2. Comment on the issue to say you are picking it up — it saves two people doing the same work.
  3. Fork the repository and make your change on a branch.
  4. Open a pull request that references the issue number.

Research direction

Start by reviewing the existing BehaviorSession, BehaviorOphysExperiment, and BehaviorOphysExperimentMetadata entry points, then document the proposed session design for team review. Check how published notebooks and Visual Behavior group GLM notebooks use these classes. Done means the listed validation criteria pass, including both session and experiment instantiation paths and working notebooks.

Written by the indexing model from the issue text.

Assessment

Tech stack
jupyter-notebook
Domain
backend-api-design, data
Issue type
Feature
Difficulty
5/5
Estimated time
Over a week
Activity status
Stale
Clarity
Mostly clear
Newbie friendliness
30/100

Get new issues in your inbox

A short digest of beginner-friendly GitHub issues.