gaze estimation with pupil tracking in...

39
Gaze Estimation with Pupil Tracking in Real-Time Final Presentation Tomas Bartipan Supervisor: Benjamin Busam Technical University of Munich Chair of Computer Aided Medical Procedures Project Management and Software Development for Medical Applications February 1, 2018 [email protected] Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 1

Upload: others

Post on 23-Jul-2020

2 views

Category:

Documents


0 download

TRANSCRIPT

Page 1: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Gaze Estimation with Pupil Tracking inReal-Time

Final Presentation

Tomas BartipanSupervisor: Benjamin Busam

Technical University of MunichChair of Computer Aided Medical Procedures

Project Management and Software Development for Medical Applications

February 1, 2018

[email protected]

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 1

Page 2: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Recap

Figure: NIR light reflection and eye schematic

Source:Real-Time Eye Gaze Tracking Under Natural Head Movementshttps://www.ecse.rpi.edu/~cvrl/zhiwei/gazetracking/

gazetracking.html

Accessed: 9/11/17

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 2

Page 3: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Recap hardware

Figure: Hardware in use

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 3

Page 4: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

The steps to get there

1 Locate eye region (Haar)

2 Locate iris center (Snakuscule)

3 Locate glint (Ellipse fitting)

4 Calculate gaze from iris-glint vector and eye position (Linearregression)

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 4

Page 5: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

The steps to get there

1 Locate eye region (Haar)

2 Locate iris center (Snakuscule)

3 Locate glint (Ellipse fitting)

4 Calculate gaze from iris-glint vector and eye position (Linearregression)

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 4

Page 6: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

The steps to get there

1 Locate eye region (Haar)

2 Locate iris center (Snakuscule)

3 Locate glint (Ellipse fitting)

4 Calculate gaze from iris-glint vector and eye position (Linearregression)

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 4

Page 7: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

The steps to get there

1 Locate eye region (Haar)

2 Locate iris center (Snakuscule)

3 Locate glint (Ellipse fitting)

4 Calculate gaze from iris-glint vector and eye position (Linearregression)

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 4

Page 8: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Snakuscule

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 5

Page 9: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Example Pass

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 6

Page 10: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Glint detection

1 Locate the brightest pixels in cornea region

2 Find a contour3 Fit an ellipse

Get a proper light! Until then, just use a point.

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 7

Page 11: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Glint detection

1 Locate the brightest pixels in cornea region

2 Find a contour3 Fit an ellipse

Get a proper light! Until then, just use a point.

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 7

Page 12: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Glint detection

1 Locate the brightest pixels in cornea region

2 Find a contour3 Fit an ellipse

Get a proper light! Until then, just use a point.

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 7

Page 13: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Glint detection

1 Locate the brightest pixels in cornea region

2 Find a contour3 Fit an ellipse

Get a proper light! Until then, just use a point.

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 7

Page 14: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Glint fit

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 8

Page 15: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Last step - Linear regression

1 Create a polynomial transformation function

2 Input(variables) = eye center position, glint parameters

3 Output = screen coordinates

4 In callibration phase, let user look at many (15-30) points andcalculate polynomial coefficients that minimize squared error

5 In action phase, plug the actual values into the polynomial

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 9

Page 16: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Last step - Linear regression

1 Create a polynomial transformation function

2 Input(variables) = eye center position, glint parameters

3 Output = screen coordinates

4 In callibration phase, let user look at many (15-30) points andcalculate polynomial coefficients that minimize squared error

5 In action phase, plug the actual values into the polynomial

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 9

Page 17: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Last step - Linear regression

1 Create a polynomial transformation function

2 Input(variables) = eye center position, glint parameters

3 Output = screen coordinates

4 In callibration phase, let user look at many (15-30) points andcalculate polynomial coefficients that minimize squared error

5 In action phase, plug the actual values into the polynomial

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 9

Page 18: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Last step - Linear regression

1 Create a polynomial transformation function

2 Input(variables) = eye center position, glint parameters

3 Output = screen coordinates

4 In callibration phase, let user look at many (15-30) points andcalculate polynomial coefficients that minimize squared error

5 In action phase, plug the actual values into the polynomial

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 9

Page 19: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Last step - Linear regression

1 Create a polynomial transformation function

2 Input(variables) = eye center position, glint parameters

3 Output = screen coordinates

4 In callibration phase, let user look at many (15-30) points andcalculate polynomial coefficients that minimize squared error

5 In action phase, plug the actual values into the polynomial

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 9

