Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We...

23
Grouping/Segmentation

Transcript of Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We...

Page 1: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

Grouping/Segmentation

Page 2: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

Does Canny always work?

Page 3: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

The challenges of edge detection

• Texture• Low-contrast boundaries

Page 4: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

What is texture?

• Hard to define, ambiguous concept• Some sort of pattern consisting of repeating elements• That we perceive as a pattern rather than individual elements• Often an indicator of:• Material: fur, sand, grass• Shape

Page 5: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

5

Textures

Terrycloth Rough Plastic Plaster-b

Sponge Rug-a Painted Spheres

Columbia-Utrecht Database (http://www.cs.columbia.edu/CAVE)

Page 6: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

Textures

Creator:WalterBaxter-2016Information extracted from IPTC Photo Metadata

A large collection of objects (birds/leaves) can also appear as texture

Page 7: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

Texture edges

• When can we detect texture boundaries?

Texture boundary

Page 8: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

Julesz�s texton theory

• Human Vision operates in two distinct modes:• Pre-attentive vision - parallel, instantaneous• Attentive vision - serial search by focusing on individual things

• Texture discrimination occurs in the pre-attentive mode• We don’t look at individual patterns but at statistics of the region

• What kind of statistics?• Not just average color• But density of certain elements – “textons”

8Slide adapted from Jitendra Malik

Page 9: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

Julesz�s texton theory

• Textons are:• Elongated blobs - e.g. rectangles, ellipses, line segments with specific

orientations, widths and lengths• Terminators - ends of line segments• Crossings of line segments

• Julesz arrived at these by experimenting on which textures were distinguishable

9Slide adapted from Jitendra Malik

Page 10: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

10

Distinguishable textures

Slide adapted from Jitendra Malik

Page 11: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

11

Distinguishable textures

Slide adapted from Jitendra Malik

Page 12: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

12

Indistinguishable textures

Slide adapted from Jitendra Malik

Page 13: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

How do we define textons?

• Use filter bank (i.e, set of filters) to detect oriented edges, spots etc• Identify repeated structures• Consider filter bank responses as “features” of a patch• Cluster patches: cluster centers form textons

Page 14: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

14

2D Textons• Goal: find canonical local features in a texture;

1) Filter image with linear filters:

2) Run k-means on filter outputs;3) k-means centers are the textons.

• Spatial distribution of textons defines the texture;

Slide adapted from Jitendra Malik

Page 15: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

15

Texton Labeling

• Each pixel labeled to texton i (1 to K) which is most similar in appearance;• Similarity measured by the Euclidean distance between

the filter responses;

Page 16: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

16

Material Representation

• Each material is now represented as a spatial arrangement of symbols from the textonvocabulary

• Texture is defined by first order statistics of texton distribution, i.e., average density

• For a given region, compute a histogram of textons as the representation: vector storing number of occurrences of each texton

Page 17: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

17

Histogram Models for Recognition(Leung & Malik, 1999)

Terrycloth

Rough Plastic

Pebbles

Plaster-b

Texton id à

Page 18: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

Using textons to identify boundaries

• At every location, try to identify texture boundaries for every orientation• Consider a disc at that location, split

into two halves by a diameter of a particular orientation• Want to measure the difference in

texture between the two halves

18

Page 19: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

19

Texture gradient

• Texture Gradient TG(x,y,r,q)• In each half, compute histogram of

textons• For each texton compute number of

occurrences• Compute distance between histograms

• A histogram is a vector è L2 distance• Better distance metrics available

q

r(x,y)

Page 20: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

20

Texture gradient = distance between textonhistograms in half disks across edge

i

j

k

0.1

0.8

}}

Page 21: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

Texture gradient

Image gradientTexture gradient

Why the double edge?

Page 22: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

Other techniques for grouping / segmentation

• Better contour detection• Learning-based edge detection (random forests, neural networks)• Contour completion and forming closed boundaries

• Better clustering• Graph-based clustering techniques (spectral clustering)• Clustering techniques that take contour information into account

Page 23: Grouping/Segmentation · • Texture discrimination occurs in the pre -attentive mode • We don’t look at individual patterns but at statistics of the region • What kind of statistics?

Grouping/Segmentation: a summary

• Goal: group pixels into objects• Simple solutions: edge detection, k-means• Challenges:• Texture: Possible solution: texture gradient• What is k?

• Grouping still a research problem!