# 0.18 The vapnik-chervonenkis inequality

 Page 1 / 1

## The vapnik-chervonenkis inequality

The VC inequality is a powerful generalization of the bounds we obtained for the hyperplane classifier in the previous lecture . The basic idea of the proof is quite similar. Before starting the inequality, we need to introduce theconcept of shatter coefficients and VC dimension.

## Shatter coefficients

Let $\mathcal{A}$ be a collection of subsets of ${\mathcal{R}}^{d}$ , definition: The ${n}^{th}$ shatter coefficient of $\mathcal{A}$ is defined by

${\mathcal{S}}_{\mathcal{A}}\left(n\right)=\begin{array}{c}max\\ {x}_{1},...,{x}_{n}\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}{\mathcal{R}}^{d}\end{array}\left|\left\{,\left\{{x}_{1},...,{x}_{n}\right\},\bigcap ,A,,,A,\phantom{\rule{0.166667em}{0ex}},ϵ,\phantom{\rule{0.166667em}{0ex}},\mathcal{A},\right\}\right|.$

The shatter coefficients are a measure of the richness of the collection $\mathcal{A}$ . ${\mathcal{S}}_{\mathcal{A}}\left(n\right)$ is the largest number of different subsets of a set of $n$ points that can be generated by intersecting the set with elements of $\mathcal{A}$ .

In 1-d, Let $\mathcal{A}=\left\{\left(-,\infty ,,,t\right],t\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{R}\right\}$ Possible subsets of $\left\{{x}_{1},...,{x}_{n}\right\}$ generated by intersecting with sets of the form $\left(-,\infty ,,,t\right]$ are $\left\{{x}_{1},...,{x}_{n}\right\},\phantom{\rule{0.166667em}{0ex}}\left\{{x}_{1},\phantom{\rule{0.166667em}{0ex}}...,{x}_{n-1}\right\},\phantom{\rule{0.166667em}{0ex}}...,\phantom{\rule{0.166667em}{0ex}}\left\{{x}_{1}\right\},\phantom{\rule{0.166667em}{0ex}}\phi$ . Hence ${\mathcal{S}}_{d}\left(n\right)=n+1$ .

In 2-d, Let $\mathcal{A}$ = $\left\{$ all rectangles in ${\mathcal{R}}^{2}$ $\right\}$

Consider a set $\left\{{x}_{1},\phantom{\rule{0.166667em}{0ex}}{x}_{2},\phantom{\rule{0.166667em}{0ex}}{x}_{3},\phantom{\rule{0.166667em}{0ex}}{x}_{4}\right\}$ of training points. If we arrange the four points into the corner of a diamond shape. It's easyto see that we can find a rectangle in ${\mathcal{R}}^{2}$ to cover any subsets of the four points as the above picture, i.e. ${\mathcal{S}}_{\mathcal{A}}\left(4\right)={2}^{4}=16$ .

Clearly, ${\mathcal{S}}_{\mathcal{A}}\left(n\right)={2}^{n},n=1,\phantom{\rule{0.166667em}{0ex}}2,\phantom{\rule{0.166667em}{0ex}}3$ as well.

However, for $n=5,{\mathcal{S}}_{\mathcal{A}}\left(n\right)<{2}^{5}$ . This is because we can always select four points such that the rectangle, which just contains fourof them, contains the other point. Consequently, we cannot find a rectangle classifier which contains the four outer points and does not contain the innerpoint as shown above.

Note the ${\mathcal{S}}_{\mathcal{A}}\le {2}^{n}$ .

If $\left|\left\{,\left\{{x}_{1},...,{x}_{n}\right\},\bigcap ,A,,,A,\phantom{\rule{0.166667em}{0ex}},ϵ,\phantom{\rule{0.166667em}{0ex}},\mathcal{A},\right\}\right|={2}^{n}$ then we say that $\mathcal{A}$ shatters ${x}_{1},\phantom{\rule{0.166667em}{0ex}}...,\phantom{\rule{0.166667em}{0ex}}{x}_{n}$ .