Page 20: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Linear regression is simple, but hard to do right!

1 Needs many callibration points

2 Coefficients need to have the same order of magnitude.

3 Small noise in callibration data results in big errors

4 Better to use non-realtime methods in callibration phase

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 10

Page 21: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Linear regression is simple, but hard to do right!

1 Needs many callibration points

2 Coefficients need to have the same order of magnitude.

3 Small noise in callibration data results in big errors

4 Better to use non-realtime methods in callibration phase

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 10

Page 22: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Linear regression is simple, but hard to do right!

1 Needs many callibration points

2 Coefficients need to have the same order of magnitude.

3 Small noise in callibration data results in big errors

4 Better to use non-realtime methods in callibration phase

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 10

Page 23: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Linear regression is simple, but hard to do right!

1 Needs many callibration points

2 Coefficients need to have the same order of magnitude.

3 Small noise in callibration data results in big errors

4 Better to use non-realtime methods in callibration phase

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 10

Page 24: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Callibration Phase

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 11

Page 25: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Running Phase

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 12

Page 26: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Status report

Eye center localization - done!

Could be more stable...

Glint fitting - done!

Needs bigger lights to be actual ellipse fitting.

Callibration data acquisition - done!

Works fine.

Linear regression - (kind of) done!

Can’t get it right! :(

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 13

Page 27: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Status report

Eye center localization - done!

Could be more stable...

Glint fitting - done!

Needs bigger lights to be actual ellipse fitting.

Callibration data acquisition - done!

Works fine.

Linear regression - (kind of) done!

Can’t get it right! :(

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 13

Page 28: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Status report

Eye center localization - done!

Could be more stable...

Glint fitting - done!

Needs bigger lights to be actual ellipse fitting.

Callibration data acquisition - done!

Works fine.

Linear regression - (kind of) done!

Can’t get it right! :(

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 13

Page 29: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Status report

Eye center localization - done!

Could be more stable...

Glint fitting - done!

Needs bigger lights to be actual ellipse fitting.

Callibration data acquisition - done!

Works fine.

Linear regression - (kind of) done!

Can’t get it right! :(

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 13

Page 30: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Status report

Eye center localization - done!

Could be more stable...

Glint fitting - done!

Needs bigger lights to be actual ellipse fitting.

Callibration data acquisition - done!

Works fine.

Linear regression - (kind of) done!

Can’t get it right! :(

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 13

Page 31: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Status report

Eye center localization - done!

Could be more stable...

Glint fitting - done!

Needs bigger lights to be actual ellipse fitting.

Callibration data acquisition - done!

Works fine.

Linear regression - (kind of) done!

Can’t get it right! :(

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 13

Page 32: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Status report

Eye center localization - done!

Could be more stable...

Glint fitting - done!

Needs bigger lights to be actual ellipse fitting.

Callibration data acquisition - done!

Works fine.

Linear regression - (kind of) done!

Can’t get it right! :(

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 13

Page 33: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Status report

Eye center localization - done!

Could be more stable...

Glint fitting - done!

Needs bigger lights to be actual ellipse fitting.

Callibration data acquisition - done!

Works fine.

Linear regression - (kind of) done!

Can’t get it right! :(

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 13

Page 34: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

General Lessons learned

Never (ever, ever, EVER!) code C++ without a debugger.

Start earlier.

Linear regression is hard.

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 14

Page 35: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

General Lessons learned

Never (ever, ever, EVER!) code C++ without a debugger.

Start earlier.

Linear regression is hard.

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 14

Page 36: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

General Lessons learned

Never (ever, ever, EVER!) code C++ without a debugger.

Start earlier.

Linear regression is hard.

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 14

Page 37: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Task specific Lessons learned

Have to use more lights.

One gets occluded easily.

Use bigger lights for ellipse fitting.

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 15

Page 38: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

Task specific Lessons learned

Have to use more lights.

One gets occluded easily.

Use bigger lights for ellipse fitting.

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 15

Page 39: Gaze Estimation with Pupil Tracking in Real-Timecampar.in.tum.de/.../busam/2017WS_PMSD/PMSD_Final_Tomas.pdfChair of Computer Aided Medical Procedures Project Management and Software

That’s all, folks!

Questions?

Source: https://commons.wikimedia.org/wiki/File:Thats_all_folks.svg, Public DomainAll images without credit are my own work

Tomas Bartipan Gaze Estimation with Pupil Tracking in Real-Time 16