position_dlc_orient.py
DLCOrientationParams
¶
Bases: SpyglassMixin
, Manual
Params for determining and smoothing the orientation of a set of BodyParts
Parameters:
Name | Type | Description | Default |
---|---|---|---|
dlc_orientation_params_name
|
str
|
Name for this set of parameters |
required |
params
|
dict
|
Dictionary of parameters, including... orient_method : str Method for determining orientation. Options are: 'none': No orientation calculation 'red_green_orientation': Two-point head orientation calculation 'red_led_bisector': Red LED bisector orientation calculation bodypart1 : str First bodypart to use for orientation calculation bodypart2 : str Second bodypart to use for orientation calculation orientation_smoothing_std_dev : float Standard deviation for Gaussian smoothing of the orientation data |
required |
Source code in src/spyglass/position/v1/position_dlc_orient.py
insert_params(params_name, params, **kwargs)
classmethod
¶
Insert a set of parameters for orientation calculation
Source code in src/spyglass/position/v1/position_dlc_orient.py
insert_default(**kwargs)
classmethod
¶
Insert the default set of parameters for orientation calculation
Source code in src/spyglass/position/v1/position_dlc_orient.py
get_default()
classmethod
¶
Return the default set of parameters for orientation calculation
Source code in src/spyglass/position/v1/position_dlc_orient.py
DLCOrientation
¶
Bases: SpyglassMixin
, Computed
Determines and smooths orientation of a set of bodyparts given a specified method
Source code in src/spyglass/position/v1/position_dlc_orient.py
107 108 109 110 111 112 113 114 115 116 117 118 119 120 121 122 123 124 125 126 127 128 129 130 131 132 133 134 135 136 137 138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 218 219 220 221 222 223 224 225 226 227 228 229 230 231 232 233 234 235 |
|
make(key)
¶
Populate the DLCOrientation table.
- Fetch parameters and position data from DLCOrientationParams and DLCSmoothInterpCohort.BodyPart tables, respectively.
- Apply chosen orientation method to position data.
- Generate a CompassDirection object and add it to the AnalysisNwbfile.
- Insert the key into the DLCOrientation table.
Source code in src/spyglass/position/v1/position_dlc_orient.py
138 139 140 141 142 143 144 145 146 147 148 149 150 151 152 153 154 155 156 157 158 159 160 161 162 163 164 165 166 167 168 169 170 171 172 173 174 175 176 177 178 179 180 181 182 183 184 185 186 187 188 189 190 191 192 193 194 195 196 197 198 199 200 201 202 203 204 205 206 207 208 209 210 211 212 213 214 215 216 217 |
|
fetch1_dataframe()
¶
Fetch a single dataframe