## Vc dimension

The VC dimension
${V}_{\mathcal{A}}$ of a collection of sets $\mathcal{A}$ is defined as the largest interger $n$ such that ${S}_{\mathcal{A}}\left(n\right)={2}^{n}$ .

## Sauer's lemma:

Let $\mathcal{A}$ be a collection of set with VC dimension ${V}_{\mathcal{A}}<\infty$ . Then $\forall n,{\mathcal{S}}_{\mathcal{A}}\left(n\right)\le {\sum }_{i=0}^{{V}_{\mathcal{A}}}\left(\begin{array}{c}n\\ i\end{array}\right)$ , also ${\mathcal{S}}_{\mathcal{A}}\left(n\right)\le {\left(n+1\right)}^{{V}_{\mathcal{A}}},\forall n$ .

## Vc dimension and classifiers

Let $\mathcal{F}$ be a collection of classifiers of the form $f:{\mathcal{R}}^{d}\to \left\{0,1\right\}$ Define $\mathcal{A}=\left\{\left\{x:f\left(x\right)=1\right\}×\left\{0\right\}\bigcup \left\{x:f\left(x\right)=0\right\}×\left\{1\right\},f\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{F}\right\}$ In words, this is collection of subsets of $\mathcal{X}×\mathcal{Y}$ for which on $fϵ\mathcal{F}$ maps the features $x$ to a label opposite of $y$ .  The size of $\mathcal{A}$ expresses the richness of $\mathcal{F}$ .  The larger $\mathcal{A}$ is the more likely it is that there exists an $fϵ\mathcal{F}$ for which $R\left(f\right)=P\left(f\left(X\right)\ne Y\right)$ is close to the Bayes risk ${R}^{*}=P\left({f}^{*}\left(X\right)\ne Y\right)$ where ${f}^{*}$ is the Bayes classifier. The ${n}^{th}$ shatter coefficient of $\mathcal{F}$ is defined as ${\mathcal{S}}_{\mathcal{F}}\left(n\right)={\mathcal{S}}_{\mathcal{A}}\left(n\right)$ and the VC dimesion of $\mathcal{F}$ is defined as ${V}_{\mathcal{F}}={V}_{\mathcal{A}}$ .

linear (hyperplane) classifiers in ${\mathcal{R}}^{d}$

Consider $d$ = 2. Let $n$ be the number of training points, it is easy to see that when $n=1$ , let $\mathcal{A}$ be as above. By using linear classifiers in ${\mathcal{R}}^{2}$ , it is easy to see that we can assign 1 to all possible subsets $\left\{\left\{{x}_{1}\right\},\phi \right\}$ and 0 to their complements. Hence ${\mathcal{S}}_{\mathcal{F}}\left(1\right)=2$ .

When $n=2$ , we can also assign 1 to all possible subsets $\left\{\left\{{x}_{1},{x}_{2}\right\},\phantom{\rule{0.166667em}{0ex}}\left\{{x}_{1}\right\},\phantom{\rule{0.166667em}{0ex}}\left\{{x}_{2}\right\},\phantom{\rule{0.166667em}{0ex}}\phi \right\}$ and 0 to their complements, and vice versa. Hence ${\mathcal{S}}_{\mathcal{F}}\left(2\right)=4={2}^{2}$ .

When $n=3$ , we can arrange arrange the point ${x}_{1},\phantom{\rule{0.166667em}{0ex}}{x}_{2},\phantom{\rule{0.166667em}{0ex}}{x}_{3}$ (non-colinear) so that the set of linear classifiers shatters the three points, hence ${\mathcal{S}}_{\mathcal{F}}\left(3\right)=8={2}^{3}$

