interfaces

digraph inheritance96efe7ce9e { bgcolor=transparent; rankdir=LR; size="8.0, 12.0"; "abc.ABC" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Helper class that provides a standard way to create an ABC using"]; "autopilot.data.interfaces.base.Interface" [URL="../base.html#autopilot.data.interfaces.base.Interface",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Create a representation of a given Schema"]; "autopilot.root.Autopilot_Type" -> "autopilot.data.interfaces.base.Interface" [arrowsize=0.5,style="setlinewidth(0.5)"]; "autopilot.data.interfaces.base.Interface_Map" [URL="../base.html#autopilot.data.interfaces.base.Interface_Map",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Statement of equivalence between two things, potentially with some"]; "autopilot.root.Autopilot_Type" -> "autopilot.data.interfaces.base.Interface_Map" [arrowsize=0.5,style="setlinewidth(0.5)"]; "autopilot.data.interfaces.base.Interface_Mapset" [URL="../base.html#autopilot.data.interfaces.base.Interface_Mapset",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Metaclass for mapping base types to another format."]; "autopilot.root.Autopilot_Type" -> "autopilot.data.interfaces.base.Interface_Mapset" [arrowsize=0.5,style="setlinewidth(0.5)"]; "autopilot.data.interfaces.nwb.NWB_Interface" [URL="../nwb.html#autopilot.data.interfaces.nwb.NWB_Interface",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "autopilot.root.Autopilot_Type" -> "autopilot.data.interfaces.nwb.NWB_Interface" [arrowsize=0.5,style="setlinewidth(0.5)"]; "autopilot.data.interfaces.tables.H5F_Group" [URL="../tables.html#autopilot.data.interfaces.tables.H5F_Group",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Description of a pytables group and its location"]; "autopilot.data.interfaces.tables.H5F_Node" -> "autopilot.data.interfaces.tables.H5F_Group" [arrowsize=0.5,style="setlinewidth(0.5)"]; "autopilot.data.interfaces.tables.H5F_Node" [URL="../tables.html#autopilot.data.interfaces.tables.H5F_Node",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Base class for H5F Nodes"]; "autopilot.data.modeling.base.Node" -> "autopilot.data.interfaces.tables.H5F_Node" [arrowsize=0.5,style="setlinewidth(0.5)"]; "autopilot.data.interfaces.tables.H5F_Table" [URL="../tables.html#autopilot.data.interfaces.tables.H5F_Table",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "autopilot.data.interfaces.tables.H5F_Node" -> "autopilot.data.interfaces.tables.H5F_Table" [arrowsize=0.5,style="setlinewidth(0.5)"]; "autopilot.data.interfaces.tables.Tables_Interface" [URL="../tables.html#autopilot.data.interfaces.tables.Tables_Interface",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top"]; "autopilot.data.interfaces.base.Interface" -> "autopilot.data.interfaces.tables.Tables_Interface" [arrowsize=0.5,style="setlinewidth(0.5)"]; "autopilot.data.modeling.base.Node" [URL="../../modeling/index.html#autopilot.data.modeling.base.Node",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Abstract representation of a Node in a treelike or linked data structure."]; "autopilot.root.Autopilot_Type" -> "autopilot.data.modeling.base.Node" [arrowsize=0.5,style="setlinewidth(0.5)"]; "autopilot.root.Autopilot_Type" [URL="../../../root/index.html#autopilot.root.Autopilot_Type",fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",target="_top",tooltip="Root autopilot model for types"]; "pydantic.main.BaseModel" -> "autopilot.root.Autopilot_Type" [arrowsize=0.5,style="setlinewidth(0.5)"]; "abc.ABC" -> "autopilot.root.Autopilot_Type" [arrowsize=0.5,style="setlinewidth(0.5)"]; "pydantic.main.BaseModel" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled"]; "pydantic.utils.Representation" -> "pydantic.main.BaseModel" [arrowsize=0.5,style="setlinewidth(0.5)"]; "pydantic.utils.Representation" [fillcolor=white,fontname="Vera Sans, DejaVu Sans, Liberation Sans, Arial, Helvetica, sans",fontsize=10,height=0.25,shape=box,style="setlinewidth(0.5),filled",tooltip="Mixin to provide __str__, __repr__, and __pretty__ methods. See #884 for more details."]; }

Interfaces define mappings between basic python types and the classes in modeling.

This set of classes is still growing, and we’re still exploring the best strategy to make generalizable interfaces between very different formats, but in general, each interface consists of mappings between types and some means of converting the particular data structures of one format and another.

The only interface that is actively used within Autopilot is that for tables, but we have started interfaces for nwb and datajoint (using a parallel project datajoint-babel). Both of these are provisional and very incomplete, but it is possible to generate a datajoint schema from any table, and there are mappings and conversions for their different representations of types.

Our goal for future versions is to generalize data interfaces to the point where a similar API can be shared across them, so a subject’s data can be stored in HDF5 or in a datajoint database equivalently.