Format of the SimpleGazeTracker CSV data file (version 0.5.2 or earlier)¶
Here is a sample of the SimpleGazeTracker CSV data file.
If settings are sent from the Presentation PC by using sendSettings()
, recording conditions are output (line 1-3).
Following it, data blocks are output.
注釈
sendSettings is deprecated in 0.11.0 or later.
Use "config" option of openDataFile()
instead.
A data block starts with #START_REC and ends with #STOP_REC, which are inserted by startRecording()
and stopRecording()
, respectively.
Numbers after #START_REC shows recorded year, month, day, hour, minute and second.
#MESSAGE is inserted if startRecording() is called with a message string (line 5).
#XPARAM and #YPARAM indicate calibration parameters (line 6-7).
#CALPOINT is position of calibration target to calculate calibration parameters (i.e. #XPARAM and #YPARAM) (line 8-16).
If you use 9 positions for calibration, 9 #CALPOINT lines are output.
The recorded data follows these lines (line 17-). The first element of the recorded data is the timestamp when the gaze position is recorded. The second and the thrid element indicate horizontal and vertical gaze position in the screen coordinate if recording mode is monocluar. If recording mode is binocular, the second and third element indicate horizontal and vertical gaze position of the left eye, and the fourth and fifth element indidate gaze position of the right eye.:
001: #SCREEN_WIDTH,1920
002: #SCREEN_HEIGHT,1080
003: #VIEWING_DISTANCE,57.3
004: #START_REC,2012,1,30,16,10,24
005: #MESSAGE,0,trial1
006: #XPARAM,-53.020081,-2.346666,979.127991,0.000000,0.000000
007: #YPARAM,-0.342159,-66.443535,-397.927063,0.000000,0.000000
008: #CALPOINT,960,290
009: #CALPOINT,1310,790
010: #CALPOINT,610,790
011: #CALPOINT,960,540
012: #CALPOINT,1310,540
013: #CALPOINT,960,790
014: #CALPOINT,610,290
015: #CALPOINT,1310,290
016: #CALPOINT,610,540
017: 1.2,618.3,515.7
018: 2.6,622.7,509.0
019: 4.4,622.9,525.8
At the end of the data block, messages inseted by sendMessage()
, are output (line 825-837).
If recording duration is very long (depending on sampling frequency of the camera), messages are output in between the recorded data to prevent buffer overrun.
#STOP_REC is output at the end of the block (line 838).:
825: 6781.7,1165.4,444.3
826: 6790.6,1173.3,440.3
827: #MESSAGE,500.0,STIM 960 540
828: #MESSAGE,1516.5,STIM 860 740
(snip)
837: #MESSAGE,10516.0,STIM 960 340
838: #STOP_REC
If several pair of startRecording() and stopRecording() are called in a single recording, corresponding number of data block are output in a single data file.
Format of the SimpleGazeTracker CSV data file (0.5.3 to 0.6.6)¶
Data file generated by SimpleGazeTracker 0.5.3 is the same as those generated by 0.5.2 or former except following points.
The first line of the data file is a string 'SimpleGazeTrackerDataFile' (line 1).
Version of SimpleGazeTracker is declared by #TRACKER_VERSION (line 2).
Data format is declared by #DATAFORMAT (line 3). This indicates what each column of the data represents. For example, if value of this option is 'T,X,Y,P', the data was recorded in the monocular mode. The first column corresponds to the timestamp. The second and the third column correspond to horizontal and vertical gaze position, respectively. The fourth column corresponds to pupil size.
Symbol |
Description |
Recording mode |
---|---|---|
T |
Timestamp (msec) |
Both (monocular/binocular) |
X |
Horizontal gaze position |
Monocular |
Y |
Vertical gaze position |
Monocular |
P |
Pupil size |
Monocular |
LX |
Horizontal gaze position of the left eye |
Binocular |
LY |
Vertical gaze position of the left eye |
Binocular |
RX |
Horizontal gaze position of the right eye |
Binocular |
RY |
Vertical gaze position of the right eye |
Binocular |
LP |
Left pupil size |
Binocular |
RP |
Right pupil size |
Binocular |
C |
Camera-specific data |
Both (monocular/binocular) Available only when camera-specific data is enabled. new in 0.6.5 |
001: #SimpleGazeTrackerDataFile
002: #TRACKER_VERSION,0.5.3
003: #DATAFORMAT,T,X,Y,P
004: #SACCADE_MINIMUM_DURATION,12
005: #SACCADE_ACCELERATION_THRESHOLD,3800.0
006: #SCREEN_WIDTH,1920
007: #FILTER_WN,0.25
008: #DOTS_PER_CENTIMETER_H,37.7
009: #TRACKER_ORIGIN,BottomLeft
009: #RECORDED_EYE,L
010: #FILTER_ORDER,3
011: #BLINK_MINIMUM_DURATION,50
012: #FILTER_SIZE,5
013: #FILTER_TYPE,butter_filtfilt
014: #DOTS_PER_CENTIMETER_V,37.7
015: #VIEWING_DISTANCE,57.2957795131
016: #SACCADE_VELOCITY_THRESHOLD,40.0
017: #SCREEN_ORIGIN,BottomLeft
018: #FIXATION_MINIMUM_DURATION,12
019: #SCREEN_HEIGHT,1080
020: #START_REC,2012,10,3,21,24,51
021: #MESSAGE,0,trial1
022: #XPARAM,-69.290479,5.310818,969.443606
023: #YPARAM,-8.161037,-93.216076,-449.842138
024: #CALPOINT,610.000000,290.000000
025: #CALPOINT,1310.000000,540.000000
026: #CALPOINT,610.000000,540.000000
027: #CALPOINT,960.000000,790.000000
028: #CALPOINT,610.000000,790.000000
029: #CALPOINT,1310.000000,290.000000
030: #CALPOINT,1310.000000,790.000000
031: #CALPOINT,960.000000,290.000000
032: #CALPOINT,960.000000,540.000000
033: 0.000,957.5,526.4,132.1
034: 0.375,952.8,530.0,131.5
035: 2.440,943.6,562.6,126.8
036: 5.033,945.3,586.4,129.1
Format of the SimpleGazeTracker CSV data file (0.7.0)¶
Data file generated by SimpleGazeTracker 0.7.0 is the same as those generated by 0.6.6 or former except USBIO data.
In 0.7.0, the #DATAFORMAT line includes 'USBIO' symbol if USB inputs are recorded.
Symbol |
Description |
Recording mode |
---|---|---|
USBIO |
USB analog/digital input |
Availabe only when USB-IO unit is connected. new in 0.7.0 |
'USBIO' is followed by a list of channel names (semicolon-separated) like this. In this example, two analog inputs (AD0, AD1) and one digital input are recorded in this order.
#DATAFORMAT,T,X,Y,P,USBIO;AD0;AD1;DI
In the data line, USB inputs are recorded as a list of semicolon-separared values. Order of the values corresponds with that of channel names in the #DATAFORMAT line. In this example, value of AD0, AD1 and DI are 2044, 1920 and 255, respectively.
5.033,945.3,586.4,129.1,2044;1920;255
Format of the SimpleGazeTracker CSV data file (0.8.0)¶
#CALPOINT information is extended in SimpleGazeTracker 0.8.0. In addition to calibration target location, accuracy (mean deviation from target location) and standard deviation (standard variation of deviation) are output.
001: #CALPOINT,350.000000,-250.000000,-19.581205,10.108988,2.099655,2.640429
002: #CALPOINT,0.000000,250.000000,-15.328429,20.622807,6.183005,2.492021
003: #CALPOINT,0.000000,0.000000,15.916396,-8.670573,5.431423,1.244815
004: #CALPOINT,0.000000,-250.000000,-9.560707,18.605805,1.590791,2.255189
005: #CALPOINT,-350.000000,-250.000000,8.718887,-0.562188,8.252490,1.475270
006: #CALPOINT,350.000000,0.000000,21.822557,-23.568509,1.378845,4.085564
007: #CALPOINT,-350.000000,0.000000,-1.987498,-16.536330,2.827205,1.075086
008: #CALPOINT,-350.000000,250.000000,NO_CALIBRATION_DATA,NO_CALIBRATION_DATA,NO_CALIBRATION_DATA,NO_CALIBRATION_DATA
009: #CALPOINT,350.000000,250.000000,NO_CALIBRATION_DATA,NO_CALIBRATION_DATA,NO_CALIBRATION_DATA,NO_CALIBRATION_DATA
In the above example, nine lines of #CALPOINT are output, which indicate that nine location was used for calibration. If recording mode is monocular, six values follow #CALPOINT. Unit of these values is pix. As shown in line 8 and 9 of above example, accuracy and precision value is NO_CALIBRATION_DATA if no gaze data is recorded at that location.
Horizontal (X) location of the calibration tareget.
Vertical (Y) location of the calibration tareget.
Accuracy in horizontal direction.
Accuracy in vertical direction.
Precision in horizontal direction.
Precision in vertical direction.
For binocular recording, 10 values follow #CALPOINT.
Horizontal (X) location of the calibration tareget.
Vertical (Y) location of the calibration tareget.
Accuracy in horizontal direction (Left eye).
Accuracy in vertical direction (Left eye).
Accuracy in horizontal direction (Right eye).
Accuracy in vertical direction (Right eye).
Precision in horizontal direction (Left eye).
Precision in vertical direction (Left eye).
Precision in horizontal direction (Right eye).
Precision in vertical direction (Right eye).
#CALPOINT is output everytime when recording is started. If multiple calibrations are performed during experiment, results of the latest calibration is output.
After calibration or validation is performed, detailed calibration/validation data can be saved to SimpleGazeTracker data file by pressing "s" key. Note that "s" key must be pressed before pressing ESC/q key. Following shows an example of detailed calibration data.
#START_DETAIL_CALDATA,2015,3,6,18,16,23
#CALDATA,350.0,-250.0,-1.05,-46.14,332.28,-241.30,1691.67
#CALDATA,350.0,-250.0,-0.86,-46.18,329.64,-240.28,1690.19
#CALDATA,350.0,-250.0,-0.85,-46.19,329.64,-240.15,1685.20
#CALDATA,350.0,-250.0,-0.85,-46.16,329.49,-240.58,1680.15
#CALDATA,350.0,-250.0,-0.85,-46.19,329.65,-240.13,1679.15
#CALDATA,350.0,-250.0,-0.92,-46.27,330.73,-238.90,1675.76
#CALDATA,350.0,-250.0,-0.89,-46.32,330.36,-238.00,1671.90
#CALDATA,350.0,-250.0,-0.84,-46.16,329.33,-240.63,1669.51
#CALDATA,350.0,-250.0,-0.97,-46.27,331.35,-239.04,1661.06
#CALDATA,350.0,-250.0,-1.00,-46.22,331.70,-239.91,1656.95
#CALDATA,0.0,250.0,27.22,-75.03,-6.55,280.50,1430.19
#CALDATA,0.0,250.0,28.10,-74.29,-19.96,269.40,1426.26
#CALDATA,0.0,250.0,28.01,-73.95,-19.33,263.60,1428.38
#CALDATA,0.0,250.0,27.74,-74.32,-14.94,269.32,1423.63
#CALDATA,0.0,250.0,27.72,-74.37,-14.65,270.13,1419.19
#CALDATA,0.0,250.0,27.78,-74.40,-15.38,270.72,1420.18
#CALDATA,0.0,250.0,27.82,-74.32,-16.00,269.43,1419.26
#CALDATA,0.0,250.0,27.83,-74.43,-16.02,271.38,1412.89
#CALDATA,0.0,250.0,27.77,-74.40,-15.18,270.81,1419.36
#CALDATA,0.0,250.0,27.77,-74.41,-15.26,270.94,1415.47
#CALDATA,0.0,0.0,23.50,-57.80,14.74,-11.27,1417.33
#CALDATA,0.0,0.0,23.49,-57.97,15.13,-8.45,1413.10
#CALDATA,0.0,0.0,23.45,-58.00,15.82,-7.93,1418.18
#CALDATA,0.0,0.0,23.46,-58.04,15.72,-7.41,1418.36
#CALDATA,0.0,0.0,23.48,-58.00,15.40,-7.96,1422.51
#CALDATA,0.0,0.0,23.46,-57.97,15.57,-8.55,1425.75
#CALDATA,0.0,0.0,23.31,-58.02,17.81,-7.87,1420.37
#CALDATA,0.0,0.0,23.38,-58.03,16.84,-7.59,1415.73
#CALDATA,0.0,0.0,23.38,-57.83,16.41,-10.88,1421.57
#CALDATA,0.0,0.0,23.45,-57.95,15.74,-8.81,1419.24
(snip)
#END_DETAIL_CALDATA
Calibration data starts with #START_DETAIL_CALDATA. Numbers following #START_DETAIL_CALDATA represents when "s" key is pressed (year, month, date, hour, min, sec). #START_DETAIL_CALDATA is followed by #CALDATA lines. In #CALDATA lines, following values are output.
Monocular
horizontal location of calibration target
vertical location of calibration target
horizontal distance between pupil and Purkinje image in the camera image
vertical distance between pupil and Purkinje image in the camera image
estimation of horizontal gaze location
estimation of vertical gaze location
pupil diameter.
binocular
horizontal location of calibration target
vertical location of calibration target
horizontal distance between pupil and Purkinje image in the camera image (Left eye)
vertical distance between pupil and Purkinje image in the camera image (Left eye)
horizontal distance between pupil and Purkinje image in the camera image (Right eye)
vertical distance between pupil and Purkinje image in the camera image (Right eye)
estimation of horizontal gaze location (Left eye)
estimation of vertical gaze location (Left eye)
estimation of horizontal gaze location (Right eye)
estimation of vertical gaze location (Right eye)
pupil diameter (Left eye)
pupil diameter (Right eye)
Calibration data finishes with #END_DETRAIL_CALDATA. For validation data, #START_DETAIL_VALDATA and #END_DETRAIL_VALDATA are used instead of #START_DETAIL_CALDATA and #END_DETRAIL_CALDATA.