AIEXPERTS/BD
Back to Blog
Industry

Computer Vision Quality Control in Garment Factories: A Practical Guide for Bangladesh RMG

16 min read

A 500,000-unit-per-month garment factory in Ashulia runs 15 to 25 human QC inspectors across inline stations and the final audit table. They still ship defective units. Chargebacks from buyers run between USD 0.50 and USD 3.00 per defect, plus rework and return shipping. The problem is not effort. It is scale and consistency — and no amount of additional inspectors will fix it.

This is the exact situation computer vision quality control was built to solve. If you run quality at a Bangladesh RMG factory, you already understand the "why." What you need is the "how": what defects the technology actually catches, what it costs in BDT, how it maps to your buyer's AQL and SEDEX requirements, and how to run a credible 90-day pilot without committing seven figures upfront. That is what this guide covers.

Direct answer (for those skimming): Computer vision quality control in a garment factory uses industrial cameras and a trained AI model to inspect garments at production line speed, flagging defects like broken stitches, stains, missing accessories, and shade variation in real time. End-of-line systems for Bangladesh factories typically cost USD 15,000 to USD 35,000 per inspection station and pay back within 4 to 9 months through reduced labour and chargebacks.

This article is the technical companion to our broader overview of AI applications across Bangladesh's garment industry. If you are still scoping AI use cases at the sector level, start there. If you are evaluating a CV inspection vendor, this guide is built for you.

What Computer Vision Quality Control Actually Does in a Garment Factory

Computer vision quality control is, at its core, a camera plus a trained model plus a decision rule. A camera array captures images of each garment as it moves through a production point. A computer vision model — trained on examples of clean and defective garments — classifies each image: pass, fail, or specific defect type. Defectives are flagged in real time for rework or rejection. No human inspection step required for the categories the model handles well.

The technical stack is simpler than vendors make it sound: industrial cameras (usually a few hundred USD each), a controlled lighting rig (LED panels with diffusers — fluorescent tubes create flicker artifacts that destroy model accuracy), an edge inference unit (a small industrial PC with a GPU), and integration with your line tracking or ERP system. Models commonly use YOLO (You Only Look Once) or EfficientDet architectures, both of which process images in under 20 milliseconds — fast enough for production line speed.

The edge versus cloud distinction matters for Bangladesh factories. Load shedding and inconsistent broadband make cloud-only inference a production risk. Any vendor proposing a system that stops working when your internet drops should be disqualified immediately. Look for on-device (edge) inference with periodic cloud syncing for reporting and model updates. We dig into this more in our guide to edge AI for factory floor deployment.

Where in the Production Flow Cameras Are Placed

There are five candidate inspection points, and where you place cameras determines both cost and value:

  • Pre-cutting (fabric roll inspection): Catches yarn-level defects before cutting. High value for upstream-integrated mills; lower priority for CMT operations.
  • Post-cutting (bundling): Detects shade variation between panels before they reach the sewing line. This is the single highest-leverage placement for knitwear and denim — shade variation caught here costs pennies; caught after sewing it costs the whole garment.
  • Inline at sewing stations: Captures broken stitches, skip stitches, and seam puckering in real time. Highest installation complexity.
  • End-of-line before folding: Replaces or supplements human final-table QC. The standard starting point.
  • Packing and shipping: Final accessory, label, and foreign object checks.

For a first pilot, start at end-of-line. Lowest installation complexity, cleanest before-and-after comparison, and immediate impact on the buyer-facing AQL data you already track.

Which Defects Computer Vision Catches — and Which It Doesn't

This is the section most CV vendor pages refuse to write honestly. Here is the practitioner version, mapped to the defect categories Bangladesh RMG factories actually face.

Defects Computer Vision Detects Reliably

For these categories, CV systems trained on a few hundred examples per class routinely achieve 92 to 97 percent accuracy under controlled lighting:

  • Broken stitch, skip stitch, open seam — clear visual signatures
  • Stains and contamination (oil, grease, rust, sweat)
  • Holes, snags, fabric tears
  • Missing or misplaced accessories — buttons, zippers, labels, hangtags
  • Foreign object detection, including needle fragments when paired with metal detection sensors
  • Shade variation between panels — requires spectrophotometric cameras, not standard RGB

