Chapter 20 Accuracy

20.1 Introduction accurately characterizing performance: important aspect of vision system

20.2 Mensuration Quantizing Error position on digital grid: has inherent quantizing error due to discreteness B: coordinate of line’s right endpoint Δc: spacing between pixel centers q: uniform random variable, 0 ≤ q ≤ 1 B = Δc(B^{∗} − 1/2 + q) B^{∗} = Ceiling(B/Δc − 1/2) relationship between the line segment end and the digital grid =====Fig. 20.1=====

β^{∗}: digital coordinate of the line’s rightmost pixel natural quantizing model:

β^{∗} = \{ \begin{matrix}B^{∗} & with probability q \\ B^{∗} − 1 & with probability 1 − q \end{matrix}

letting x be a random variable where

x = \{ \begin{matrix}1 & with probability q \\ 0 & with probability 1 − q \end{matrix}

restate the quantizing model:

β^{∗} = B^{∗} − 1 + x

note: E(x) = q and E(x^{2}) = q the mean of digital coordinate β^{∗}:

E(β^{∗}) = E(B^{∗} − 1 + x) = E (\frac{B}{Δc} + \frac{1}{2} − q − 1 + x) = \frac{B}{Δc} − \frac{1}{2}

thus unbiased estimator B̂ for position B is B̂ = Δc(β^{∗} + \frac{1}{2}) the variance of digital coordinate β^{∗}:

V (β^{∗}) = E \{[β^{∗} − (\frac{B}{Δc} − \frac{1}{2})]^{2}\} = E [(B^{∗} − 1 + x − \frac{B}{Δc} + \frac{1}{2})^{2}]

= E[(x − q)^{2}] = E(q − 2q^{2} + q^{2}) = E(q − q^{2}) = \frac{1}{2} − \frac{1}{3} = \frac{1}{6}

A: line’s left endpoint handled in a similar way

20.3 Automated Position Inspection: False-Alarm and Misdetection Rates in industrial position inspection: mechanism machines part to specification inspection: ensures machining or part placement is correct automated inspector: consists of machine identifying critical object points t: known number for relative position x: actual position x: Gaussian distribution with mean t and standard deviation σ_{x} t ± α: tolerance interval centered around position t |x − t| < α: position is good |x − t| ≥ α: position is bad

actual position x: not known measurement y: obtained by observing actual position and measuring it measurement y: noisy and not equal to x y given x: Gaussian distribution with mean x and standard deviation σ_{y} t ± β: acceptance interval for decision that actual position in tolerance |y − t| < β: inspection system decides the position is good |y − t| ≥ β: inspection system decides the position is bad false alarm: good position falsely called bad misdetection: bad position missed and incorrectly called good false-alarm rate is the conditional probability:

P_{F} = P (|y − t| > β | |x − t| < α)

misdetection rate is the conditional probability:

P_{M} = P (|y − t| < β | |x − t| > α)

entire probability model: characterized by five parameters t, σ_{x}, σ_{y}, α, β problem: how to compute false-alarm and misdetection probabilities

20.3.1 Analysis P (x): probability density function for actual position x P (y|x): conditional probability density function for y given x with Gaussian distribution assumption:

P (x) = \frac{1}{\sqrt{2π}σ_{x}}e^{−\frac{1}{2}(\frac{x−t}{σx})^{2}}

P (y|x) = \frac{1}{\sqrt{2π}σ_{y}}e^{−\frac{1}{2}(\frac{y−x}{σy})^{2}}

conditional probability P (|y − t| < β | |x − t| < α) closely related to false-alarm probability:

P (|y − t| < β | |x − t| < α) = 1 − P (|y − t| > β | |x − t| < α) = 1 − P_{F}

now

P (|y − t| < β | |x − t| < α) = P (−β ≤ y − t ≤ β| − α ≤ x − t ≤ α)

= \frac{P (−α ≤ x − t ≤ α, −β ≤ y − t ≤ β)}{P (−α ≤ x − t ≤ α)} = \frac{∫_{x=−α+t}^{α+t} ∫_{y=−β+t}^{β+t} P (y|x)P (x)dydx}{∫_{x=−α+t}^{α+t} P (x)dx}

= \frac{∫_{x=−α+t}^{α+t} ∫_{y=−β+t}^{β+t} \frac{1}{\sqrt{2π}σ_{x}}e^{−\frac{1}{2}(\frac{x−t}{σx})^{2}} \frac{1}{\sqrt{2π}σ_{y}}e^{−\frac{1}{2}(\frac{y−x}{σy})^{2}}dydx}{∫_{x=−α+t}^{α+t} \frac{1}{\sqrt{2π}σ_{x}}e^{−\frac{1}{2}(\frac{x−t}{σx})^{2}}dx}

inherent invariance of false-alarm and misdetection probabilities to the scale

σ_{x}, σ_{y}, α, β define relative precision r of the measurement:

r = \frac{σ_{y}}{2α} = \frac{σ_{y}}{2k_{α}σ_{y}} = \frac{1}{2k_{α}}

=====Garfield 17:67=====

20.3.2 Discussion when k_{β} = \frac{β}{σ_{y}} large: acceptance interval large k_{β} large: all good positions are accepted k_{β} large: false-alarm rate small k_{β} large: bad positions will also be accepted k_{β} large: high rate of misdetection k_{β} small: acceptance interval relatively small k_{β} small: all bad positions expected not to be accepted k_{β} small: misdetection rate small k_{β} small: good positions will also not be accepted k_{β} small: high rate of false alarm false alarm rate and misdetection rate approximately inverse proportional three operating curves for a fixed failure rate of 0.05 top operating curve: relative precision of 0.1 middle operating curve: relative precision of 0.065 bottom operating curve: relative precision of 0.05 =====Fig. 20.2===== three operating curves for a fixed failure rate of 0.01 top operating curve: relative precision of 0.1 middle operating curve: relative precision of 0.075 bottom operating curve: relative precision of 0.05 =====Fig. 20.3===== fix failure rate and misdetection rate: as relative precision r better,

tolerance interval i.e. st. dev. of measurements smaller operating curves for smaller values of relative precision below larger ones

fix relative precision and misidentification rate: as failure rate increases false-alarm rate increases three operating curves for a fixed relative precision of 0.075 top operating curve: failure rate of 0.02 middle operating curve: failure rate of 0.01 bottom operating curve: failure rate of 0.005 =====Fig. 20.4===== operating curves for larger failure rates uniformly above smaller ones

for failure rate to increase when relative precision fixed, tolerance interval

must remain the same while st. dev. of actual position increase if acceptance interval does not change, misidentification rate decreases

20.4 Experimental Protocol controlled experiments: important component of computer vision experimental protocol: so experiment can be repeated and evidence verified by

another researcher experiment protocol states:

• quantity (or quantities) to be measured

• accuracy of measurement

• population of scenes/images or artificially generated data protocol: gives experimental design and data analysis plan

The experimental design describes how a suitably random, independent, and representative set of images from the specified population is to be sampled, generated, or acquired. accuracy criterion: how comparison between true, measured values evaluated experimental data analysis plan: how hypothesis meets specified requirement experimental data analysis plan: how observed data analyzed experimental data analysis plan: detailed enough for another researcher analysis plan: supported by theoretically developed statistical analysis

20.5 Determining the Repeatability of Vision Sensor Measuring Positions vision sensors: measure position or location in 1D, 2D, 3D to determine repeatability of vision sensor: some number of points, times

20.5.1 The Model N: number of points to be measured μ_{1}, ..., μ_{N}: actual but unknown positions of these points M: number of times each point is measured K: each point is K-dimensional Y_{nm}: mth measurement of the nth point assumption: measurements independent assumption: difference between actual and measured positions N(0, r^{2}I) r: standard deviation describing repeatability of vision sensor

20.5.2 Derivation mean observed positions:

μ̂_{n} = \frac{1}{M} M ; ∑ ; m=1 Y_{nm}

sum of norms squared of differences between observed positions and mean:

S^{2} = N ; ∑ ; n=1 M ; ∑ ; m=1(Y_{nm} − μ̂_{n})′(Y_{nm} − μ̂_{n})

We need to determine the relationship between S^{2} and r^{2}.

20.6 Determining the Positional Accuracy of Vision Sensors vision sensors: may measure position in 1D, 2D, 3D To determine the accuracy of the vision sensor (after it has been suitably calibrated), an experiment must be performed in which some number of points in known positions are exposed to the sensor, the measured positions are compared with the known positions, and the accuracy is computed in terms of the degree to which the actual and measured positions agree. positions of points: random and not follow regular pattern number of points measured large enough: variance of accuracy small

20.6.1 The Model N: number of points to be measured μ_{1}, ..., μ_{N}: actual but unknown positions of these points μ_{1}^{∗}, ..., μ_{N}^{∗}: unknown expected positions of these points N points: independent N points: deviations between actual and nominal position N(0, σ_{1}^{2}I) M: number of times each point is measured K: each point is K-dimensional Y_{nm}: mth measurement of nth point assumption: measurements independent difference between μ_{n}, Y_{nm}: N(μ_{n} + b_{n}, r^{2}I) bias vector b_{n}: N(0, σ_{b}^{2}I) positional accuracy of vision sensor: described by r^{2} + σ_{b}^{2} The purpose of the experiment is to estimate r^{2} + σ_{b}^{2} by using a large enough number of samples so that the unbiased estimate σ̂_{2} of r̂^{2} + σ̂_{b}^{2} is guaranteed to be sufficiently close to r^{2} + σ_{b}^{2}.

20.6.2 Derivation sum of norms squared of differences between observed and known positions:

S^{2} = N ; ∑ ; n=1(Y_{n} − μ_{n})′(Y_{n} − μ_{n})

We need to determine the relationship between S^{2}, σ_{1}^{2}, σ_{2}^{2}.

20.7 Performance Assessment of Near-Perfect Machines machines in recognition and defect inspection: required to be nearly flawless error rate: fraction of time that machine’s judgment incorrect error rate: contains false detection and misdetection errors false-detection rate: false-alarm rate: unflawed part judged flawed misdetection rate: flawed part judged unflawed

20.7.1 Derivation consider false-alarm errors; misdetection errors similar N: sampling size, total number of parts observed K: number of false-alarm judgements observed to occur in acceptance test f_{∘}: machine performance specification of false-alarm fraction maximum likelihood estimate f̂ of f based on K: f̂ = K/N f̂ < f_{∘}: machine passes acceptance test f̂ > f_{∘}: machine fails acceptance test f: true error rate X_{n}: random variable taking value 1 for false alarm, 0 otherwise

in maximum-likelihood technique, compute estimate f̂ as f maximizing:

P rob ( N ; ∑ ; n=1 X_{n} = K|f) = ( \begin{matrix}N \\ K \end{matrix} ) f^{K}(1 − f)^{N−K}

20.7.2 Balancing the Acceptance Test If the buyer and seller balance their own self-interests exactly in a middle compromise, the operating point chosen for the acceptance test will be the one for which the falseacceptance rate (which the buyer wants to be small) equals the missed-acceptance rate (which the seller wants to be small).

20.7.3 Lot Assessment In the usual lot inspection approach, a quality control inspector makes a complete inspection on a randomly chosen small sample from each lot. reason for not inspecting all of the lot: cost more than specified number of defective products found: entire lot rejected

20.8 Summary mensuration quantizing error model: computes variance due to random error =====Oldie 33:120=====