Machine Vision & Industrial Inspection AI calculator
AI Inspection Sample Size Calculator
Plan a zero-failure inspection validation before booking line time. Enter the unacceptable inspection failure rate, required detection probability, planned runs, parts per run and system availability.
What this calculator does
- Size an independent zero-failure validation sample against an unacceptable inspection failure rate.
Formula used
- Required samples = ceiling(log(1 − confidence ÷ 100) ÷ log(1 − failure rate ÷ 100))
- Planned samples = floor(runs × parts per run × availability ÷ 100)
- Additional samples = max(required samples − planned samples, 0)
- Detection probability (%) = (1 − (1 − failure rate ÷ 100)^planned samples) × 100
- Gross planned parts = runs × parts per run
Inputs explained
- Validation Runs Planned: Independent validation runs in your campaign schedule.
- Parts per Validation Run: Planned independently scored trial parts in each run.
- Validation System Availability: Expected available inspection time during the planned runs.
- Unacceptable Inspection Failure Rate: Failure probability your zero-failure plan must discriminate.
- Required Failure Detection Probability: Required chance of finding a failure at that unacceptable rate.
How to use the result
- Best suited to planning known-defect recall validation, checking a zero-failure acceptance campaign.
- This is a zero-failure acceptance design, not a training dataset recommendation. Repeated views of one part do not provide independent trials. Small finite lots or clustered failures require a different sampling model.
Common questions
- What counts as an inspection failure? Use a prespecified wrong inspection decision against ground truth. For recall validation, test known-defective samples and count missed defects as failures.
- What does 95% detection probability mean? At the entered unacceptable failure rate, the required sample has at least a 95% chance of revealing one or more failures.
- Can I accept a plan with one failure? No. This design allows zero failures. Any observed failure requires investigation or a separately designed acceptance plan.
- Is the projected available sample enough to certify inspection? No. Availability only estimates completed trials. Confirm the actual independent sample count, zero observed failures and representative defect coverage before applying the statistical statement.
Last reviewed 2026-10-23.