When $n=4$ , no matter where the points ${x}_{1},\phantom{\rule{0.166667em}{0ex}}{x}_{2},\phantom{\rule{0.166667em}{0ex}}{x}_{3},\phantom{\rule{0.166667em}{0ex}}{x}_{4}$ and what designated binary values ${y}_{1},\phantom{\rule{0.166667em}{0ex}}{y}_{2},\phantom{\rule{0.166667em}{0ex}}{y}_{3},\phantom{\rule{0.166667em}{0ex}}{y}_{4}$ are. It's clear that $\mathcal{A}$ does not shatter the four points. To see the claim, first observe that the four points will form a 4-gon (if the four points are co-linear, or if the three points are co-linear then clearly linear classifiers cannot shatter the points). The two points that belong to the same diagonal lines form 2 groups and no linear classifier can assign different values to the 2 groups. Hence ${\mathcal{S}}_{\mathcal{F}}\left(4\right)<16={2}^{4}$ and ${V}_{\mathcal{F}}=3$ .

We state here without proving it that in general the class of linear classifiers in ${\mathcal{R}}^{d}$ has ${V}_{\mathcal{F}}=d+1$ .

## The vc inequality

Let ${X}_{1},\phantom{\rule{0.166667em}{0ex}},...,\phantom{\rule{0.166667em}{0ex}}{X}_{n}$ be i.i.d. ${\mathcal{R}}^{d}$ -valued random variables. Denote the common distribution of ${X}_{i},1\le i\le n$ by $\mu \left(A\right)=P\left({X}_{1}\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}A\right)$ for any subset $A\subset {\mathcal{R}}^{d}$ . Similarly, define the empirical distribution ${\mu }_{n}\left(A\right)=\frac{1}{n}{\sum }_{1}^{n}{1}_{\left\{{X}_{i}ϵA\right\}}$ .

Theorem

## Vc '71

For any probablilty measure $\mu$ and collection of subsets $\mathcal{A}$ , and for any $ϵ>0$ .

$P\left(\begin{array}{c}sup\\ Aϵ\mathcal{A}\end{array},\left|{\mu }_{n},\left(A\right),-,\mu ,\left(A\right)\right|,>,ϵ\right)\le 8{\mathcal{S}}_{\mathcal{A}}\left(n\right){e}^{-n{ϵ}^{2}/32}$

and

$E\left[\begin{array}{c}sup\\ Aϵ\mathcal{A}\end{array},\left|{\mu }_{n},\left(A\right),-,\mu ,\left(A\right)\right|\right]\le 2\sqrt{\frac{log2{\mathcal{S}}_{\mathcal{A}}\left(n\right)}{n}}$

Before giving a proof to the theorem. We present a Corollary.

Corollary

Let $\mathcal{F}$ be a collection of classifiers of the form $f:{\mathcal{R}}^{d}\to \left\{0,1\right\}$ with VC dimension ${V}_{\mathcal{F}}<\infty$ ,  Let $R\left(f\right)=P\left(f\left(X\right)\ne Y\right)$ and ${\stackrel{^}{R}}_{n}\left(f\right)=\frac{1}{n}{\sum }_{1}^{n}{1}_{\left\{f\left({X}_{i}\right)\ne {Y}_{i}\right\}}$ , where ${X}_{i},{Y}_{i},1\le i\le n$ are i.i.d. with joint distribution ${P}_{XY}$ .

Define

${\stackrel{^}{f}}_{n}=\begin{array}{c}argmin\\ fϵ\mathcal{F}\end{array}{\stackrel{^}{R}}_{n}\left(f\right)$ .

Then

$E\left[R\left({\stackrel{^}{f}}_{n}\right)\right]-\begin{array}{c}inf\\ fϵ\mathcal{F}\end{array}R\left(f\right)\le 4\sqrt{\frac{{\mathcal{V}}_{\mathcal{F}}log\left(n,+,1\right)+log2}{n}}.$

Let $\mathcal{A}=\left\{\left\{x:f\left(x\right)=1\right\}×\left\{0\right\}\bigcup \left\{x:f\left(x\right)=0\right\}×\left\{1\right\},f\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{F}\right\}$

