Settings Selector based on Capture Speed

This section provides detailed guidance on the best camera settings based on your time budget from when you trigger an acquisition until you get the point cloud. Here we also consider your PC specs because data transfer and point cloud processing depend on that as well. We address settings for 3D captures to get good point clouds and 2D captures to get good color images.

You have determined which Zivid camera to use for your Piece Picking application, and you have mounted it and positioned it correctly. The next step is to select the camera settings that meet your cycle time requirements, given your PC specs. If you haven’t got a PC yet, then this section is also about finding the PC specs that will meet your capture time requirements in combination with the settings used.

3D settings

We have split the Piece Picking application into two categories based on scene complexity. For each category, we specify and recommend settings that meet the given imaging requirements and capture speed requirements.

Consumer Goods

If your scene does not consist of very bright, shiny, and dark objects, you can save significant cycle time by choosing Fast settings for Piece Picking. The Fast settings cover a narrower dynamic range but provide faster captures. Here is an example of a scene where Fast settings work well. As you can see, there are no items that cause strong direct reflections, highlights and saturation, and there are no very dark items.

Consumer Goods scene - Fast settings

Note

If there are no bright, shiny, and dark items in your scene, choose Fast settings.

With Quality settings for Consumer Goods, the camera covers a reasonably wide dynamic range, providing good point clouds for a large variety of objects. The scene can, in this case, include anything from bright and reflective plastic-wrapped objects and items in poly bags to dark absorptive material. The image below depicts a typical complex Consumer Goods scene that requires Quality settings.

Note

If you want to be sure that the camera will not miss seeing anything, choose Quality settings.

Settings Selector Table

The following table represents a settings selector tool based on the required capture time budget. The same table indicates the performance and thus the cost of a PC that can meet your capture speed requirements. Check out Recommended Industrial PCs to see examples of High-End, Mid-End, and Low-End configurations.

If you notice color Inconsistency in form of random color tint in your color images, choose the presets for the grid frequency in your region (50 Hz or 60 Hz). If the ambient light is unproblematic, select Off for optimal performance. To be sure, you can can check if there is flickering light in the scene with the Zivid camera.

Application

Capture Time (2D + 3D)

Camera Settings

High-End PC

Mid-End PC

Low-End PC

Consumer Goods (Quality)

~250 ms

~850 ms

~1600 ms

Z2+ MR130 Quality

Z2+ MR60 Quality

Z2+ LR110 Quality

Consumer Goods (Fast)

~150 ms

~250 ms

~430 ms

Z2+ MR130 Fast

Z2+ MR60 Fast

Z2+ LR110 Fast

To download the desired settings file, you can also connect to the camera (your specific model) in Zivid Studio, select the preset settings, turn on Ambient Light Adaption, and export the settings.

Caution

The capture time with settings adapted for ambient light frequency might be longer.

Application

Camera Settings

Consumer Goods (Quality)

Z2+ MR130 Quality

Z2+ MR60 Quality

Z2+ LR110 Quality

Consumer Goods (Fast)

Z2+ MR130 Fast

Z2+ MR60 Fast

Z2+ LR110 Fast

To download the desired settings file, you can also connect to the camera (your specific model) in Zivid Studio, select the preset settings, turn on Ambient Light Adaption, and export the settings.

Caution

The capture time with settings adapted for ambient light frequency might be longer.

Application

Camera Settings

Consumer Goods (Quality)

Z2+ MR130 Quality

Z2+ MR60 Quality

Z2+ LR110 Quality

Consumer Goods (Fast)

Z2+ MR130 Fast

Z2+ MR60 Fast

Z2+ LR110 Fast

To demonstrate reaching the above requirements for piece picking we continuously run benchmark capture programs with our cameras on various PCs. The following table shows the results.

Parcel Picking

Parcel is also split into two settings depending on scene complexity and capture time.

Parcels Fast settings are designed to achieve the shortest cycle times. These settings have a limited dynamic range but are good enough for objects that are relatively straightforward for imaging, for example:

  • cardboard boxes

  • white envelopes

  • bright poly bags

Note

If you image only boxes, parcels, satchels, etc., choose Parcels Fast settings.

Tip

Try increasing the exposure time for more data coverage on dark specular objects or switch to Parcels Quality presets.

For more challenging scenes, you should try out Parcels Quality settings. These settings have larger dynamic range and are capable of getting good surface coverage on objects such as:

  • black poly bags

  • dark plastic bags

  • dark plastic wrap

