Optics & lighting

Choose lighting and ROI for open-package contents

Use matched present, absent and covered-item controls to separate actual visible contents from tray edges, reflections and wrapping.

Send samples for engineering review
Choose lighting and ROI for open-package contents
Engineering illustration; not a photograph or a completed production test.

Define the visible item contrast contract

Define the contrast evidence for each declared visible item and for its valid empty observation zone. A white insert on a white tray, a glossy seal near a reflective wrapper and a dark cap inside a deep cavity are different observation problems. State the boundary or surface feature that supports presence, and distinguish it from the cavity rim or background print. An expected zone name is a bookkeeping label, not proof that any bright region there belongs to the intended kit item. Include an absent control and a covered control so darkness, reflection and hidden contents cannot quietly become reliable inventory evidence.

Compare illumination on matched packages

Compare candidate diffuse, directional or appropriate silhouette illumination on the same identified packages with unchanged camera geometry and exposure. A backlit approach only makes sense when the permitted presentation actually exposes a usable transmitted boundary; an opaque carton does not become transparent. Change the selected lighting variable alone and retain all original comparisons, including unsuccessful options. Evaluate correctly packed, omitted-item and extra-item references together. A light that cleans the normal preview but makes an empty tray recess resemble the item has not solved completeness. Record the observation that supports the candidate and the case that would disprove it.

Challenge wrapping reflections and deep shadows

Challenge transparent wrapping, folded paper and reflective surfaces across the permitted presentation range. Inspect whether a highlight hides a required object boundary or creates an occupied-looking region in an empty cavity. Compare the same package with the declared wrapper or flap variation while preserving its reference contents. Do not remove normal packaging material merely to produce an easier development image unless that altered presentation is part of the agreed station process. Exposure saturation and deep shadows remain evidence limits even when the mask looks smooth. If material hides the object, preserve unobservability rather than asking a threshold to infer presence through it.

Observe separate visible item zones

Required object contours remain fully inside separate zones, while flaps and covered areas retain their observation limits.

  1. Original package coordinate basis
  2. Visible item zone A with margin
  3. Visible item zone B with margin
  4. Covered or reflective evidence boundary
Observation concept; zone names do not prove SKU recognition or hidden contents.
View full-size diagram

Declare separate item observation zones

Declare observation zones in the original image coordinate basis and retain any crop or alignment transform. Each legitimate visible item contour must fit completely inside its assigned zone with margin over allowed poses. Keep zones nonoverlapping so the same foreground cannot satisfy different kit quantities. The reviewed fixed-region route uses configured labels and component geometry, not learned recognition of arbitrary contents. Verify its installed input and visibility contract before relying on it. If packages vary freely in layout, constrain presentation or use a validated alignment or recognition method instead of treating a broad zone as proof that the intended SKU is present.

optical_record = {
    'package_id': package_id,
    'kit_revision': kit_revision,
    'illumination_revision': illumination_revision,
    'original_zone_coordinates': original_zone_coordinates,
    'foreground_polarity': foreground_polarity,
    'mask_revision': mask_revision,
    'visibility_state': visibility_state,
}
# Proposed workbook fields. A configured zone name is not proof of the item's learned identity.

Validate foreground with presence and absence

Inspect actual foreground masks beside the original source frame for both present and absent references. Confirm polarity and retain the processing revision. A wrapper seam or tray edge may become a valid-looking connected region even when the intended item is absent. Opening can remove a small legitimate seal and closing can merge neighboring visible objects; evaluate any morphology change on the same references before retaining it. Keep clipped, touching and oversized regions explicitly ambiguous under the selected contract. A less fragmented mask does not establish correct quantity if it has erased an omission or merged distinct objects into an apparently convenient component.

Test the allowed material range

Test allowed tray color, carton print, object finish, wrapper condition and presentation pose with frozen references and settings. Compare each identified package before and after the selected change, then separate material groups that were not used for initial tuning. Inspect the complete image so an adjacent item cannot enter a stale local zone unnoticed. If a crop is revised, update and verify the coordinate relationship rather than retaining previous masks or counts. Keep the agreed visibility policy unchanged across groups. A package variant that cannot be observed must remain an explicit limit or review case, not disappear from the planned sample denominator.

Keep the optical workbook

Link package and kit identities, reference contents, lighting arrangement, actual exposure, original zones, polarity, mask revision, visibility state and failure signature in the workbook. Add the matched comparison and the explanation it supports or refutes. Preserve the raw images and failed masks beside the selected option. The table distinguishes optical ambiguity from a later BOM decision and offers no universal intensity threshold or morphology kernel. A receiving engineer should be able to reconstruct why a region was considered visible item evidence and which wrapper, tray or presentation variants remain outside the demonstrated observation contract.

Optical workbook for visible package inventory
RiskMatched controlEvidence retained
Empty cavity resembles an itemPresent and absent contents with same lightOriginal boundaries and polarity
Wrapper creates occupied-looking reflectionSame package with declared wrapper variationRaw highlight and visibility state
Different zones share foregroundFull-image overlay over permitted posesSeparate original coordinates and margins
Morphology merges or removes objectsSame mask before and after operationRevision and reference-content effects

Freeze only the demonstrated visible inventory

Freeze illumination, camera geometry, item zones and foreground preparation only after the agreed groups preserve the visible evidence for required and extra items. Carry unresolved clipping, contact or cover conditions into the workflow explicitly, rather than modifying references to create apparent completeness. Use independent packages for acceptance of the selected chain. Fixed-zone source examples do not prove learned kit recognition, closed-box contents or readiness of the current station package. Deyi Vision can support comparisons of supported image workflows, but this procedure proposes an optical development test and does not report a completed production inspection or a guaranteed inventory accuracy.

Paired optical evidence before BOM tuning

Compare lighting and masks on matched reference contents while preserving absence and ambiguity.

  1. Freeze package reference and camera
  2. Change the declared illumination variable
  3. Inspect masks with present and absent controls
  4. Freeze evidence or retain visibility gaps
Proposed development sequence; no production trial is claimed.
View full-size diagram

Sources and technical references

These references explain the methods and limits used in this tutorial. Example checks are guidance; production acceptance requires evidence from your own samples.

  1. Image ThresholdingOpenCV

    Foreground polarity and threshold selection must be validated with original images and explicit controls.

    Checked
  2. Morphological TransformationsOpenCV

    Morphology can alter component geometry and therefore cannot be accepted from a cleaner preview alone.

    Checked
  3. Deyi Vision Vision WorkbenchDeyi Vision

    Supported saved-image workflow comparisons need preserved input evidence and actual configuration.

    Checked

Engineering review

Bring the inspection problem and the evidence.

Send sample images, your current setup and the check that failed. Include field of view, working distance, line speed and acceptance criteria for a practical review.

Send samples for engineering review
Contact

Direct RFQ contact

Talk to engineering about the inspection problem.

Send sample images, competitor model, FOV, working distance and line speed before model selection.

Target: selection brief within 24h
Send sample images