Note that

$P\left(f\left(X\right)\ne Y\right)=P\left(\left(X,Y\right)\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}A\right):=\mu \left(A\right)$

where $A=\left\{x:f\left(x\right)=1\right\}×\left\{0\right\}\bigcup \left\{x:f\left(x\right)=0\right\}×\left\{1\right\}$ .

Similarly,

$\frac{1}{n}\sum _{1}^{n}{1}_{\left\{f\left({X}_{i}\right)\phantom{\rule{0.166667em}{0ex}}\ne \phantom{\rule{0.166667em}{0ex}}{Y}_{i}\right\}}=\frac{1}{n}\sum _{1}^{n}{1}_{\left\{\left({X}_{i},{Y}_{i}\right)\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}A\right\}}:=\mu \left(A\right).$

Therefore, according to the VC theorem.

$\begin{array}{ccc}\hfill E\left[\begin{array}{c}sup\\ f\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{F}\end{array},\left|{\stackrel{^}{R}}_{n},\left(f\right),-,R,\left(f\right)\right|\right]=E\left[\begin{array}{c}sup\\ A\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{A}\end{array},\left|{\mu }_{n},\left(A\right),-,\mu ,\left(A\right)\right|\right]& \le & 2\sqrt{\frac{log2{\mathcal{S}}_{\mathcal{A}}\left(n\right)}{n}}\hfill \\ & =& 2\sqrt{\frac{log2{\mathcal{S}}_{\mathcal{F}}\left(n\right)}{n}}\hfill \end{array}$

Since ${V}_{\mathcal{F}}<\infty ,{\mathcal{S}}_{\mathcal{F}}\left(n\right)\le {\left(n+1\right)}^{{V}_{\mathcal{F}}}$ and

$E\left[\begin{array}{c}sup\\ fϵ\mathcal{F}\end{array},\left|{\stackrel{^}{R}}_{n},\left(f\right),-,R,\left(f\right)\right|\right]\le 2\sqrt{\frac{{V}_{\mathcal{F}}log\left(n+1\right)+log2}{n}}.$

Next, note that

$\begin{array}{ccc}\hfill R\left({\stackrel{^}{f}}_{n}\right)-\begin{array}{c}inf\\ f\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{F}\end{array}R\left(f\right)& =& \left[R,\left({\stackrel{^}{f}}_{n}\right),-,{\stackrel{^}{R}}_{n},\left({\stackrel{^}{f}}_{n}\right)\right]+\left[{\stackrel{^}{R}}_{n},\left({\stackrel{^}{f}}_{n}\right),-,\begin{array}{c}inf\\ f\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{F}\end{array},R,\left(f\right)\right]\hfill \\ & =& \left[R,\left({\stackrel{^}{f}}_{n}\right),-,{\stackrel{^}{R}}_{n},\left({\stackrel{^}{f}}_{n}\right)\right]+\left[\begin{array}{c}sup\\ f\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{F}\end{array},\left({\stackrel{^}{R}}_{n},\left({\stackrel{^}{f}}_{n}\right),-,R,\left(f\right)\right)\right]\hfill \\ & \le & \left[R,\left({\stackrel{^}{f}}_{n}\right),-,{\stackrel{^}{R}}_{n},\left({\stackrel{^}{f}}_{n}\right)\right]+\left[\begin{array}{c}sup\\ f\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{F}\end{array},\left({\stackrel{^}{R}}_{n},\left(f\right),-,R,\left(f\right)\right)\right]\hfill \\ & \le & 2\begin{array}{c}sup\\ f\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{F}\end{array}\left|{\stackrel{^}{R}}_{n},\left(f\right),-,R,\left(f\right)\right|\hfill \end{array}.$

Therefore,