Tip

To reduce capture time, switch the engine from Omni to Stripe; note that you may get less coverage on black parcels.

Settings Selector Table

If you experience color Inconsistency in form of random color tint in your color images or artifacts in the form of ripples/waves across the whole point cloud, choose 50/60 Hz to select presets adapted to the ambient light (grid) frequency. If the ambient light is unproblematic, select Off for optimal performance. To be sure, you can can check if there is flickering light in the scene with the Zivid camera.

Application

Capture Time (2D + 3D)

Camera Settings

High-End PC

Mid-End PC

Low-End PC

Parcels (Quality)

~135 ms

~900 ms

~1600 ms

Z2+ MR130 Quality

Z2+ LR110 Quality

Z2 M70 Reflective

Z2 L100 Reflective

Parcels (Fast)

~50 ms

~100 ms

~200 ms

Z2+ MR130 Fast

Z2+ LR110 Fast

Z2 M70 Matte

Z2 L100 Matte

To download the desired settings file, you can also connect to the camera (your specific model) in Zivid Studio, select the preset settings, turn on Ambient Light Adaption, and export the settings.

Caution

The capture time with settings adapted for ambient light frequency might be longer.

Application

Camera Settings

Parcels (Quality/Reflective)

Z2+ MR130 Quality

Z2+ LR110 Quality

Z2 M70 Reflective

Z2 L100 Reflective

Parcels (Fast/Matte)

Z2+ MR130 Fast

Z2+ LR110 Fast

Z2 M70 Matte

Z2 L100 Matte

To download the desired settings file, you can also connect to the camera (your specific model) in Zivid Studio, select the preset settings, turn on Ambient Light Adaption, and export the settings.

Caution

The capture time with settings adapted for ambient light frequency might be longer.

Application

Camera Settings

Parcels (Quality/Reflective)

Z2+ MR130 Quality

Z2+ LR110 Quality

Z2 M70 Reflective

Z2 L100 Reflective

Parcels (Fast/Matte)

Z2+ MR130 Fast

Z2+ LR110 Fast

Z2 M70 Matte

Z2 L100 Matte

To demonstrate reaching the above requirements for parcels we continuously run benchmark capture programs with our cameras on various PCs. The following table shows the results.

Testing 3D Settings

You can use Zivid Studio to test 3D settings.

To import the settings in Zivid Studio:

  • Click on FileImport Capture Settings

  • Navigate to the location of your settings file

  • Click Open

You can also drag and drop a YML file into Zivid Studio to import the settings.

You can also load the settings with the SDK.

Go to source

source

const auto settings = Zivid::Settings(settingsPath);
Go to source

source

var settings = new Zivid.NET.Settings(settingsFile);
Go to source

source

settings = zivid.Settings.load(user_options.settings_path)

2D settings

We provide three options for acquiring 2D settings for your Piece Picking application:

  • Use settings presets

  • Get 2D settings automatically using the Zivid calibration board with a code sample

  • Manually tune 2D settings

The 3D settings presets also include the 2D settings. Therefore, we recommend using the same settings preset for 3D and 2D captures. If this does not provide satisfactory results, check out the following options.

Automatic 2D settings

Run the auto_2d_settings.py sample to automatically find the acquisition settings for a 2D capture using a Zivid calibration board. Place the calibration board at either the top or bottom of the bin and run the sample by specifying the calibration board location and the desired focus range (bin height) as command line arguments. If you, for example, place the calibration board at the bin top and the bin height is 400 mm, run the sample as:

python auto_2d_settings.py --desired-focus-range 400 --checkerboard-at-start-of-range --use-projector --no-color-balance

If you place the calibration board at the bin bottom, run:

python auto_2d_settings.py --desired-focus-range 400 --checkerboard-at-end-of-range --use-projector --no-color-balance

Manually tune 2D settings

If 2D settings presets or automatic tuning does not provide sufficient 2D quality, you can manually tune the color settings by adjusting the color balance and gamma parameters. Gamma correction can be used to either darken or brighten the image. The color channel parameters makes the color image look more natural.

For an in-depth tutorial on how to optimize for colors, see Optimizing Color Image.

Testing 2D Settings

To test 2D settings, you can either use the 2D capture mode in Zivid Studio or run one of our code samples.

