When Image Cleanup Alters Mandatory Text: The Case for an Independent Reference

A German retailer’s carton-image cleanup shows why generative edits and visual checks are inadequate for mandatory text, and how deterministic processing with OCR and ink checks provides a stronger gate.

Product images can be cleaned up without changing what they say. That is the central lesson in a case account by Justin Flick, who writes for SOMUVA UG, the operator of the German-language online shop vapechamp.de. His team wanted to turn phone photographs of carton back panels into straightened images on a white background for online product pages. The panels carry legally required manufacturer and importer names, addresses and warning texts, along with contact details such as telephone numbers. The images could look better, but the printed information had to remain identical. In measurement terms, Flick says, the measurand was the printed text, not the appearance of the image.

The case sits outside a factory, and Flick describes it as small. Its relevance lies in a principle he draws from Gleb Tsipursky’s commentary on AI inspection: an automated result is only as trustworthy as the independent reference against which it has been checked. Tsipursky argued that quality leaders should measure disagreements between automated inspection and qualified human judgment before reducing human review. Flick applies that logic to image processing: if an output disagrees with a reliable reference, the disagreement must be explained before publication, not averaged into a similarity score.

A plausible image with altered information

The first attempt used a generative image model. The team supplied a straightened carton image and instructed the model to keep every printed character, number and symbol identical. The output looked professional, with sharp print, even lighting and a clean background. Comparison with the source revealed changes: the digits “2801” had become “2001,” a telephone number contained wrong digits, and commas and full stops had been exchanged in places. The alterations were plausible and therefore easy to miss at a glance. Because the panel carries mandatory information, the team discarded the generated images and published none of them.

Flick’s conclusion is narrow but important. A generative model produces text that plausibly looks like print; it does not guarantee the text that was actually printed. Visual inspection is a weak check against plausible errors, which is why it cannot serve as the reference. The point is not that every generated image is wrong, but that visual plausibility is insufficient evidence for text fidelity where legal information is involved.

A deterministic chain, with text protected

The replacement was a deterministic processing chain. The carton face is rectified with a perspective transform from four corner points. Uneven lighting is flattened by estimating the background illumination and dividing it out, followed by white balancing to a target tone. Denoising is gentle and edge-preserving. Text blocks are marked as protected regions, so their pixels pass through the background clean-up unchanged. The result is placed on a white background with a soft shadow. Nothing on the carton is redrawn or re-typeset; every character in the final panel is derived from the photographed pixels.

Two measurement principles and a gate

The team kept a reference for each image: the same crop after rectification and the illumination and white-balance step only, before denoising or clean-up. Each processed carton face was compared with that reference before being placed on the background, using two different measurement principles. The first was an OCR diff. Both images were read by an open-source OCR engine with German and English language data after upscaling; the resulting word sequences were aligned and every deviation listed. The second was an ink check that does not depend on reading text. Pixels clearly darker than the carton background in the reference count as print. If such pixels become light in the processed image and most of a connected group disappears, the group is flagged as a lost character.

The gate also showed that classical filters are not automatically safe. A speckle filter had turned “130” into “30” and removed colons. A threshold clean-up step had erased the dot in a web address. Both stages were dropped. As Flick puts it, any step that decides what counts as noise can decide that a full stop is noise. The lesson is that deterministic methods also require verification; they are not exempt from the same discipline applied to AI tools.

OCR is a measurement system, too

An OCR diff has its own measurement uncertainty. On small print, the OCR engine misread the reference image as well, for example reading a “5” as an “S.” A raw OCR diff therefore reports disagreements that the processing did not cause. Taken at face value, those reports lead to false rejects; ignored wholesale, they hide real changes and produce false accepts. Flick compares this with a gauge study: before attributing variation to the part, one separates the variation of the measurement system. In this case, the OCR’s misreads of the reference had to be separated from changes introduced by processing. A second, independent principle—the ink check—and a separate review step did that work.

This is where the disagreement audit becomes practical. Each disagreement was treated as a stop to be resolved, not as a similarity score to be averaged away. That matches Tsipursky’s third step: identify the source of the disagreement rather than assuming the person or the model must be wrong. For image processing, the source may be the processing step, the OCR engine, the reference, or the review process itself.

Review, backups and the published file

A separate automated review, independent of the processing chain, checked the images in two rounds. In the first round, a composite image failed because one inserted line could not be verified reliably. The team removed the composite and used the genuine information block from the carton instead. Before any image was replaced, the previous state was backed up so it could be restored. After publication, the team downloaded the files as actually delivered and compared them with its own. At reduced resolution, the mean absolute greyscale difference was well under one grey level. The published file is the last link in the chain and deserves the same check as every step before it.

What quality teams can take away

The practical points are specific. Define the measurand: for images carrying mandatory text, the characters matter, not the appearance. Keep a separate reference image from the earliest reliable processing step, and never compare an output only with itself. Use two measurement principles, such as an OCR text diff and a pixel-level ink check. Characterise the OCR’s own errors on the reference before trusting its verdicts. Treat any disagreement as a stop, not a score. Test classical filters as rigorously as AI tools. Add an independent second review and remove what cannot be verified. Back up before every change and pixel-compare the published files. Improve the input with frontal, unwrapped, frame-filling photographs taken in daylight.

Generative models remain useful for images where nothing has to be read. For images that carry mandatory information, Flick says the team now uses classical processing plus a text comparison against the original. The boundary is the presence of consequential text, not a blanket rejection of generative tools. The broader quality question is the one Tsipursky poses: when the machine and a qualified person disagree, do we know who was right, why, and what was changed afterward? For processed images, the same question applies when output and reference disagree. The answer should come before publication.

PD

Petra Dahlberg

Petra Dahlberg covers thermal and fluid equipment in industrial plants, with a focus on industrial chillers, compressors, pumps, heat exchangers, and control valves. Her reporting favors measurable evidence such as flow rate, head, differential pressure, dew point, compressor specific power, and vibration, and it treats ISO 12100 and IEC 60204-1 as boundary references only where they genuinely apply. She supports process engineers, maintenance managers, and capital procurement teams comparing utility and fluid systems on energy use, spare parts, and total cost of ownership.