$\begin{array}{ccc}\hfill E\left[R,\left({\stackrel{^}{f}}_{n}\right)\right]-\begin{array}{c}inf\\ f\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{F}\end{array}R\left(f\right)& \le & 2E\left[\begin{array}{c}sup\\ f\phantom{\rule{0.166667em}{0ex}}ϵ\phantom{\rule{0.166667em}{0ex}}\mathcal{F}\end{array},\left|{\stackrel{^}{R}}_{n},\left(f\right),-,R,\left(f\right)\right|\right]\hfill \\ & \le & 4\sqrt{\frac{{V}_{\mathcal{F}}log\left(n+1\right)+log2}{n}}\phantom{\rule{4pt}{0ex}}\phantom{\rule{4pt}{0ex}}\phantom{\rule{4pt}{0ex}}\phantom{\rule{4pt}{0ex}}\phantom{\rule{4pt}{0ex}}\phantom{\rule{4pt}{0ex}}\hfill \end{array}.$

where we get a research paper on Nano chemistry....?
nanopartical of organic/inorganic / physical chemistry , pdf / thesis / review
Ali
what are the products of Nano chemistry?
There are lots of products of nano chemistry... Like nano coatings.....carbon fiber.. And lots of others..
learn
Even nanotechnology is pretty much all about chemistry... Its the chemistry on quantum or atomic level
learn
da
no nanotechnology is also a part of physics and maths it requires angle formulas and some pressure regarding concepts
Bhagvanji
hey
Giriraj
Preparation and Applications of Nanomaterial for Drug Delivery
revolt
da
Application of nanotechnology in medicine
what is variations in raman spectra for nanomaterials
ya I also want to know the raman spectra
Bhagvanji
I only see partial conversation and what's the question here!
what about nanotechnology for water purification
please someone correct me if I'm wrong but I think one can use nanoparticles, specially silver nanoparticles for water treatment.
Damian
yes that's correct
Professor
I think
Professor
Nasa has use it in the 60's, copper as water purification in the moon travel.
Alexandre
nanocopper obvius
Alexandre
what is the stm
is there industrial application of fullrenes. What is the method to prepare fullrene on large scale.?
Rafiq
industrial application...? mmm I think on the medical side as drug carrier, but you should go deeper on your research, I may be wrong
Damian
How we are making nano material?
what is a peer
What is meant by 'nano scale'?
What is STMs full form?
LITNING
scanning tunneling microscope
Sahil
how nano science is used for hydrophobicity
Santosh
Do u think that Graphene and Fullrene fiber can be used to make Air Plane body structure the lightest and strongest. Rafiq
Rafiq
what is differents between GO and RGO?
Mahi
what is simplest way to understand the applications of nano robots used to detect the cancer affected cell of human body.? How this robot is carried to required site of body cell.? what will be the carrier material and how can be detected that correct delivery of drug is done Rafiq
Rafiq
if virus is killing to make ARTIFICIAL DNA OF GRAPHENE FOR KILLED THE VIRUS .THIS IS OUR ASSUMPTION
Anam
analytical skills graphene is prepared to kill any type viruses .
Anam
Any one who tell me about Preparation and application of Nanomaterial for drug Delivery
Hafiz
what is Nano technology ?
write examples of Nano molecule?
Bob
The nanotechnology is as new science, to scale nanometric
brayan
nanotechnology is the study, desing, synthesis, manipulation and application of materials and functional systems through control of matter at nanoscale
Damian
Is there any normative that regulates the use of silver nanoparticles?
what king of growth are you checking .?
Renato
What fields keep nano created devices from performing or assimulating ? Magnetic fields ? Are do they assimilate ?
why we need to study biomolecules, molecular biology in nanotechnology?
?
Kyle
yes I'm doing my masters in nanotechnology, we are being studying all these domains as well..
why?
what school?
Kyle
biomolecules are e building blocks of every organics and inorganic materials.
Joe
how did you get the value of 2000N.What calculations are needed to arrive at it
Privacy Information Security Software Version 1.1a
Good
Got questions? Join the online conversation and get instant answers!