If your top three buyer chargeback categories sit inside this list (and for most Bangladesh export factories they do), CV is a strong fit.

Defects Computer Vision Detects Inconsistently

Be cautious about vendor promises in these categories:

  • Seam puckering: Subtle texture variation; accuracy is highly model- and lighting-dependent. Expect 70 to 85 percent detection rates.
  • Minor measurement deviations: Standard inspection cameras cannot reliably measure chest, sleeve, or inseam to ±0.5 cm tolerance. This requires a separate calibrated measurement vision system (Vitronic, Orox, Uster).
  • Soft-handle and tactile defects: CV does not assess hand-feel, fabric drape, or weight. These remain human judgments.
  • Subtle density variation in knit fabric: Requires specialised imaging beyond standard inspection.

Current CV systems are not a full replacement for trained human sensory inspection in premium or high-fashion segments. They are best for high-volume basics, uniform workwear, and export commodity garments — which describes the majority of Bangladesh's RMG output. Match the technology to what you actually produce.

Measurement Deviation Detection (Treat as a Separate Decision)

If measurement-related rejections are your top chargeback category, automated measurement systems are a separate purchase. They use structured light or calibrated 2D vision to measure garment dimensions against spec sheets. Costs are typically 2 to 3 times higher than standard defect inspection. Pilot them only after your standard CV inspection is delivering proven results.

What AI Defect Detection Costs — Bangladesh Factory Economics

Vendor pages quote prices in USD without considering Bangladesh labour rates, electricity costs, or import duties. Here is the honest cost picture for a factory in Gazipur, Ashulia, Chittagong EPZ, or Narayanganj.

System Cost Tiers

TierWhat You GetCost (USD)Best For
1. Cloud SaaS inspection appTablet + AI-assisted human gradingUSD 300–1,000/monthFactories not ready for inline cameras
2. End-of-line inspection station1–2 cameras, lighting rig, edge compute, line integrationUSD 15,000–35,000 one-time50,000+ units/month
3. Inline automated inspectionCamera array at sewing/conveyor stationsUSD 50,000–150,000 per line300,000+ units/month per line
4. Full robotic inspectionGarment handling automation + CVUSD 300,000+ per lineOut of scope for most BD factories in 2026

For most Bangladesh export factories, Tier 2 is the right starting point. It delivers measurable improvement at a capex level a mid-sized factory can absorb without external financing.

Operating Costs

  • Electricity: Edge inference units draw 200 to 500 watts. At Bangladesh commercial rates (~BDT 10–12/kWh from BPDB), monthly power cost per station is BDT 1,500 to 4,000. Negligible.
  • Maintenance: Camera cleaning, periodic model retraining, software updates. Budget BDT 50,000 to 150,000 per year per mid-tier station.
  • Model training for new styles: Each new garment style needs 200 to 500 labelled defect images to fine-tune the model. A local labelling team (Bangladesh rates ~USD 3–8/hour) can prepare a new style in 1 to 2 days. Build this cost into your style changeover cycle, not as a one-time hit.

ROI Framework for Bangladesh Factories

Let us run the math on an illustrative end-of-line system at a 500,000-unit/month factory:

Labour offset. One end-of-line AI inspection station typically replaces or significantly reduces the workload of 2 to 4 final-table inspectors. At BDT 12,500/month minimum wage plus benefits (fully loaded ~BDT 18,000/month per worker), that is BDT 432,000 to 864,000 per year per station in saved labour — before any quality benefit.

Chargeback reduction. A factory shipping 500,000 units/month with 3 percent of defects reaching the buyer is shipping 15,000 defective units monthly. At a typical chargeback rate of USD 1.50/unit, that is USD 22,500/month or USD 270,000/year. Reducing the buyer-facing defect rate from 3 percent to 1 percent saves USD 180,000/year.

Payback. A Tier 2 system at BDT 2,500,000 (~USD 23,000), against combined savings of roughly USD 220,000 to USD 270,000/year, pays back in well under 6 months at this scale.

Treat these numbers as illustrative, not as a quote. Your defect rate, product mix, and buyer chargeback terms will move the calculation. For a structured way to build your own business case, work through our guide on how to measure AI ROI using your factory's actual numbers. The same chargeback-reduction logic applies to the broader category of reducing operational costs with AI.

