Camera For Machine Vision
Camera For Machine Vision
com
PAGE 1
Introduction
This document provides the details of the various industrial cameras available in the market
for machine vision applications. The document covers details on the camera selection
based on the customer requirement, comparison of cameras and few application examples.
Cameras for image processing systems are categorized either as industrial/machine vision
(MV) or network/IP (Internet Protocol) cameras.
NETWORK CAMERAS:
Network cameras, also known as IP (Internet Protocol) cameras, record videos. They are
frequently used in classical surveillance applications. Network cameras acquire the images
and compress them. By connecting to a network, a theoretically unlimited number of users
can also access the camera.
INDUSTRIAL CAMERAS:
Industrial cameras by contrast send the images as uncompressed (‘raw’) data directly to
the processing node or cloud; The Processing node is then responsible for processing the
relatively large volume of data. The benefit of this method is that no image information is
lost.
There are two further subdivisions within the world of industrial cameras: Area scan and
line scan cameras.
Area scan cameras are equipped with a rectangular sensor featuring numerous lines of
pixels that are exposed at the same time. The image data is thus recorded in one single step
and is also processed in the same way.
The following are the list of Machine Vision applications for Area Scan Camera:
• In the automotive industry for inspection of individual parts, in control
engineering and robotics for the positioning of components and code identification,
paint defect inspection etc
• In electronics industry for inspection of components such as circuit boards,
soldering checks and pick & place processes.
• In the pharmaceutical and packaging industries for checks of production steps
and inspection for completeness, compliance with dimensional requirement and
detection of material flaws
• LCD Panel Inspection
• Solar Panel Inspection
PAGE 2
• Aerial Imaging
• Reconnaissance
•
Line scan cameras by contrast use one sensor comprised of just 1, 2 or 3 lines of pixels. The
image data is captured line by line, with the individual lines then reconstructed into an
entire image during the processing stage.
Line scan cameras are used universally when products must be inspected as they pass by on
conveyor belts – at times at extremely fast speeds.
1. Sensor Types
a. CMOS
b. CCD
2. Shutter Technique
a. Rolling Shutter
b. Global Shutter
3. Frame Rates: This term is synonymous with ‘frames per second’ or ‘fps’; For line
scan cameras, the terms ‘line rate’ or ‘line frequency’ are used. It describes the
number of images that the sensor can capture and transmit per second. The frame
rate varies from 10fps to 340 fps. The frame rate required is based on the Image
processing systems requirement.
4. Resolution: Resolution describes a measurement of the smallest possible distance
between two lines or points such that they can still be perceived as separate from
one another within the image.
Resolution=Object Size/ Size of the detail to be inspected
Example 1 : You’d like to capture a precision image of the eye color of a roughly 2m
tall person standing at a specific point:
Resolution= 2m/1mm = 2000 pxl
pxl in x and y=4 MP
PAGE 3
Eye detail1 mm :
A resolution of 4 megapixels is required to ensure that the 1 mm large detail for the eye
is clearly recognizable.
5. Interfaces: The interface serves as the liaison between the camera and Image
processing node, forwarding image data from the camera sensor to the
components that process the images, i.e. the hardware and software. The choice is
available between a variety of modern, widely available technologies
a. Camera Link
b. Gigabit Ethernet
c. USB3.0
d. CoAxpress Connector: CoaXPress (CXP) is the world’s leading standard for
high-speed imaging in professional and industrial imaging applications such
as machine vision, medical imaging, life sciences, broadcast and defence.
6. Housing Sizes
PAGE 4
The size of the camera housing is tied directly to the choice of interface. In
applications where cameras are organized next to one another (known as multicamera
setups) to better record the entire width of a material web, each millimeter of space
matters
RESOLUTION CALCULATION
Case 1:
Assume Customer Requirement:
1. Industry: Automotive
2. Use case: Paint Defect detection
3. Smallest defect size to be detected = 0.5 mm
4. Assume Object Size – 1mX1m (if the object size is bigger, we may need multiple
cameras)
5. Camera distance from the object – 2 m
6. The object will be there in front of the Camera Momentarily for a period of 4 – 5
seconds
Spatial resolution required which is the physical measurement a pixel represents 0.125 mm
i.e 4 pixel for the smallest possible element to be detected
Spatial resolution = 8000 in 1 axis
If the defect size is to be detected in the above case is 1 mm, then the camera resolution
required will be 16M
Case 2:
1. Industry: Automotive
2. Use case: Paint Defect detection
3. Smallest defect size to be detected = 0.5 mm
PAGE 5
4. Assume Object Size – 4mX 4m
5. Camera distance from the object – 2 m
6. The object will be there in front of the Camera Momentarily for a period of 4 – 5
seconds
Spatial resolution required which is the physical measurement a pixel represents 0.125 mm
i.e 4 pixel for the smallest possible element to be detected
Spatial resolution = 8000 in 1 axis
If the defect size is to be detected in the above case is 1 mm, then the camera resolution
required will be 16M
Example with Camera Vendor specification for the above requirement, the below is the
feasibility
If the FOV is 4mX4m and the minimum defect size is 0.7mm, you will need extremely high resolution cameras. ~ 20-30
MP.
In this case, camera will work like a scanner. The object have to move under the camera then it is possible to
scan the image. High precision is required in the setup so that you will get a very good image.
2) Use multiple area scan cameras and do stitching of images. Below is the specification of 12MP camera.
You will need at least 2 cameras to stitch.
https://www.baslerweb.com/en/products/cameras/area-scan-cameras/ace/aca4112-30um/
3) Use a 3D profiler incase the object is smaller in size and with curved surfaces
PAGE 6
LIST OF AREA SCAN CAMERAS AND THEIR SPECIFICATIONS
3 Model: SP- JAI CMOS , Area Scan 5120 x 3840 30fps CoaXPres
20000-CXP2- s
20M 2-
connector
(CXP2)
4 Model :SP- JAI CMOS, Area Scan 5120 x 3840 30fps Power
20000-PMCL - over
20 M Camera
Link
(PMCL)
Deca
5 SP-12000-CXP4 JAI CMOS Area SCAN 4096 x 3072 189fps CoaXPres
12M, s
4-
connector
(CXP2
6 Model: Basler CMOS Area SCAN 4608 px x 3288 7fps GigE
acA4600-7gc 14 px Vision
MP
Applications:
Machine Vision
Detection
Automotive
Manufacturing
Photo Voltaics
PAGE 7
7 Model: Basler CMOS Area SCAN 4608 px x 3288 10fps USB3.0
acA4600-10UC px
14 MP
Basler
8 Model : VC VieWorks CMOS Area Scan Upto 10000 × Upto 337 CoAx
Series 7096 fps Express
and
Camera
Link
PAGE 8
7 raL12288-8gm - Basler CMOS Line SCAN 12288 8 GiGE
Basler racer Vision
9 VT Series – M72 VieWorks CMOS Line SCAN 17824 x 256 250 CoaXPress
and
CameraLin
k
1 VT Series – M95 VieWorks CMOS Line SCAN 23360 x 256 140 CoaXPress
0
Precision 3D surface profiling can be essential for determining a surface suitability for its
intended purpose. Components failures can often be traced back to a precision surface
that was not manufactured to specification.
3D surface profiling is a general term which encompasses more specific types of
measurements such as surface shape, surface finish, surface profile roughness and surface
defects in a nm precision for smaller parts.
Recording 3D scenes requires camera systems that can sense the depth of information of
each corresponding pixel of an image, in addition to texture information (e.g. RGB). Those
cameras are also known as range or depth cameras. Capturing the third dimension can be
done in many ways, and each of the machine vision technologies available has its pros and
cons. The following gives a basic idea of different 3d imaging systems available.
PAGE 9
There are often many possible ways to solve a specific vision task. In some cases, the
choice of either 2D or 3D vision is obvious, but in other cases both technologies could
work though each provides certain benefits. It is important to understand these benefits
and how they apply to a given application in order to provide a reliable machine vision
solution. In general, 3D is best suited not only for analyzing volume, shape or 3D position
of objects, but also for detecting parts and defects that are low contrast but have a
detectable height difference. The third-dimension is mainly used for measuring,
inspecting and positioning, but there are also cases where 3D is used to read imprinted
code or text when contrast information is missing.
Capturing the third dimension can be done in many different ways, and each of the
machine vision technologies available has its pros and cons. Three-dimensional imaging
can be broken into two main categories: passive and active. From there it can be broken
into much more specific techniques. Passive techniques include depth from focus, light
field, and stereo. The main active techniques are based on time-of-flight, structured light,
and interferometry.
Three-dimensional imaging can be further broken down into how the image is actually
acquired, including snapshot and scanning methods.
The advantages and disadvantages of the four main 3-d imaging system is discussed
below:
PAGE 10
Choosing which type of 3D vision system to use is highly dependent on the parts that need
to be measured. While laser range finders using time of flight methods can be used to
locate distant objects, stereo imaging systems may be better suited to imaging high-
contrast objects. Where such objects are highly specular, it may be more useful to employ
projected texture techniques.
PAGE 11
Field of Application:
Because structured light is incorporated in the method, there are rarely issues with tricky
surfaces or low ambient light. Laser triangulation delivers highly precise data even for low
contrast objects. There is one problem with laser triangulation, however: it is relatively
slow and struggles to handle the ever-increasing speeds of modern production
environments. The scanning process requires that the object being measured comes to a
stop so that changes to the laser line can be recorded. Typical applications include
log/board/veneer wood inspection, electrical components/ solder paste inspection, and
food and packaging inspection applications.
Advantages:
Limitations:
PAGE 12
Why are 3D laser Profilers needed? 3D Laser Profiling vs. 2D Machine Vision:
Despite the proven advantages of 3D technology for inline quality inspection applications,
many organizations still rely solely on 2D machine vision for their quality control
processes.
While useful in a select number of scenarios, 2D vision is limited in its ability to achieve
100% quality control—which is why it is so important for organizations to invest in a
smart 3D solution. To illustrate this point we should compare the basic capabilities of a 3D
laser profiler to a 2D vision sensor.
3D Shape Measurement:
Apparent Size:
PAGE 13
It’s a different story with 3D. The depth measurement information provided by 3D laser
profilers eliminates errors due to object movement. This means objects can move
anywhere within the sensor’s measurement range and still yield accurate results—
effectively eliminating object fixturing requirements and improving overall measurement
reliability.
Contrast-Based Measurements:
PAGE 14
Industrial robots work in a three-
dimensional world. Unfortunately,
2D technology is unable to provide
the necessary depth and spatial
information (in 6 degrees of
freedom) for the growing number
of vision-guided robotics (VGR)
systems used for automated quality
control.
Laser profilers combine 3D and 2D capability for total quality inspection. In addition to 3D
shape measurements, the intensity of the projected laser or LED light is used to create a
2D image of the surface of a part. This information can be used to extract surface markings
like bar codes and printed text.
3D height map of a PCB captures shape data. Accompanying 2D intensity image captures surface
markings such as barcodes and printed text.
PAGE 15
LIST OF LASER PROFILE CAMERAS AND THEIR SPECIFICATIONS:
Camera Model Manufacturer Type of camera and Resolution and Scan Interface
and sensing Range Rate
Manufacturer
1. Model: DS1300 Cognex 3D Laser Measurement range Up-to 10 Gigabit
Applications : Displacement Sensor: 725 mm KHZ Ethernet
Measure laser profiler Resolution X (mm): interface
Heights, Verify 0.101–0.457 Integrate
Volumes, Laser Class: 2M Resolution Z (mm): d link
Determine 0.016–0.265
Presence/
absence of
components,
Identify surface
defects, Optical
character
recognition.
2. Model: DS1050 Cognex 3D Laser Measurement range Up-to 10 Gigabit
Applications : Displacement Sensor: 76 mm KHZ Ethernet
Measure laser profiler Resolution X (mm): interface
Heights, Verify 0.059–0.090 Integrate
Volumes, Laser Class: 2M Resolution Z (mm): d link
Determine 0.004–0.014
Presence/
absence of
components,
Identify surface
defects, Optical
character
recognition
PAGE 16
4 Model : Gocator LMI technologies 3d laser Point Profilers Measurement range Up-to 32 Gigabit
1390 2000 mm KHZ Ethernet
Applications: Laser Class: 3B Resolution X (mm):
surface Not Applicable
roughness, obje Resolution Z (mm):
ct thickness. .0250
6 Model: Gocator LMI technologies 3d laser Point Profilers Measurement range Up-to Gigabit
2380 6 mm 5KHZ Ethernet
Applications: Laser Class: 3R Resolution X (mm):
SCAN 0.0058 – 0.0062
MICRON- Resolution Z (mm):
LEVEL DETAILs 0.0011
7 Model: Gocator LMI technologies 3d laser Point Profilers Measurement range Up-to Gigabit
2410 800 mm 5KHZ Ethernet
Applications: Laser Class: 3R Resolution X (mm):
SCAN 0.375 - 1.100
MICRON- Resolution Z (mm):
LEVEL DETAILs 0.092 - 0.488
8 Model: Gocator LMI technologies 3d laser Point Profilers Measurement range Up-to Gigabit
2880 800 mm 2.5KHZ Ethernet
Applications: Laser Class: 3B Resolution X (mm):
scan micron- 0.375 - 1.100
level detail with Resolution Z (mm):
dual camera 0.092 - 0.488
scan
PAGE 17
Machine Vision Lighting:
1. Introduction
The one aspect of vision system design and implementation that consistently causes more
delays, cost overruns, and general consternation than other considerations, is lighting.
The key aspects of solutioning for machine vision lighting are:
Understanding of lighting types and application advantages and disadvantages, vision
camera and sensor quantum efficiency and spectral range, illumination techniques and
their application fields relative to surface flatness and surface reflectivity.
Familiarity with the major four factors of vision illumination: geometry, pattern or
structure, wavelength, and filters.
Detailed analysis of the immediate inspection environment (physical constraints and
requirements).
Appropriate lighting needs to deliver three acceptance criteria :
Maximize the contrast on those features of interest
Minimize the contrast elsewhere
Provide for a measure of robustness.
Fluorescent, quartz halogen, and LED are the most widely used lighting types in machine
vision, particularly for small- to medium-scale inspection stations. Metal halide, xenon,
and high-pressure sodium are more typically used in large-scale applications or in areas
requiring a very bright source. Metal halide, also known as mercury, is often used in
microscopy because it has many discrete wavelength peaks, which complements the use of
filters for fluorescence studies. A xenon source is useful for applications requiring a very
bright strobe light. Figure below shows the advantages and disadvantages of fluorescent,
quartz halogen, and LED lighting types and relevant selection criteria, as applied to
machine vision. For example, whereas LED lighting has a longer life expectancy, quartz
halogen lighting may be the choice for a particular inspection because it offers greater
intensity.
PAGE 18
In recent years, LED technology has improved in stability, intensity, and cost-
effectiveness; however, it is still not as cost-effective for large area lighting, particularly
compared with fluorescent sources. However, if application flexibility, output stability,
and longevity are important parameters, then LED lighting might be more appropriate. In
those applications requiring high light intensity, such as high-speed inspections, it may be
useful to match the source’s spectral output with the spectral sensitivity of the particular
vision camera. For example, CMOS sensor-based cameras are more IR sensitive than their
charge-coupled device (CCD) counterparts, imparting a significant sensitivity advantage
in light-starved inspection settings when using IR LED.
Contrast of the object in focus can be manipulated using the above four actors. Effecting
contrast changes through geometry involves moving the sample, light, and/or camera
positions until a suitable configuration can be found. For example, a coaxial ring light (one
mounted around the camera) may generate hotspot glare on a semi-reflective barcode
surface, but by simply moving the light off-axis, the hotspot glare is also moved out of the
camera’s view. Contrast changes through structure or the shape of the light projected on
the sample is generally lighting technique–specific. Contrast changes through color
lighting are related to differential color absorbance versus reflectance.
With respect to the lighting environment, there are two aspects to evaluate when
determining the optimal lighting solution:
PAGE 19
5. Illumination Techniques
Illumination techniques comprise back lighting, diffuse (also known as full bright field)
lighting, bright field (actually partial bright field or directional) lighting, and dark field
lighting.
The application of some techniques requires a specific light and geometry, or relative
placement of the camera, sample, and light—others do not. For example, a standard
bright field bar light may also be used in dark-field mode; whereas a diffuse light is used
exclusively as such.
Back Lighting:
Back lighting generates instant contrast as it creates dark
silhouettes against a bright background. The most common
uses are for detecting the presence/absence of holes and gaps,
part placing or orientating, or measuring objects. Often it is
useful to use a monochrome light, such as red, green, or blue,
with light control polarization if precise (subpixel) edge
detection becomes necessary.
PAGE 20
6. Application Fields:
Lighting Technique Application Fields: Surface Shape Versus Surface Reflectivity Detail
PAGE 21
Lenses for Camera
Usually an industrial camera does not have a lens. Instead, they come with a C-mount or
CS-mount. As these mounts are standardized, there is a wide range of lenses available for
industrial cameras. But choosing a lens for a particular solution takes a few steps of
calculation and selection based on the use case and ambience.
PAGE 22
Step 6: Calculating the focal length:
The Focal length is the central parameter of a lens. We can calculate it using the following
formula:
Basler, Zeiss, Tamron, Thorlabs, Aegis, Kowa are some of the leading lens vendors for
industrial cameras and machine vision.
PAGE 23
Special types of Lenses:
Vario lens
Vario lenses allow the manual variation of their focal length. Colloquially, this is called "to
zoom". But actually, vario lenses are not zoom lenses. If their focal length is varied,the
focus also has to be readjusted. The advantage of vario lenses: small, lightweight and low-
priced.
It is recommended to use vario lenses, if the machine vision application requires a short
focal length (wide angle).
Beyond their variable focal length, vario lenses are selected according to the rules that
apply to "normal" C-mount lenses.
Zoom lens
Zoom lenses are advanced vario lenses. We can vary their focal length (colloquially, "to
zoom" the lens) and they remain focused. In the case of manual zoom lenses this is
ensured opto-mechanically. Therefore, they are quite big, weighty and expensive.
In the case of industrial USB cameras, FireWire cameras or GigE cameras with integrated
lenses, the readjustment of the focus is performed by software.
Important: Besides their size and weight, manual zoom lenses have another
disadvantage. Their minimum object distance is usually one meter or even more. In
contrast to fixed focus C-mount lenses, the minimum object distance cannot be reduced
by extension rings: The lens would lose its capability to readjust the focus after it has been
zoomed.
Auto-focus lens
In the vast majority of machine vision applications, the basic optical parameters object
size and working distance are fixed. In such cases, C-mount lenses with a fixed focal
length and a manually adjustable focus are used.
If, however, the object size and/or the working distance are variable, the lens' focus has to
be adapted quickly to these variations. Ideally, the application software performs this
adaption based on an auto-focus algorithm. Hence, the focus mechanism of the lens must
have a motor so that it can be adjusted.
Auto-iris lens
One of the most important requirements for the realization of a simple machine vision
system is stable illumination. If this cannot be guaranteed, an auto-iris lens may be
helpful. Like the human eye, it adapts itself to environmental illumination, by opening
and closing its iris.
Outdoor surveillance cameras are fitted with auto-iris lenses by default. These lenses are
controlled directly by the surveillance camera. In machine vision applications, this direct
coupling is seldom acceptable. Thus, in the context of industrial cameras, the application
software should be responsible for the auto-iris control.
PAGE 24
LIST OF AUTOFOCUS AND ZOOM CAMERAS AND THEIR SPECIFICATIONS
One of the common use-cases of GPU is Video editing; while some powerful CPUs can
handle basic video editing, if you're working with large amounts of high-resolution files -
particularly 4K or 360-degree video - a high-end GPU is a must-have in order to transcode
the files at a reasonable speed.
PAGE 25
What to look for in a GPU?
There are main characteristics of a GPU related to DL are:
• Memory bandwidth — as discussed above, the ability of the GPU to handle large
amount of data. The most important performance metric.
• Processing power —indicates how fast your GPU can crunch data. We will
compute this as the number of CUDA cores multiplied by the clock speed of each
core.
• Video RAM size — the amount of data you can have on the video card at once. If
you are going to work with Computer Vision models, you want this to be as large
as affordable. Especially, if you want to do some CV Kaggle competitions. Amount
of VRAM is not so crucial for Natural Language Processing (NLP) and working
with categorical data.
Typical methods of increasing speed in image processing include the distribution of the
computing tasks between multiple multi core processors, or also the use of specialized
FPGAs. Each of these technologies has its own advantages and disadvantages, but all
have one aspect in common in that they generally do not use the fastest available
processor in the system which is optimized for imaging algorithms namely the processor
on the graphics cards, also known as the GPU (Graphical Processing Unit).
These "racers" among the processors have an incredible development history. The
evolution has been principally driven by the gaming industry, where the requirements
demanded of the graphical representation of game scenes and animations have greatly
increased. Sales of Millions of games consoles have contributed to the demand, resulting
in large numbers of GPUs and corresponding profits to further boost the development of
graphics components. Other industrial sectors are now reaping the benefits, including
image processing.
PAGE 26
combination with larger memory options can achieve data throughput rates of up to 500
times greater than those of standard FPGAs.
However, these increased speeds are not fully available to image processing users – the
outsorcing of the algorithms to the GPU causes a delay in the data flow, from image
capture to data processing. Regardless of this effect, various analyses of intense
computing operations indicate a rise in performance by a factor of 2 to 10 when using a
GPU in place of a CPU, while the CPU can then be used at for other tasks
simultaneously.
There are two principal reasons as to why the GPU technology has only recently become
available for image processing. On the one hand, until recently graphics cards had
different processors for different tasks. The situation has now changed with the latest
graphics processors, such as the GeForce 8800 from Nvidia or equivalents from
companies such as ATI. Some of the 681 million transistors on the GeForce 8800
processor can be dynamically allocated for operations such as geometry or pixel
computation. On the other hand, the PCI link allows fast data transfer between host and
VGA card.
"The architecture of a graphics chip is always very complex," explains Martin Kersting,
Head of Development at STEMMER IMAGING. "However, the DirectX-API and the
High Level Shader Language (HLSL) compiler from Microsoft together with a handful of
functions in our Common Vision Blox software library enable image processing software
developers to transfer images between the host and GPU, and therefore use all processors
in the system in an optimum way."
As already mentioned, data transfers between the VGA card and GPU cause a certain
delay between capturing the image and processing the data on the graphics card. Kersting
PAGE 27
describes the advantage of the technology as follows: "Skillful use of GPU image
processing can mean that special hardware is not even needed in applications with
extremely high data throughputs."
To bring the benefits of GPU image processing to developers in the most effective way,
the developers at STEMMER IMAGING – the image processing experts based in
Puchheim, Germany – have now integrated the functionality in the Common Vision Blox
(CVB) software library from the company. "To do so, we added several new functions to
CVB that can be called from a CVB application that can be accessed without any
additional GPU programming experience," states Kersting.
These functions currently implement tasks such as image filtering, point operations
between two images, parallel processing of four monochrome images, transformations
from RGB to HSI and from Bayer to RGB formats, so-called flat field corrections,
rotation and scaling of images. To optimize the image data transfer between main
memory and GPU it is also possible to combine several algorithms within the graphics
card by using the open programming possibilities of the HLSL language.
Kersting and his team have carried out multiple tests on possible increases in speed with
the new technology. For example, images captured with a monochrome CCIR camera
such as the JAI A11 using a PC-based system with an Nvidia 8800 graphics card were
upscaled to 2K x 2K pixels and displayed on a PC monitor. At the same time, the
graphics processor computed a 3x3 Sobel filter at a rate of 30 pictures/second. In a direct
comparison between a 2.4 GHz Intel Core 2 Duo processor and the Nvidia 8800, both
units computed a 5x5 filter.
PAGE 28
Figure 2: In a direct comparison between a 2.4 GHz Intel Core 2 Duo processor and an
Nvidia 8800 graphics card, the GPU completed the set image processing task about 5
times faster than the CPU
PAGE 29
• 3D LUT Transform on GPU
• Color correction with ICC profiles on GPU
• Adaptive denoising on CUDA
• RAW/DNG realtime image processing on CUDA
• Defringe on CUDA
• Custom solutions for fast image processing
GPUs Comparison
Here is performance comparison between all cards. Check the individual card
profiles below. Notably, the performance of Titan XP and GTX 1080 Ti is very close
despite the huge price gap between them.
PAGE 30
The price comparison reveals that GTX 1080 Ti, GTX 1070 and GTX 1060 have great
value for the compute performance they provide. All the cards are in the same league
value-wise, except Titan XP.
PAGE 31
NVIDIA p600 NVIDIA GPU Memory – 24Gb GDD5RX
PAGE 32
Pixel/texturing throughput – 1.3 Gpix/s
PAGE 33