Skip to content
LexDataLexData
PlatformIndustriesCustomers
DocsThe Field GuideBlogWhy models drift
AboutCareersSecurityContact
Log inStart now

// MANUFACTURING

IV Bag Fill Level & Leak Detection

IV Bag Fill Level & Leak Detection. What it takes to run it.

Fill level classed against the printed scale on the same frame that finds the bag, a wet port asked as a question rather than scored pass or fail.

Start with your footageBook a demo →All of manufacturing →

// 01 · The question

“Is this bag filled to the right band against the printed scale, and is that mark at the port a leak or just condensation?”

// 02 · Why it is hard

The film is clear, so the model never learns the bag itself, only the fluid, the ports and the label that sit inside it. The line's own lights throw a highlight wherever they catch the film, and the highlight moves with the bag: across the meniscus it hides the fill line, and at a port it can look exactly like a droplet. A model trained on frames where the labeler skipped the glared bags learns that glare means nothing is there, and passes every bag the light happens to hit.

// 03 · What the labels have to be

Bounding box

Decided before the first frame

The bag is nearly invisible on its own, so the box goes around the things a filled bag reliably shows: the fluid column, the two ports and the label. Fill level is then a class carried on that same box, read against the printed scale rather than measured as a separate shape. Whether a port is wet is not a geometry question at all; that is a question put to the frame.

This is the decision that is expensive to reverse. The geometry has to match what the answer contains, and finding out it does not means labelling the set a second time.

// 03a · What it finds

The bag itself

found through the fluid column, the two ports and the label rather than the clear film, boxed on every bag at station six

The fill level

a class carried on the same box, read against the printed scale once the bag has settled from the filler

A wet mark at a port

asked as a question of the frame, whether the moisture looks like a leak or like condensation, with the frame behind the answer

A bag the model doubts

a meniscus sitting on a band boundary, or a highlight crossing it, held for a person with the frame rather than scored either way

// 03b · What it checks

  1. 01

    The fill class against the line's own bands, under-filled, in-range and over-filled, read against the printed scale the same way the inspector read it against the light.

  2. 02

    A wet port's answer against a person before anything is disposed on it; the question flags, and a person decides whether it is a leak or condensation.

  3. 03

    The rule's own severity and cooldown, an under-filled bag routine to the station screen, a wet port high to the quality engineer in Slack with the frame attached.

  4. 04

    The correction rate after a new film supplier or a new lot of fluid, since a tint change shows up there before anyone has said a thing changed.

// 03c · What the line provides

  • The camera already over the filling line at its mounted position, with the backlight the line already runs; no bench photographs and no new station.
  • A polariser on the lens where one fits, to take out most of the glare before it reaches the sensor; what remains is labeled as what it is.
  • The line's own fill bands and printed scale, fixed before labeling, so a class means the same under-filled or over-filled call the inspector already makes.
  • A quality engineer to read the wet-port question and decide, the same thumb-over-the-seal call made against a frame instead of a bag in hand.

// 04 · How we run it

Three parts of one loop, on this job.

LexAnnotate

Defect Annotation

Pixel-level defect annotation for surface scratches, cracks, dents, weld faults, and assembly misalignments. Multi-sensor alignment for multi-camera inspection systems.

LexInsight

Line Performance

Ask which shift or which line is producing the most of one defect class, and get an answer with the frames behind it, graded against the plant's own written standard.

LexAlert

Quality Alerts

Monitor defect detection accuracy across changing production conditions. Detect when lighting shifts, new materials, or equipment aging degrades model performance. Auto-retrain to maintain 99%+ accuracy.

How the loop fits together →

// 05 · What breaks it after launch

Covariate shift

A camera was replaced

→Covariate shift →

A failed line camera is swapped for the same model from a newer batch, with a slightly different lens coating and a sensor that renders the backlight a little cooler. The bags look the same to the inspector. To the model, every highlight has moved and the meniscus sits against a background of a different tone, so the doubted frames spike on the first shift after the swap.