To import the settings in Zivid Studio:

  • Click on FileImport Capture Settings

  • Navigate to the location of your settings file

  • Click Open

You can also drag and drop a YML file into Zivid Studio to import the settings.

The following code shows how to use the exported settings in the API.

Go to source

source

auto camera = zivid.connectCamera();
const auto settings = Zivid::Settings(settingsPath);
    const auto frame2D = camera.capture2D(settings);
Go to source

source

var camera = zivid.ConnectCamera();
var settings = new Zivid.NET.Settings(settingsFile);
using (var frame2D = camera.Capture2D(settings))
Go to source

source

camera = app.connect_camera()
settings = zivid.Settings.load(user_options.settings_path)
frame_2d = camera.capture_2d(settings)

After capturing the image can be saved in linear RGB or sRGB.

Go to source

source

const auto imageRGBA = frame2D.imageRGBA();
const auto imageFile = "ImageRGBA_linear.png";
std::cout << "Saving 2D color image (Linear RGB) to file: " << imageFile << std::endl;
imageRGBA.save(imageFile);
Go to source

source

var imageRGBA = frame2D.ImageRGBA();
var imageFile = "ImageRGBA_linear.png";
Console.WriteLine($"Saving 2D color image (Linear RGB) to file: {imageFile}");
imageRGBA.Save(imageFile);
Go to source

source

image_rgba = frame_2d.image_rgba()
image_file = "ImageRGBA_linear.png"
print(f"Saving 2D color image (sRGB color space) to file: {image_file}")
image_rgba.save(image_file)

Go to source

source

const auto imageSRGB = frame2D.imageRGBA_SRGB();
const auto imageFile = "ImageRGBA_sRGB.png";
std::cout << "Saving 2D color image (sRGB color space) to file: " << imageFile << std::endl;
imageSRGB.save(imageFile);
Go to source

source

var imageSRGB = frame2D.ImageRGBA_SRGB();
var imageFile = "ImageRGBA_sRGB.png";
Console.WriteLine($"Saving 2D color image (sRGB color space) to file: {imageFile}");
imageSRGB.Save(imageFile);
Go to source

source

image_srgb = frame_2d.image_rgba_srgb()
image_file = "ImageRGBA_sRGB.png"
print(f"Saving 2D color image (sRGB color space) to file: {image_file}")
image_srgb.save(image_file)

Note

We have tested the 3D and 2D settings we recommend for the above typical scenes in low (~300 lx) and high (~1000 lx) ambient light conditions. This we have done for the range of distances that we specify in the Camera Selector section, and all with various items in the scene. Therefore, we are confident that these settings will work the majority of scenes that fit into these categories. However, if you know exactly what items you expect in your scene and you are an expert camera user, you can manually configure settings to optimize them for your case. Check out Capturing High Quality Point Clouds to learn how to do that.

Avoiding interference from flickering light

Flickering light sources (10-1000 Hz), such as barcode readers and fluorescent tubes, can interfere with the Zivid camera. This interference can manifest as color inconsistency in the color image. To prevent this, ensure the flickering light source is either:

  1. continuous and frequency correlated to the Zivid camera exposure time

  2. continuous and frequency correlated to the Zivid camera sampling interval

  3. inactive during the Zivid camera acquisition

Configuration in presence of active light sources

The first step is to identify the frequency of the active light source. If you are unsure about the frequency, you can measure it with the Zivid camera.

Detecting and measuring ambient light frequency

Open Zivid Studio and connect to your camera. Click on the three dots in the Capture section. Then click Measure scene lighting conditions. The software will display the detected ambient light flicker frequency.

../../../_images/studio-measure-ambient-light.png

Alternatively, use the SDK to measure the ambient light conditions. This method will report whether significant ambient light flicker is detected and if it corresponds to a 50 Hz or 60 Hz power grid.

Go to source

source

std::cout << "Measuring scene conditions" << std::endl;
auto sceneConditions = camera.measureSceneConditions();
auto flickerClassification = sceneConditions.ambientLight().flickerClassification().toString();
std::cout << "Flicker classification: " << flickerClassification << std::endl;
    auto flickerFrequency = sceneConditions.ambientLight().flickerFrequency();
    std::cout << "Measured flickering frequency in the scene: " << flickerFrequency << " Hz." << std::endl;
Go to source

source

