ota.execution package

Submodules

ota.execution.pupil_locate module

ota.execution.pupil_locate.construct_pupil_list(video, first_frame, last_frame, threshold=10)[source]

Construct a dictionary of pupil objects for a series of video frames.

Inputs:
video - video object first_frame - int last_frame - int
Outputs:
pupil_list: Dictionary of pupil objects where the key is the frame number and the value is the pupil object.

ota.execution.torsion_quant_2DX module

ota.execution.torsion_quant_2DX.quantify_torsion(WINDOW_RADIUS, RESOLUTION, torsion_mode, transform_mode, video, start_frame, reference_frame, end_frame, pupil_list, threshold, WINDOW_THETA=None, SEGMENT_THETA=None, upper_iris=None, lower_iris=None, feature_coords=None)[source]

Utilizes the 2D cross correlation algorithm xcorr2d to measure and return torsion using the settings given.

Inputs:
WINDOW_RADIUS:
Integer Mandatory input which sets the radial thickness of the iris transform.
RESOLUTION:
Double Mandatory input with sets the upsampling factor or the interpolation resolution depending on settings below.
torsion_mode:
String Mandatory input which determines whether interpolation or upsampling is used. if torsion_mode = ‘interp’, then interpolation is used and RESOLUTION is assumed to be interpolation resolution. Consequently an upsampling factor of 1 is used in the transform. if torsion_mode = ‘upsample’, then upsampling is used and RESOLUTION is assumed to be the upsampling factor.
transform_mode:
String Mandatory input which determines whether a subset of the iris is used or the full iris is used during correlation. if transform_mode = ‘subset’, a subset of the iris is used. if transform_mode = ‘full’, the full iris us used.
video:
Video object Mandatory input
start_frame:
Integer Mandatory input which is the index of the reference frame.
end_frame:
Integer Mandatory input which is the index of the last frame to analyze.
pupil_list:
dictionary of pupil objects key: (int) video frame value: pupil object
WINDOW_THETA:
Integer Angle bounds above/below the feature that define the portion of the iris that is to be included in the reference iris window. This window should be smaller than the segment. Mandatory input if transform_mode = ‘subset’.
SEGMENT_THETA:
Integer Angle bounds above/below the feature that define the portion of the iris that is to be included in each segment, for which the window is to be located in. Mandatory input if transform_mode = ‘subset’.
upper_iris_occ:
dictionary, {‘c’: column index, ‘r’: row index} Holds the [row,column] coordinates of the upper boundary of the iris that is not occluded by eyelids or eyelashes.
lower_iris_occ:
dictionary, {‘c’: column index, ‘r’: row index} Holds the [row,column] coordinates of the lower boundary of the iris that is not occluded by eyelids or eyelashes.
feature_coords:
dictionary, {‘c’: column index, ‘r’: row index} Holds the dictionary of feature coordinates tracked during subset correlation. Mandatory input if transform_mode = ‘subset’.

Returns:

torsion:
Dictionary key = frame number value = rotation from reference frame

Module contents