Use of Stereoscopic Imaging for Distance Determination
Total Page:16
File Type:pdf, Size:1020Kb
Indiana University-Purdue University Fort Wayne Department of Electrical and Computer Engineering ECE 406 Senior Engineering Design II Final Report Project Title: Use of Stereoscopic Imaging for Distance Determination Team Members: Andrew Fullenkamp Christopher Nei Kaleb Krempel Faculty Advisor: Elizabeth Thompson, Ph.D. Advisor: Timothy Loos, Ph.D. Date: 4/19/2016 Contents Acknowledgements .................................................................................................................... 4 Abstract/Summary ..................................................................................................................... 5 Section I: Problem Statement ..................................................................................................... 7 Introduction ............................................................................................................................ 7 Requirements and Specifications ........................................................................................... 7 Given Parameters or Quantities.............................................................................................. 7 Design Variables .................................................................................................................... 7 Limitation and Constraints ...................................................................................................... 7 Section II: Conceptual Designs .................................................................................................. 8 Camera Hardware .................................................................................................................. 8 Type 1: Digital Single Lens Reflex (DSLR) Cameras .......................................................... 8 Type 2: Point-And-Shoot Cameras...................................................................................... 8 Type 3: Web Cameras. ....................................................................................................... 8 Type 4: Prefabricated stereo camera. ................................................................................. 9 Image Processing Unit ........................................................................................................... 9 Option 1: Implement on a Raspberry Pi (RPi). .................................................................... 9 Option 2: Use an alternative micro-computer system. ........................................................10 Option 2a: Hummingboard .................................................................................................11 Option 2b: ASUS VivoMini .................................................................................................12 Option 3: Relay image data to a deployable PC application. ..............................................13 GUI for System Management (for embedded image processing platforms) ...........................14 Option 1: Connect a screen to the Image Processing Unit: ................................................14 Option 2: Run a web server on the Image Processing Unit: ...............................................14 Conceptual Designs ..............................................................................................................14 Design 1: A Simplified Approach. .......................................................................................14 Designs 2: Virtual Stereo Using Translational Camera .......................................................15 Design 3: Virtual Stereo Using an Array of Mirrors .............................................................16 Design 4: Implementation of Image Processing Application Option 3 .................................17 Section III: Summary of the Evaluation of the Conceptual Designs ...........................................19 Camera Type Selection .........................................................................................................19 System Configuration Selection .............................................................................................21 Section IV: A Detailed Design of the Selected Conceptual Design ............................................24 Theoretical Considerations ....................................................................................................24 Hardware ...............................................................................................................................24 Image Processing ..................................................................................................................27 P a g e | 1 The User Interface .................................................................................................................29 Stereo Camera Calibration ....................................................................................................30 Section V: Design Implementation ............................................................................................33 Construction of the Apparatus ...............................................................................................33 Stereo Camera Alignment .....................................................................................................34 Calibrating Individual Cameras ..............................................................................................35 Calibrating the Overall System ..............................................................................................37 User Interface for System Control ..........................................................................................41 Accessing the User Interface .............................................................................................41 System Home ....................................................................................................................43 Camera Trigger ..................................................................................................................45 User Targeting ...................................................................................................................46 Results Plot ........................................................................................................................49 Section VI: Testing ....................................................................................................................51 Position Estimate Accuracy ...................................................................................................51 Repeatability Considerations .................................................................................................53 Lighting and White Balance Considerations ..........................................................................54 Section VII: Cost Analysis .........................................................................................................58 Recommendations ....................................................................................................................59 Conclusion ................................................................................................................................59 References ...............................................................................................................................60 Appendix A: Intrinsic Parameters for Stereo Cameras from Camera Calibration Procedure. .....61 Interpretation of Intrinsic Parameters .....................................................................................61 Intrinsic Parameters of Left Stereo Camera ...........................................................................61 Intrinsic Parameters of Right Stereo Camra ..........................................................................62 Appendix B: Raw Calibration Point Data ...................................................................................63 Appendix C: Source Code for System User Interface ................................................................68 /index.html .............................................................................................................................68 /interfaceStyles.css................................................................................................................70 /TargetCounts.php .................................................................................................................71 /cgi-bin/CameraInit.sh ............................................................................................................71 /cgi-bin/CameraTrigger.html ..................................................................................................72 /cgi-bin/CameraTrigger.sh .....................................................................................................72 /UserTargeting/index.html......................................................................................................73 /cgi-bin/ImportCSV.php .........................................................................................................82 /cgi-bin/ExportCSV.php .........................................................................................................83 P a g e | 2 /ResultsPlot/index.php ...........................................................................................................83 /ResultsPlot/CPointUndistort .................................................................................................86