Skip to main content
Skip table of contents

TRACKPixx

class tracker.TRACKPixx3

Bases: Tracker, DpxDevice

Class Definition for the DATAPixx3 Device.

The bases defined below are the core subsystems attached to a DATAPixx3 devices. A DATAPixx3 device also has very specific subsystems which are used through handles. See the example bellow for more details.

If you have a Lite version of the device, some of these handles will not be available. The usage of the handles is as follows:

PYTHON
>>> from pypixxlib.datapixx import DATAPixx3
>>> my_device = DATAPixx3()
>>> my_device.adc.function() # adc is the subsystem in this example.
>>> my_device.BaseFunction() # A base function from one of the class' bases.
clearDeviceCalibration()

Clear calibration from tracker, making device not calibrated

close()

Closes a TrackPixx device.

This method is used to release a handle on a TrackPixx device.

finishCalibration()

Finishes the calibration on the Device.

This function is to be called when you are done displaying stimuli for calibration. It will calculate the calibrations parameter on the device and set the state to calibrated (which can be verified through isDeviceCalibrated.

getDistance()

Returns the tracking distance in cm.

This returns the current distance set in tracker in cm. This is used along with lens to determine the iris size.

Returns:

The distance in cm

getEyePosition()

Returns the current gaze position by finding the best polynomial.

This returns the current calibrated gaze position on the screen using the calibration parameters found for the latest calibration.

Returns:

A list of gaze position, such that first elements are screen_x_left_eye, screen_y_left_eye, screen_x_right_eye, screen_y_right_eye

getEyePositionDuringCalib(x_screen, y_screen, eye_to_verify)

Tells the camera to get eye position now.

This function is to be called during calibration, when there is a focus point displayed on the stimulus display.

Parameters:
  • x_screen (float) – x-coordinate of the stimulus

  • y_screen (float) – y-coordinate of the stimulus

You (will be able to soon) to call this soon after stimulus is displayed (~500 ms after) since the tracker will wait for a fixation itself.

getImagePtr()

Allocates memory for the image data to be stored in ram and return a int pointing to it.

getLEDintensity()

Get the len intensity of the IR led connected to the camera tracker.

Returns:

Value of the intensity between 1 to 8.

Return type:

int

getLens()

Returns the lens type currently selected.

Lens can take three different values:
  • 0 (25mm)

  • 1 (50mm)

  • 2 (75mm)

getTargetCalibrationImages(fileNamePrefix, path, disableMedianFilter, disableHDR)

Save 16 frames images in the png format to disk

getTime()

Gets the device time from DataPixx since power up.

Returns:

Time in seconds.

Return type:

float

hideOverlay()

Desactivate Datapixx3 Overlay to display the eye image and eye cursors on monitor.

isDeviceCalibrated()

Returns the calibrated state of the tracker.

Returns:

True when tracked has been successfully calibrated, false otherwise.

isSleepMode()

Returns True if TRACKPixx sleep mode is enabled.

loadCalibration()

Load calibration saved to tracker

open()

Opens a TrackPixx device.

This method is used to get a handle on a TrackPixx device.

saveBufferedData()

Save from last_read_address up to TPxGetReadAddr(), into the default file for today.

saveCalibration()

Save last executed calibration to tracker

setDistance(distance)

Sets the current setup tracking distance in cm. This is used along with lens to determine the iris size.

setEyePositionToPROPIxx(eye_x_final, eye_y_final)

Provide the position of eyes to the PROPIXX

setIrisSize(lens, dist=0)

Set the iris size depending of lens type and distance

Parameters:
  • lens (int) – Diameter of the len in millimeter (25, 50,75).

  • dist (int) – Distance between the camera and the observer.

setLEDintensity(led_intensity)

Set the len intensity of the IR led connected to the camera tracker.

Parameters:

led_intensity (int) – Value of the intensity between 1 to 8.

setLens(lens)

Sets the lens specified to Datapixx3. This will have an impact on camera object image size calculation.

Lens can take three different values:
  • 0 (25mm)

  • 1 (50mm)

  • 2 (75mm)

setScreenProportionToCalibrate(proportion)

Set the proportion of the screen to calibrate (TRACKPixx-mini only)

setSleepMode(enable)

Enables or disables the sleep mode.

Enabling this mode turns the TRACKPixx off. Disabling it will turn the TRACKPixx on.

Parameters:

enable (bool) – Set to true to enable sleep mode.

setUpDataRecording(saveFolder)

Set up the the base address and buffer size for schedule recording of TRACKPixx data.

showOverlay(presetDisposition='FULL_STIMULI_HALF_TRACK')

Activate Datapixx3 Overlay to display the eye image and eye cursors on monitor.

class tracker.TRACKPixxMini

Bases: Tracker

This class is the concrete class specific to TRACKPixx-mini Tracker only .

close()

Closes a TrackPixx device.

This method is used to release a handle on a TrackPixx device.

finishCalibration()

Finishes the calibration on the Device.

This function is to be called when you are done displaying stimuli for calibration. It will calculate the calibrations parameter on the device and set the state to calibrated (which can be verified through isDeviceCalibrated.

getEyePosition()

Returns the current gaze position by finding the best polynomial.

This returns the current calibrated gaze position on the screen using the calibration parameters found for the latest calibration.

Returns:

A list of gaze position, such that first elements are screen_x_left_eye, screen_y_left_eye, screen_x_right_eye, screen_y_right_eye

getEyePositionDuringCalib(x_screen, y_screen, eye_to_verify)

Tells the camera to get eye position now.

This function is to be called during calibration, when there is a focus point displayed on the stimulus display.

Parameters:
  • x_screen (float) – x-coordinate of the stimulus

  • y_screen (float) – y-coordinate of the stimulus

You (will be able to soon) to call this soon after stimulus is displayed (~500 ms after) since the tracker will wait for a fixation itself.

getImagePtr()

Allocates memory for the image data to be stored in ram and return a int pointing to it.

getName()

Return part number

isDeviceCalibrated()

Returns the calibrated state of the tracker.

Returns:

True when tracked has been successfully calibrated, false otherwise.

open(licenseFileDir='')

Opens a TrackPixx device.

This method is used to get a handle on a TrackPixx device.

saveBufferedData()

Save from last_read_address up to TPxGetReadAddr(), into the default file for today.

setScreenProportionToCalibrate(proportion)

Set the proportion of the screen to calibrate (TRACKPixx-mini only)

setUpDataRecording(saveFolder)

Set up the the base address and buffer size for schedule recording of TRACKPixx data.

class tracker.Tracker

Bases: object

This class is the bridge between C commands that access device and python commands. When you initiate a new device Access object, all functions are loaded from a .DLL file, and the appropriate C types conversion happen. After that, new functions are created with more Pythonic names that handle the calling of C functions.

classmethod buildTrackerObject(cls)

Return a specific object on the detected tracker

calibrateBuiltInTarget(targetIndex)

“Calibrate a target with built-in calibration (TRACKPixx-mini only).

Parameters:

targetIndex (int) – Index of the target to calibrate.

clearDeviceCalibration()

Clear calibration from tracker, making device not calibrated

close()

Closes a TrackPixx device.

This method is used to release a handle on a TrackPixx device.

convertCoordSysToCartesian(inList)

Convert custom coordinate to system coordinate.

Parameters:

inList (List) – List of coordinates to convert.

Returns:

List of coordinates to converted.

Return type:

(List)

convertCoordSysToCustom(inList)

Convert custom coordinate to system coordinate.

Parameters:

inList (List) – List of coordinates to convert.

Returns:

List of coordinates to converted.

Return type:

(List)

finalizeBuiltInCalibration()

Finalize the built-in calibration (TRACKPixx-mini only)

Returns:

Retrun 0 if the calibration is finished properly.

Return type:

int

finishCalibration()

Finishes the calibration on the Device.

This function is to be called when you are done displaying stimuli for calibration. It will calculate the calibrations parameter on the device and set the state to calibrated (which can be verified through isDeviceCalibrated.

getDistance()

Returns the tracking distance in cm.

This returns the current distance set in tracker in cm. This is used along with lens to determine the iris size.

Returns:

The distance in cm

getEyePosition()

Returns the current gaze position by finding the best polynomial.

This returns the current calibrated gaze position on the screen using the calibration parameters found for the latest calibration.

Returns:

A list of gaze position, such that first elements are screen_x_left_eye, screen_y_left_eye, screen_x_right_eye, screen_y_right_eye

getEyePositionDuringCalib(x_screen, y_screen, eye_to_verify)

Tells the camera to get eye position now.

This function is to be called during calibration, when there is a focus point displayed on the stimulus display.

Parameters:
  • x_screen (float) – x-coordinate of the stimulus

  • y_screen (float) – y-coordinate of the stimulus

You (will be able to soon) to call this soon after stimulus is displayed (~500 ms after) since the tracker will wait for a fixation itself.

getImagePtr()

Allocates memory for the image data to be stored in ram and return a int pointing to it.

getLEDintensity()

Get the len intensity of the IR led connected to the camera tracker.

Returns:

Value of the intensity between 1 to 8.

Return type:

int

getLens()

Returns the lens type currently selected.

Lens can take three different values:
  • 0 (25mm)

  • 1 (50mm)

  • 2 (75mm)

getTime()

Gets the device time from DataPixx since power up.

Returns:

Time in seconds.

Return type:

float

hideOverlay()

Desactivate Datapixx3 Overlay to display the eye image and eye cursors on monitor.

initializeBuiltInCalibration()

Initialize the built-in calibration (TRACKPixx-mini only)

isDeviceCalibrated()

Returns the calibrated state of the tracker.

Returns:

True when tracked has been successfully calibrated, false otherwise.

isSleepMode()

Returns True if TRACKPixx sleep mode is enabled.

loadCalibration()

Load calibration saved to tracker

open()

Opens a TrackPixx device.

This method is used to get a handle on a TrackPixx device.

saveBufferedData()

Save from last_read_address up to TPxGetReadAddr(), into the default file for today.

saveCalibration()

Save last executed calibration to tracker

setActive()

Use to fake calls on dpxDevice

setDistance(distance)

Sets the current setup tracking distance in cm. This is used along with lens to determine the iris size.

setEyePositionToPROPIxx(eye_x_final, eye_y_final)

Provide the position of eyes to the PROPIXX

setIrisSize(lens, dist=0)

Set the iris size depending of lens type and distance

Parameters:
  • lens (int) – Diameter of the len in millimeter (25, 50,75).

  • dist (int) – Distance between the camera and the observer.

setLEDintensity(led_intensity)

Set the len intensity of the IR led connected to the camera tracker.

Parameters:

led_intensity (int) – Value of the intensity between 1 to 8.

setLens(lens)

Sets the lens specified to Datapixx3. This will have an impact on camera object image size calculation.

Lens can take three different values:
  • 0 (25mm)

  • 1 (50mm)

  • 2 (75mm)

setScreenProportionToCalibrate(proportion)

Set the proportion of the screen to calibrate (TRACKPixx-mini only)

setSleepMode(enable)

Enables or disables the sleep mode.

Enabling this mode turns the TRACKPixx off. Disabling it will turn the TRACKPixx on.

Parameters:

enable (bool) – Set to true to enable sleep mode.

setUpDataRecording(saveFolder)

Set up the the base address and buffer size for schedule recording of TRACKPixx data.

showOverlay(presetDisposition='FULL_STIMULI_HALF_TRACK')

Activate Datapixx3 Overlay to display the eye image and eye cursors on monitor.

updateRegisterCache()

Use to fake calls on dpxDevice

JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.