Preview only show first 10 pages with watermark. For full document please download

Fpga In Advanced Vision Applications

   EMBED


Share

Transcript

FPGA in Advanced Vision Applications Rostislav Halaš Regional Product Engineer Embedded Systems National Instruments ni.com Tools for Measurement, Control and Automated Test Advanced Manufacturing Aerospace and Defense Energy Transportation Platform - Software ni.com Platform2 – hardware Consumer Electronics Wireless Multicore CPU systems • • • Ride the CPU frequency wave Automatic hardware acceleration (SSE, Hyperthreading) Making software multithreaded • • • • • OpenMP (multiple cores) MPI (multiple separate machines) Vision Development Module Some problems divide well Others don’t ni.com 3 FPGAs • • • • • • • • • Latency Jitter Compute power Pipelining Security Weight / Power / Heat Complexity Raw Clock Rates Limited Floating Point support ni.com 4 Latency - Preprocessing Exp Exp Readout Processing Loop Period Loop Period ni.com 5 Latency – Co-processing Exp Exp Readout Processing Loop Period ni.com 6 Latency – Co-processing Exp Exp Readout Loop Period ni.com 7 Complexity Counter Analog I/O VHD ~4000 lines L LabVIEW FPGA ni.com I/O with DMA 8 FPGA Use Modes Visualization Camera Monitor Memory FPGA Acquisition Logic Video Generation FPGA Inline Processing Image Acquisition Device High-speed Control CPU Camera FPGA Acquisition Logic Memory Host Actuator Digital or Analog I/O Memory FPGA Inline Processing Memory Image Acquisition Device Image Preprocessing Memory Acquisition Logic CPU FPGA Camera Memory ni.com Memory CPU FPGA Processing FPGA Inline Processing Image Acquisition Device Host Co-Processing FPGA Camera CPU Acquisition Logic Image Acquisition Device Host 9 Memory Host Image Processing and Visualization ni.com • FPGA is directly in the path of the image data • Processes pixels as they arrive • May require some buffering—2D kernel operations • Generates and outputs images directly or send result to host CPU 10 NI FPGA Hardware • NI FlexRIO + NI 1483 adapter module • PCIe-1473R • • • LabVIEW FPGA example programs • • • • ni.com Base, medium or full configuration cameras General purpose digital I/O Area scan and linescan image acquisition Threshold Centroid Bayer decoding 11 FlexRIO for PXI System Architecture I/O FPGA 132 DIO ni.com Processor PCIe FlexRIO Adapter Module FlexRIO FPGA Module Camera Link Module Kintex-7 FPGA Up to 2 GB of DRAM PCIe Gen 2 x 8 12 PXI Platform Embedded Controllers Synchronization Data streaming Power/cooling Visualization • Image transformation • • • Feature highlighting • • • Image warping, rotation and flip Image compression, encryption, and authentication Filtering Shading correction Noise reduction • • ni.com Image averaging Retinex algorithm 13 Image Processing Functions FPGAs suitable to improve images and extract basic features • Preprocessing – – – – – – – – ni.com Image transforms Image operators Shading correction Bayer decoding Color space conversion 1D & 2D FFT Filtering (smooth/sharpen) Binary morphology • Feature Extraction – Edge, lines corners – Binary objects – Color • Measurements – Centroid – Area measurements 14 Image Processing Functions FPGAs not suitable for certain high-level algorithms • Object-level vision functions – – – – – ni.com Pattern matching OCR/OCV Barcode reading Some geometric measurements Classification 15 High-Speed Control • FPGA is directly in the path of the image data • FPGA generates and outputs control commands directly FPGA Memory Camera Acquisition Logic Actuator Digital I/O FPGA Inline Processing Memory Image Acquisition Device ni.com CPU 16 Host High-Speed Control • Laser alignment/steering – – • High-speed sorting – – – • Segmentation Measure parameters of contaminant Trigger rejection valves In Air Sorting – – ni.com Beam profile/position measurements Low latency control output Image and inspect falling product Low jitter requirement for decision making and IO 17 Example: Medical Imaging Challenge Develop the signal processing backend for an Optical Coherence Tomography machine. High Level Requirements Sample at 800 MS/s Control fast steering mirrors to perform raster scan Imaging in real-time Stream image data over the network ni.com 18 FlexRIO Optimized for Deployment I/O FPGA Processor 132 DIO Controller for FlexRIO FlexRIO Adapter Module Kintex-7 FPGA Dual-Core ARM Processor High Speed Serial NI Linux Real-Time OS Optimized for Size, Weight, Power Interchangeable I/O Analog, Digital, RF Custom I/O with MDK ni.com 19 OCT Solution with Controller for FlexRIO DRAM NI 5772 Acquisition Engine Form Image Write to Client 1 GbE Read from Client Configuration Galvo Control 2 Ch 800 MS/s 12-bit ni.com Remote Client Processor 20 Image Co-processing Memory CPU FPGA Processing FPGA Camera Memory Acquisition Logic Image Acquisition Device ni.com 21 Host Visual Servo Control Image Feedback CAPTURED IMAGES Move Complete ni.com VISION Image Capture MOTION 22 Visual Servo Control: Direct Servo Position Setpoint Control Loop Actuator 5ms Position Feedback ni.com Coordinate Transform Image Processing Camera Coordinate Transform Image Processing Camera 23 Target Performance Comparison Example ni.com 24 IC-3173 EtherCAT Master: Machine Controller Touchscreen HMI GigE (PoE) (EtherCAT) To the network or PC To industrial I/O AKD EtherCAT Servo Drive (EtherCAT) ni.com 25 Future Looking Projects Using FPGA Co-processing System On Module ni.com 26 You Might Want to Use an FPGA for Vision… • • • • • • • • ni.com If latency or jitter is critical If power consumption is critical If you have to speed up throughput If you can pipeline your algorithms If you have to reduce the amount of data or aggregate multiple high-speed channels If you are using algorithms that can take advantage of the FPGA architecture If the FPGA is already in the image path If any of the above give you a competitive advantage 27