How AI QC Data Supports Compliance Audits (SEDEX, Higg, BSCI, AQL)

This is the angle most CV vendors miss completely. The compliance value of digital QC data is often as large as the defect-reduction value — and it is what increasingly differentiates suppliers in buyer audits.

Buyer AQL Reports — Automated and Audit-Ready

AI inspection systems generate per-style, per-shift, per-defect-category reports automatically. These map directly to buyer AQL 2.5 or AQL 4.0 reporting requirements, which means no manual data compilation by your QC clerks the night before a buyer audit.

H&M, Zara, Inditex, PVH, Levi's, and Walmart are all moving toward requiring digital quality data alongside shipment documentation. Factories with auditable digital QC reduce buyer audit time materially and build buyer trust faster than factories relying on paper inspection records. Within three to five years, this will be a baseline expectation rather than a differentiator.

SEDEX SMETA and BSCI Audit Support

SEDEX SMETA audits and BSCI assessments both examine quality management documentation as part of management systems evaluation. AI QC data demonstrating systematic defect tracking, rework processes, and root-cause analysis supports the "documented quality management system" requirements under Pillar B (Health and Safety) and the management systems sections of both frameworks. It is not the primary data point either audit cares about, but it is one fewer thing to scramble for at audit time.

Higg FEM and Fabric Waste Tracking

The Higg FEM (Facility Environmental Module) tracks fabric efficiency as an environmental metric. AI marker optimisation reduces fabric waste; end-of-line inspection data on contamination and stain rates supports the chemical management documentation under FEM. If your factory reports through Cascale's Higg platform, integrate your AI QC outputs from day one rather than building a separate reporting pipeline later.

Needle Policy and Foreign Object Compliance

Most European and US buyers have mandatory needle policy requirements: every broken needle must be logged, accounted for, and traceable. CV systems with foreign object detection can automatically photograph and log needle fragments at inspection points. Paired with metal detection at final line and packing, this creates a documented, auditable needle-control system that satisfies buyer requirements without relying on worker self-reporting. For any factory currently failing buyer needle audits, this single capability often justifies the entire CV investment.

Running a 90-Day Computer Vision QC Pilot in a Bangladesh Garment Factory

A pilot does not need a seven-figure budget or six months of consulting. Here is the practical timeline that works for Bangladesh factories.

Step 1 — Define Your Defect Priority List (Week 1–2)

Pull the last six months of buyer rejection and chargeback reports. Identify your top three defect categories by frequency and cost. These are the defects your pilot must detect. Do not try to detect everything on day one — model accuracy collapses when you spread training data across too many classes.

For most Bangladesh export factories, the top three end up being some combination of stain/contamination, broken or skip stitch, and shade variation. Before you start, also work through our AI readiness assessment checklist for Bangladesh businesses to confirm your data and infrastructure are ready.

Step 2 — Assess Your Factory Environment (Week 2–3)

Three site assessments:

  • Lighting audit. Fluorescent tubes flicker at 50 Hz and create artifacts that destroy model accuracy. You will need LED panels with diffusers at the inspection station — budget BDT 50,000 to 150,000 per station for lighting upgrade.
  • Connectivity assessment. Confirm you have reliable local network for the inspection station, even if internet is intermittent. Edge inference means production never stops for connectivity, but you do need periodic sync.
  • Integration question. Can your existing ERP or production tracking system (Oracle NetSuite, SAP B1, or locally developed) accept QC data via API or CSV? If not, a standalone dashboard is acceptable for a pilot — integration can come later.

Step 3 — Collect Training Data (Week 3–6)

For a meaningful pilot, you need 300 to 500 labelled images per defect category — both defective and clean examples. Source them from your existing rejects pile and photograph them under the same lighting your inspection station will use. Label using free tools (Label Studio, CVAT) or hire a local labelling team. A competent local AI partner can run this entire step as part of the engagement.

Step 4 — Deploy and Calibrate (Week 6–10)

Install cameras at one end-of-line inspection station. Run the model in parallel with human inspectors for two weeks. Compare outputs every shift, retrain on the cases the model missed. Set confidence thresholds to match your AQL target: a higher threshold means fewer false negatives but more false positives requiring human review. Tune for the trade-off that fits your buyer's tolerance for misses.

