Source code for allensdk.brain_observatory.behavior.session_apis.abcs.data_extractor_base.behavior_data_extractor_base
import abc
from datetime import datetime
from typing import List
[docs]class BehaviorDataExtractorBase(abc.ABC):
"""Abstract base class implementing required methods for extracting
data (from LIMS or from JSON) that will be transformed or passed on to
fill behavior session data.
"""
[docs] @abc.abstractmethod
def get_behavior_session_id(self) -> int:
"""Get the ID of the behavior session"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_foraging_id(self) -> int:
"""Get the foraging ID for the behavior session"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_equipment_name(self) -> str:
"""Get the name of the experiment rig (ex: CAM2P.3)"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_sex(self) -> str:
"""Get the sex of the subject (ex: 'M', 'F', or 'unknown')"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_age(self) -> str:
"""Get the age code of the subject (ie P123)"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_stimulus_name(self) -> str:
"""Get the name of the stimulus presented for a behavior or
behavior + ophys experiment"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_reporter_line(self) -> List[str]:
"""Get the (gene) reporter line(s) for the subject associated with a
behavior or behavior + ophys experiment"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_driver_line(self) -> List[str]:
"""Get the (gene) driver line(s) for the subject associated with a
behavior or behavior + ophys experiment"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_full_genotype(self) -> str:
"""Get the full genotype of the subject associated with a
behavior or behavior + ophys experiment"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_behavior_stimulus_file(self) -> str:
"""Get the filepath to the StimulusPickle file for the session"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_mouse_id(self) -> int:
"""Get the mouse id (LabTracks ID) for the subject
associated with a behavior experiment"""
raise NotImplementedError()
[docs] @abc.abstractmethod
def get_date_of_acquisition(self) -> datetime:
"""Get the acquisition date of an experiment in UTC"""
raise NotImplementedError()