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

// MANUFACTURING

Flange Defect Inspection

Flange Defect Inspection. What it takes to run it.

Scratch, crack, dent and pinhole boxed on the sealing face, two thresholds giving pass, review or fail before the joint is bolted.

Start with your footageBook a demo →All of manufacturing →

// 01 · The question

“Is that a pinhole on the sealing face, or a speck of swarf the air blast hasn't cleared yet?”

// 02 · Why it is hard

A pinhole and a speck of swarf throw back the same few dark pixels under raking light to a model that has seen only a few hundred of each, a dent only shows when the light comes from the side, and good faces outnumber bad ones by construction, so the rare classes have to be sampled up rather than left to turn up on their own.

// 03 · What the labels have to be

Bounding box

Decided before the first frame

Disposition is read off which of four classes a candidate falls into and where it ranks against the operating thresholds, not off its outline's exact extent, so a box on each scratch, crack, dent and pinhole is the whole geometry the station needs. A mask would spend labeling time on an area the band's two thresholds, not a measurement, decide from.

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

A scratch or a dent

boxed under the station's raking light, the angle that shows a shallow depression a flat light misses

A crack

boxed as its own class and always a reject, an irregular line that often branches rather than runs straight

A pinhole

boxed as the hardest of the four to see, confirmed against the frame taken after the air blast, since a dot still there after the blast is a pinhole and one that isn't is swarf

A face the model doubts

any candidate that lands between the two thresholds, held at the station with the frame for the quality engineer's own raking-light check

// 03b · What it checks

  1. 01

    Each candidate's rank against the two thresholds the quality engineer set, so a flange passes, fails or goes to review rather than every flange getting one forced guess.

  2. 02

    A pinhole candidate against the frame taken after the air blast, telling a true pinhole from a speck of swarf before either is scored.

  3. 03

    The review queue against its own history, since a jump in doubted flanges with no jump in corrections means the thresholds are wrong for a new casting lot, not that the model is wrong.

  4. 04

    The reject rule's severity and cooldown, approved before it goes live, so a crack at the station reaches the quality engineer's own log and Slack with the frame attached.

// 03c · What the line provides

  • The camera already over the sealing face at the station, under the raking light the inspector already works under.
  • Frames from this line's own castings, with the swarf and coolant film a face carries an hour after turning, not a studio shot.
  • The two thresholds in writing, set by weighing a false reject against a leaking joint, and owned by the quality engineer alone.
  • The quality engineer, for the flange in the band, the way the thumbnail check decides today.

// 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

Prior shift

The defect rate changed

→Prior shift →

A new foundry starts casting the flanges and the pinhole rate triples while the scratch rate holds; the faces look the same and the classes mean the same thing, but how often pinholes occur has moved, so the band that sent one flange in fifty to review now sends one in five. The model has not degraded, and retraining it on the same classes will not shrink the queue; the signal is the review queue's own history, not a drop in any score.

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's thumbnail check?

No. It boxes every candidate on every face, and the ones it is unsure of, mostly pinholes against swarf, go to the station with the frame. The inspector still runs a thumbnail across a face in review, and says it is faster than looking.

How does it tell a pinhole from a speck of swarf?

Mostly from whether the dot is still there in the frame taken after the air blast; a true pinhole survives, swarf does not. Every one the inspector corrects teaches the next version the same rule a little better.

What happens when a new casting supplier starts?

The pinhole rate can triple while the scratch rate holds, and the faces look the same the day it happens. A review band tuned to the old rate fills with ordinary pits, which is the cue to re-tune the two thresholds for the new lot first, and only retrain if the inspector's corrections are climbing too, which means the model is seeing a pattern it was never taught.

Who owns the two thresholds?

The quality engineer, outright. A new model version ships with the thresholds it inherited rather than its own, so the operating point never moves without the engineer finding out first.

Read next

Flange defect inspection on the sealing face, the full walk-through →Surface defect detection: the same find-then-grade split, graded by area instead of a sealing-face band →Pipe and tube defect inspection: the same two-threshold pass, review or fail banding, on a tube instead of a sealing face →What a new casting supplier does to a threshold nobody retuned →
Start with your footageBook a demo →

// 07 · Also in manufacturing

Surface Defect Detection→Weld Quality Inspection→Assembly Verification & Error Proofing→Package & Label Inspection→Package Damage Detection→FDA Food Label Compliance→Juice Box Quality Inspection→Diabetes Device 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→Product Color Inspection→Chocolate Box Inspection→Blister Pack Inspection→Date Code OCR Verification→Process Compliance Tracking→Dimensional Defect Inspection→Connector Pin Inspection→Medical Device Label Verification→Hog Ring Inspection→Pallet Scanning→PCB Defect Detection→IV Bag Fill Level & Leak Detection→Bottle Cap Inspection→Paint Defect Detection→Fall Detection→Orthopedic Implant Inspection→All forty-one→
Surface Defect DetectionWeld Quality InspectionAssembly Verification & Error ProofingPackage & Label InspectionPackage Damage DetectionFDA Food Label ComplianceJuice Box Quality InspectionDiabetes Device 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 VerificationProduct Color InspectionChocolate Box InspectionBlister Pack InspectionDate Code OCR VerificationProcess Compliance TrackingDimensional Defect InspectionConnector Pin InspectionMedical Device Label VerificationHog Ring InspectionPallet ScanningPCB Defect DetectionIV Bag Fill Level & Leak DetectionBottle Cap InspectionPaint Defect DetectionFall DetectionOrthopedic Implant InspectionAll 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