It is not the only one that can get this use case, it is the one that usually gets it first. All ten conditions.

// 06 · In manufacturing

Defect Detection at Scale

Full write-up ↓Every case study →

The Challenge

Vision models performed well in pilots but lost accuracy as factory conditions shifted.

Our Execution

Built pixel-level annotated datasets and multi-sensor alignment for reliable defect detection.

The Result

Maintained 99%+ defect detection accuracy across changing production environments. Reduced unplanned downtime.

99%+

Accuracy maintained in production

// 06a · Questions we get asked

Does this replace the inspector who squeezes every tenth bag?

No. The squeeze finds a slow leak, a bag lighter than it should be, which no frame can show. The camera inspects every bag rather than every tenth for fill level and for a visible wet mark; the two checks sit side by side rather than one replacing the other.

How does it tell a leak from condensation at the port?

That is not scored by the detector. The boxed port crop is put to LexInsight as a question, is there visible moisture and does it look like a leak or like condensation, and the answer comes back with the frame behind it. A bag the answer calls wet goes to a person, who decides; it is a flag, not a pass or fail gate.

What about glare on the clear film?

Handled before inference, not during it. Glared frames are labeled on purpose, at a higher share than they occur, with the meniscus read from the frame just before or after the glare moved off it. A polariser on the lens takes out most of it on the camera side as well.

What happens when the line's camera is replaced?

Every highlight the model learned moves with it, since a new unit renders the backlight at a different tone even when the bags look unchanged to a person. The signal is the correction rate stepping up on the day of the swap; the fix is a short labeled window from the new camera folded in, an afternoon's work if the swap is known about.

Read next

Leak inspection of IV bags with a line camera, the full walk-through →Assembly verification: the same partial-view problem, read from a box and its position instead of a port crop →What a swapped camera does to every highlight the model learned →
Start with your footageBook a demo →

// 07 · Also in manufacturing

Surface Defect Detection→Weld Quality Inspection→Assembly Verification & Error Proofing→Package & Label Inspection→Date & Lot Code Inspection→Predictive Maintenance→Multi-Sensor Monitoring→Tablet Defect Inspection→Syringe Barrel Defect Detection→Foreign Material Detection→Glass Defect Detection→Semiconductor Wafer Inspection→Strip Surface Defect Inspection→Ceramic Defect Detection→Wood Defect Detection→Pipe & Tube Defect Inspection→Body-in-White Inspection→Contact Lens Defect Inspection→Coffee Bean Defect Inspection→Parts Count Verification→Pallet Scanning→PCB Defect Detection→All forty-one→
Surface Defect DetectionWeld Quality InspectionAssembly Verification & Error ProofingPackage & Label InspectionDate & Lot Code InspectionPredictive MaintenanceMulti-Sensor MonitoringTablet Defect InspectionSyringe Barrel Defect DetectionForeign Material DetectionGlass Defect DetectionSemiconductor Wafer InspectionStrip Surface Defect InspectionCeramic Defect DetectionWood Defect DetectionPipe & Tube Defect InspectionBody-in-White InspectionContact Lens Defect InspectionCoffee Bean Defect InspectionParts Count VerificationPallet ScanningPCB Defect DetectionAll forty-one →

Send us a week of this footage. We’ll show you what comes back.

Start with your footageBook a demo →
LexData
LexData

Product

  • Platform
  • Industries
  • Use cases

Resources

  • Docs
  • The Field Guide
  • Blog
  • Why models drift

Industries

  • Energy & utilities
  • Oil & gas
  • Agriculture
  • Manufacturing
  • Insurance
  • Retail
  • Robotics

Company

  • About
  • Customers
  • Careers
  • Contact

Trust

  • Security
  • Privacy
  • Terms

Stay updated

What we learn running vision models in production.

See everything.
Miss nothing.

Stay updated

What we learn running vision models in production.

Terms of use & Privacy policy

© 2026 LexData Labs · All rights reserved