Step 5 — Measure and Decide (Week 10–13)

Three metrics decide the pilot:

  1. Defect escape rate — defects reaching buyer audit before pilot versus during pilot.
  2. QC labour hours per 1,000 units — before versus during.
  3. Cost per unit of inspection — including system amortisation.

Based on those numbers, decide whether to extend the pilot to a full line, expand to additional defect categories, or discontinue. Honest pilots include all three outcomes — discontinue is a valid result if the numbers do not support continuing.

Selecting a Computer Vision QC Vendor or Partner for Your Factory

The vendor landscape splits into international platforms, local AI partners, and hybrid approaches. Each has real trade-offs.

International Vendors vs. Local Implementation Partners

International CV platforms (Inspectorio, Pivot88, TrusTrace inspection modules) offer mature software and buyer-recognised brand names, but pricing is typically calibrated for large factory groups — USD 2,000 to 10,000+ per month SaaS, and limited hands-on Bangladesh support. Good fit if your buyer specifically requests one of these platforms.

Local AI partners based in Bangladesh deliver lower cost, customisation for your specific defect types, training on your own factory data, and available on-site support. The question to ask: do they have manufacturing AI deployment experience, or only general software development experience? The two are not the same.

Hybrid approach — and the most cost-effective path for mid-sized Bangladesh factories — uses a local AI partner to build and maintain CV models on open-source frameworks (YOLOv8, EfficientDet, OpenCV), deployed on commodity industrial cameras and edge hardware. You own the model and the data; you are not locked into a vendor's SaaS pricing model forever.

Questions to Ask Any Vendor Before Committing

  1. How many garment factory deployments have you completed? Can you share references?
  2. What defect categories does your standard model detect, and what is the retraining process for new styles?
  3. How does model performance behave when a new fabric type or colour is introduced?
  4. Is inference on-device or cloud-dependent? What is the fallback when connectivity fails?
  5. What lighting hardware do you supply or specify?
  6. How do you integrate with our ERP or production tracking system?
  7. What is the model update schedule and who bears retraining cost?
  8. What is included in your standard SLA (uptime, response time, on-site support for Bangladesh)?

Red Flags to Watch For

  • Vendor quotes accuracy rates from academic benchmark datasets (DAGM, public fabric defect datasets) rather than from production data
  • No reference customers in garment manufacturing — CV for retail or warehouse use is a different problem than CV for manufacturing
  • Cloud-only inference with no edge option — creates production dependency on internet uptime
  • No clear process for training on your specific garment styles and your specific defects
  • Pricing tied to inspected-unit volumes with no cap — costs scale exponentially as your factory grows

Conclusion: Computer Vision QC Is the Most Mature AI Investment for Bangladesh RMG Today

Computer vision quality control is the single most ROI-demonstrable AI application available to Bangladesh garment factories right now. Unlike AI demand forecasting or predictive maintenance — both of which require data infrastructure investment before they produce results — computer vision QC delivers measurable, buyer-visible improvement inside a 90-day pilot.

Three takeaways to keep:

  1. Start at end-of-line, not inline. Lower cost, faster proof of value, cleaner before-and-after numbers.
  2. Define defect priorities from your actual chargeback data, not from vendor marketing decks or generic benchmarks. Your top three categories are what the pilot must solve.
  3. Choose a partner who trains on your styles, not someone selling you a pre-trained model built on someone else's factory. Customisation is where the accuracy lives.

Bangladesh's RMG sector is under simultaneous pressure from rising wages, regional competition, and buyer demands for digital compliance documentation. AI inspection is shifting from a competitive advantage to a baseline expectation for export-oriented factories within the next 3 to 5 years. The factories that pilot computer vision quality control now will have trained models, calibrated processes, and audit-ready data infrastructure before this becomes mandatory. The factories that wait will be doing this under deadline pressure from buyers — which is a worse position to negotiate from.

If you are evaluating computer vision QC for your garment operation, we can help you design a pilot that fits your factory's scale and budget. Tell us about your current defect rate and we will show you what is achievable in 90 days.

Related reading