Console.WriteLine("Measuring scene conditions");
var sceneConditions = camera.MeasureSceneConditions();
var flickerClassification = sceneConditions.AmbientLight.FlickerClassification.ToString();
Console.WriteLine("Flicker classification: " + flickerClassification);
    var flickerFrequency = sceneConditions.AmbientLight.FlickerFrequency;
    Console.WriteLine($"Measured flickering frequency in the scene: {flickerFrequency} Hz.");
Go to source

source

print("Measuring scene conditions")
scene_conditions = camera.measure_scene_conditions()
flicker_classification = scene_conditions.ambient_light.flicker_classification
print(f"Flicker classification: {flicker_classification}")
    flicker_frequency = scene_conditions.ambient_light.flicker_frequency
    print(f"The measured flickering frequency in the scene: {flicker_frequency} Hz.")

If measuring for one source, e.g., barcode scanner, turn off all other light sources in the scene, e.g., ambient lights.

Then, you can choose to configure the active light source or the Zivid camera settings to avoid interference.

Match the active light source, e.g., barcode scanner, frequency (\(f_c\)) to the Zivid camera exposure time (\(t_z\)) using:

\[f_c = \frac{1}{t_z}\]

For example:

\[t_z = 10\,000\,\mu s \Rightarrow f_c = 100\,Hz\]

Match the exposure times (\(t_z\)) of the Zivid camera to the active light source, e.g., barcode scanner, frequency (\(f_c\)) using:

\[t_z = \frac{1}{f_c}\]

For example:

\[f_c = 140\,Hz \Rightarrow t_z = 7\,143\,\mu s\]

If the calculated exposure times are not feasible then set the 2D sampling interval (\(t_z\)) to match the active light source frequency (\(f_c\)) using the same formula:

\[t_z = \frac{1}{f_c}\]

For example:

\[f_c = 140\,Hz \Rightarrow t_z = 7\,143\,\mu s\]

An example of such case is when compensating with the longer exposure time requires lowering the projector brightness too much, thus causing noticeable noise in the color image. This is the case when using rgb mode for Settings2D::Sampling::Color, and not when using the rgbStrongAmbientLight mode. Another example is overexposure, which occurs if long exposure times cannot be adequately compensated for using other acquisition settings such as gain or projector brightness.

Configuration in presence of both active and flickering AC-powered light sources

The presence of strong and uncontrollable light sources operating with power line frequency modulation (e.g., 60 Hz in the US, 50 Hz in the EU) can introduce additional challenges. Since changing the frequency of AC-powered light sources, e.g., fluorescent tubes, is not feasible, you need to adjust the Zivid camera settings and the frequency of the active light sources.

Configuring Zivid camera

To mitigate the interference from ambient light, set the exposure times of the Zivid camera to match a multiple of the power line period.

  • 10 000 µs or 20 000 µs in the presence of 50 Hz grid frequency.

  • 8 333 µs or 16 667 µs in the presence of 60 Hz grid frequency.

If you are unable to adjust the exposure times to match the grid frequency, e.g., due to overexposure in the 2D image, then instead enable 2D sampling interval and synchronize it to your region’s grid frequency.

  • 10 000 µs in the presence of 50 Hz grid frequency.

  • 8 333 µs in the presence of 60 Hz grid frequency.

The exposure times or 2D sampling interval duration must be configured for 2D acquisitions to avoid Color Inconsistency (random Color Tint). For 3D acquisitions, this is not necessary unless the Ripples from Ambient Light Interference are observed.

The solution with exposure time matching is preferred over 2D sampling interval matching because it provides better performance and more consistent capture times.

Configuring active light source

Finally, the frequency of the active flickering light source, matched to the Zivid camera exposure time, can be calculated as:

\[f_c = n \times f_{line}\]
\[f_{line} = 60 Hz \Rightarrow f_c = n \times 60\,Hz = 60, 120, 180, 240\,Hz\]
\[f_{line} = 50 Hz \Rightarrow f_c = n \times 50\,Hz = 50, 100, 150, 200\,Hz\]

In the next section, we cover Optimizing Robot Cycle Times for speed by making use of multithreading.

Version History

SDK

Changes

2.17.0

Added support for Zivid 3 cameras and Sampling Interval setting.

2.16.0

Added support for measuring ambient light frequency and guidelines to avoid ambient light interference.

2.12.0

Zivid One+ has reached its End-of-Life and is no longer supported.