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

Industries · 7 min read

Corrosion detection with computer vision that measures rust as an area

A tag to triage the survey, a box to send the crew, a mask to say whether the patch grew since last quarter. Wet steel is where the model struggles.

Summary

This post sets out three label shapes for corrosion on tank shells and pipe racks, a tag for triage, a bounding box for repair priority and a mask for affected area, and explains why only the mask lets two surveys be compared. It concludes that the labeling standard has to be written before the first outline is drawn, and that wet steel and low sun are the frames that come back for review. It is for integrity engineers and inspection teams in oil and gas.

Sheikh Srijon · GTM Lead · Sep 24, 2026

Pipe rack from above, rust boxed along the lines and two dents flagged, from a customer inspection run

The crawler goes up the tank shell at 8 am, before the sun is high enough to put a highlight on every weld, and the drone takes the pipe rack an hour later. Between them they come back with more frames of steel than the two inspectors on site could look at in a month. Somewhere on the third course of the tank is a patch of rust the inspector chalked last quarter, and the question the integrity engineer has is the simplest one on the list: is it bigger.

Answering that needs a particular kind of label, and it is the most expensive of the three.

Three questions on the same steel, and each wants a different label

The first question is whether there is any corrosion in the frame at all. That is a tag on the whole frame, rust or no rust, and it is what turns the crawler's 8 am pass, every frame of it, into a short list. Fast to label, fast to run, and it says nothing about where.

The second is where on the rack the corrosion sits, so a crew can be sent to the right section. That is a box on each patch, and a box is enough to prioritise.

Rust on a load-bearing member ranks above rust on a handrail, and the box tells you which member it is on.

The third is how far it has spread. That needs the patch's outline, drawn where the rust ends and the sound steel begins, because the answer is an area and a box discards area. The corrosion and structural degradation use case says it directly: the label has to be the measurement, or every number downstream is a proxy for how close the inspector stood.

A bounding box is enough to send a crew and not enough to compare

The box has one property that ruins it for comparison: it grows when the drone flies closer. The same patch on the same pipe at half the altitude is a box with four times the pixels, and the rust is the size it was. Two surveys a quarter apart, flown by different pilots at different heights, produce boxes that cannot be set against each other.

A mask has the same problem in pixels and a way out of it. The pipe in the frame has a known diameter, the tank course has a known height, and either gives the scale that turns the mask's pixels into a real area. Two masks of the same patch, each scaled by the pipe beside it, can be compared, and the difference between them is the number the integrity engineer wanted at 8 am.

So the practical answer on most sites is all three shapes, in order. Tag the survey to find the frames worth opening. Box the patches to set the repair list. Mask the patches on the members that matter, and keep those masks as the record the next survey is measured against.

Two inspectors outline the same patch differently, so the standard is written first

The boundary of a rust patch is genuinely ambiguous. One inspector stops the outline at the flaking edge; another includes the staining that runs down from it; a third counts the discoloured coating around the patch as affected. All three are defensible, and a model trained on all three learns the disagreement rather than the rust.

The fix is a written rule before the first outline: staining is not rust, the outline follows the last flaked edge, a pen mark is a pen mark. That last one matters more than it sounds. On the sites where inspectors mark patches with a paint pen for the crew, the first model learns that a yellow circle means corrosion, and it is right often enough to be hard to catch.

You type the classes once, Lexi proposes the outlines on every frame, and a person who has done the walkdown checks each one against the written rule before anything trains. That QA pass is how labels come back at up to 99.9% accuracy, and it is where the 12k+ precision image annotations delivered across our oil and gas work were earned, one outline at a time. My own view is that a hundred masks drawn to a rule are worth more than a thousand boxes drawn fast, and that the rule should be stapled to the dataset so nobody has to guess it later.

Pixels become square centimetres only with a reference in the frame

Scale is the step that gets skipped. A mask gives a count of pixels; the engineer needs an area, and the conversion needs something in the frame whose size is known. On a pipe rack that is the pipe's outside diameter, read from the isometric on the December survey pack. On a tank shell it is the course height or a weld pitch. On a crawler with a fixed standoff the scale is a constant, and on a drone it changes with every frame.

The two surveys also have to be looking at the same patch, which sounds obvious and is the hard part.

The quarter-old frame and the new one are registered to the asset, by the pipe support number or the course and plate, before the areas are compared. Without that, the comparison is between two patches that may or may not be the same one, and the trend line is fiction.

Wet steel is darker steel, and the model has seen less of it

The days the model struggles are predictable. Rain on the rack, salt spray on the shell, low sun in December throwing every flange's shadow across the pipe beside it. All of these shift the colour and texture that corrosion is found by, and the same patch reads as worse at 8 am than at noon. Wet ground under the rack reflects the sky into the frame and washes out the lower pipes.

The drift catalog calls this rain, fog and dust, and the advice is to keep those frames rather than reflying. They come back for review because the model doubts them, a person confirms or corrects the outline, and the correction is worth more than a clear-day frame because the training set has so few like it. The correction rate on the wet-day survey against the dry-day one is the signal that the model needs them.

LexData takes the corrosion model through its whole life. You type what to look for, Lexi puts an outline on every frame, and a person checks each label before anything trains on it. The model then runs on each survey as it lands, in the cloud, on your servers, or on a runner beside the recorder. Frames it is unsure of come back to a person, the corrections retrain it, and the new version replaces the old one with no downtime. The December frames with the long shadows are what the spring version learned from.

The output is a list of patches with an area and a trend

What the integrity engineer gets at the end of the 8 am pass is not a score. It is the list of patches on the members that matter, each with a location on the rack, an area in real units, and the same number from the previous survey beside it. The patch on the third course of the tank is on that list with two numbers next to it, and the second is larger than the first, which is what the chalk mark was trying to say a quarter ago.

See it on your own footage.

Start with your footage

More in Industries

Industries · 6 min read

AI visual inspection as the nondestructive testing step a camera can take over

Visual testing is the first NDT gate, its acceptance criteria are already written, and a camera can apply them to every weld instead of one in twenty.

Rob Hickey · Sep 24, 2026

Industries · 6 min read

Appearance inspection systems that judge scratches, chips and burrs the same way on every shift

The station, the light and the written standard matter more than the model. The outlines carry the limit, and a tightened tolerance makes every label wrong.

Rajiya Sultana · Sep 24, 2026

Industries · 7 min read

Automated pallet accounting from the camera over the staging zone

A polygon on the frame, every pallet tracked so it is counted once, entries and exits as the ledger, and a wash-down that nudges the camera as the failure.

Andreas Ohrvall · Sep 24, 2026

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