• No results found

Content-Based Image Retrieval

N/A
N/A
Protected

Academic year: 2021

Share "Content-Based Image Retrieval"

Copied!
55
0
0

Loading.... (view fulltext now)

Full text

(1)

Content-Based Image Retrieval

Selim Aksoy

Department of Computer Engineering Department of Computer Engineering

Bilkent University

[email protected]

(2)

Image retrieval

Searching a large database for images that match a query:

What kind of databases?

What kind of queries?

What constitutes a match?

How do we make such searches efficient?

CS 484, Fall 2012 ©2012, Selim Aksoy 2

(3)

Applications

Art Collections

Fine Arts Museum of San Francisco

Medical Image Databases

CT, MRI, Ultrasound, The Visible Human

Scientific Databases

Earth Sciences

General Image Collections for Licensing General Image Collections for Licensing

Corbis, Getty Images

The World Wide Web

Google, Microsoft, Flickr

(4)

Corel data set

CS 484, Fall 2012 ©2012, Selim Aksoy 4

60,000 images with annotated keywords

(5)

Fine Arts Museum of San Francisco

80,000 images

(6)

Query formulation

Text description (keywords) Query by example

Query by example

Query by sketch

CS 484, Fall 2012 ©2012, Selim Aksoy 6

Symbolic description (man and woman on a beach)

Relevance feedback

(7)

Google query on “rose”

(8)

Corel query on “rose”

CS 484, Fall 2012 ©2012, Selim Aksoy 8

(9)

Corbis query on “rose”

(10)

Difficulties with keywords

Images may not have keywords.

(An image is worth … how many key-words?)

Query is not easily satisfied by keywords.

“A casually dressed couple gazing into each others eyes lovingly with dramatic clouds in the background.”

“Pretty girl doing something active, sporty in a

summery setting, beach - not wearing lycra, exercise clothes - more relaxed in tee-shirt. Feature is about

CS 484, Fall 2012 ©2012, Selim Aksoy 10

clothes - more relaxed in tee-shirt. Feature is about deodorant so girl should look active - not sweaty but happy, healthy, carefree - nothing too posed or set up - nice and natural looking.”

Content-based image retrieval (CBIR)

(11)

Content-based image retrieval

Query Image Retrieved Images

User

Image Database

Distance Measure

User

Image Feature Feature Space Images

(12)

Image representations and features

Image representations:

Iconic Global Global

Region-based Object-based

Image features:

Color Texture

CS 484, Fall 2012 ©2012, Selim Aksoy 12

Texture Shape

Objects and their relationships

(this is the most powerful, but you have to be able to recognize the objects!)

(13)

Image similarity

Distance measures:

Euclidean distance Other Lp metrics

Histogram intersection Cosine distance

Earth mover’s distance

Probabilistic similarity measures:

P( relevance | two images )

P( relevance | two images ) / P( irrelevance | two images)

(14)

Global histograms

Searching using global color histograms

CS 484, Fall 2012 ©2012, Selim Aksoy 14

(15)

Global histograms

“Airplanes” using color histograms (4/12) “Sunsets” using Gabor texture (3/12)

(16)

Query by image content (QBIC)

CS 484, Fall 2012 ©2012, Selim Aksoy 16

(17)

Color histograms in QBIC

The QBIC color histogram distance is:

d

hist

(I,Q) = (h(I) - h(Q))

T

A (h(I) - h(Q)).

d

hist

(I,Q) = (h(I) - h(Q)) A (h(I) - h(Q)).

h(I) is a K-bin histogram of a database image.

h(Q) is a K-bin histogram of the query image.

A is a K x K similarity matrix.

R G B Y C V

1 0 0 .5 0 .5 0 1 0 .5 .5 0 R

G

How similar is blue to cyan?

0 1 0 .5 .5 0 0 0 1

1

1 G

B Y

C

?

?

(18)

Color percentages in QBIC

CS 484, Fall 2012 ©2012, Selim Aksoy 18

%40 red, %30 yellow, %10 black

(19)

Color layout in QBIC

(20)

Earth mover’s distance

CS 484, Fall 2012 ©2012, Selim Aksoy 20

(21)

Earth mover’s distance

Visualization using EMD and multidimensional

scaling

(22)

Probabilistic similarity measures

Two classes:

Relevance class A Irrelevance class B Irrelevance class B

Bayes classifier

Assign (ξi,ξj) to

Discriminant function for classification



 >

otherwise B

)) ,

(

| P(B ))

, (

| P(A if

Α ξi ξj ξi ξj

P(A) A)

| ) , P((

)) ,

(

|

P(A ξ ξ ξ ξ

CS 484, Fall 2012 ©2012, Selim Aksoy 22

Rank images according to posterior ratio values based on feature differences.

P(B) B)

| ) , P((

P(A) A)

| ) , P((

)) ,

(

| P(B

)) ,

(

| ) P(A

,

∆(

j i

j i j

i j i j

i ξ ξ

ξ ξ ξ

ξ ξ ξ ξ

ξ = =

(23)

Probabilistic similarity measures

“Residential interiors” (12/12) “Fields” (12/12)

(24)

Shape-based retrieval

CS 484, Fall 2012 ©2012, Selim Aksoy 24

(25)

Shape-based retrieval

(26)

Elastic shape matching

CS 484, Fall 2012 ©2012, Selim Aksoy 26

(27)

Iconic matching

(28)

Iconic matching

Wavelet-based image compression Quantization of coefficients

Quantization of coefficients

CS 484, Fall 2012 ©2012, Selim Aksoy 28

(29)

Iconic matching

(30)

Region-based retrieval: Blobworld

CS 484, Fall 2012 ©2012, Selim Aksoy 30

(31)

Region-based retrieval: Blobworld

(32)

Retrieval using spatial relationships

Build graph using regions and their spatial relationships.

Similarity is computed using graph Similarity is computed using graph matching.

sky

tiger

above adjacent above

inside image

CS 484, Fall 2012 ©2012, Selim Aksoy 32

sand

tiger inside grass

above above

adjacent abstract regions

(33)

Combining multiple features

Text query on

“rose”

(34)

Combining multiple features

Visual query on

CS 484, Fall 2012 ©2012, Selim Aksoy 34

(35)

Combining multiple features

Text query Text query

on

“rose”

and visual query

on

(36)

Video Google: object matching

CS 484, Fall 2012 ©2012, Selim Aksoy 36

(37)

Video Google

Viewpoint invariant Viewpoint invariant descriptors

Visual vocabulary

(38)

Video Google

Now is the time Document 1

Word Document

Inverted index Now is the time

for all good men to come to the aid of their country.

Document 2

Word Document

aid 1

all 1

and 2

can 2

come 1, 2

country 1

for 1

CS 484, Fall 2012 ©2012, Selim Aksoy 38

Summer has come

and passed. The innocent can never last.

for 1

good 1

the 1, 1, 2

(39)

Video skimming

(40)

Event detection, indexing, retrieval

CS 484, Fall 2012 ©2012, Selim Aksoy 40

(41)

Informedia Digital Video Library

IDVL interface returned for "El Nino" query along with different multimedia abstractions from certain documents.

(42)

Informedia Digital Video Library

IDVL interface returned IDVL interface returned for “bin ladin" query.

CS 484, Fall 2012 ©2012, Selim Aksoy 42

The results can be tuned using many classifiers.

(43)

Relevance feedback

In real interactive CBIR systems, the user should be allowed to interact with the system to “refine”

the results of a query until he/she is satisfied.

the results of a query until he/she is satisfied.

(44)

Relevance feedback

Example methods:

Query point movement

Query point is moved toward positive examples and moved away from negative examples.

Weighting features

The CBIR system should automatically adjust the weight that were given by the user for the relevance of previously retrieved documents.

Weighting similarity measures

CS 484, Fall 2012 ©2012, Selim Aksoy 44

Weighting similarity measures Feature density estimation

Probabilistic relevance feedback

(45)

Relevance feedback

Positive feedback

A)p(A)

| p(

)

|

p(A|

ξ

, ∝ )

ξ

p( | A)p(A| )

p(A|

ξ

,

ξ

+ , ∝ )

ξ

+p( | A)p(A

ξ

| , )

p(A|

ξ

,

ξ

+ ,

ξ

+,)

ξ

p(+ | A)p(A

ξ

|

ξ

+, , , )

p(A ξ ξ + K ξ +ξ + ξ ξ + K ξ +

B)p(B)

| p(

)

| p(B

A)p(A)

| p(

)

| p(A

(0) (0)

(0)

(0)

ξ

ξ ξ ξ

∝∝

)

| B)p(B

| p(

) ,

| p(B

)

| A)p(A

| p(

) ,

| p(A

(0) (1)

(1) (0)

(0) (1)

(1)

(0)

ξ ξ ξ

ξ ξ ξ ξ ξ

+ +

+ +

∝∝

) ,

| B)p(B

| p(

) ,

,

| p(B

) ,

| A)p(A

| p(

) ,

,

| p(A

(1) (0)

(2) (2)

(1) (0)

(1) (0)

(2) (2)

(1)

(0) + + + +

+ +

+ +

∝∝

ξ ξ

ξ ξ

ξ

ξ ξ ξ ξ ξ ξ ξ

) ,

, ,

| B)p(B

| p(

) ,

, ,

| p(B

) ,

, ,

| A)p(A

| p(

) ,

, ,

| p(A

1) (n- (1)

(0) (n)

(n) (1)

(0)

1) (n- (1)

(0) (n)

(n) (1)

(0) + + + + +

+ +

+ +

+

∝∝

ξ ξ

ξ ξ

ξ ξ

ξ

ξ ξ

ξ ξ

ξ ξ

ξ

K K

K K

) ,

, ,

,

|

p(A|

ξ

(0),

ξ

(1)+ ,K,

ξ

(n)+ ,

ξ

(1) ,)

p(A|

ξ

(0),

ξ

(1)+ ,K,

ξ

(n)+ ,

ξ

(1) ,

ξ

(2) ,) p(A|

ξ

(0),

ξ

(1)+ , K,

ξ

(n)+ ,

ξ

(1) ,

ξ

(2),

ξ

(3)) ∝ p(A ξ ξ + K ξ(n)+ ξ K ξ(m)

) 1 ( )

1 ( ) 0 (

Negative feedback

) ,

, ,

| A)p(B

| p(

) ,

, ,

,

| p(B

) ,

, ,

| B)p(A

| p(

) ,

, ,

,

| p(A

(n) (1)

(0) (1)

(1) (n)

(1) (0)

(n) (1)

(0) (1)

(1) (n)

(1) (0)

+ +

+

+

+ +

ξ ξ

ξ

ξ ξ ξ ξ

ξ ξ ξ ξ ξ ξ ξ ξ ξ

K K

K K

) ,

, ,

,

| A)p(B

| p(

) ,

, ,

, ,

| p(B

) ,

, ,

,

| B)p(A

| p(

) ,

, ,

, ,

| p(A

(1) (n)

(1) (0)

(2)

(2) (1)

(n) (1)

(0)

(1) (n)

(1) (0)

(2)

(2) (1)

(n) (1)

(0)

+

+

+

+

+

+

ξ ξ

ξ ξ

ξ ξ ξ ξ ξ

ξ ξ ξ ξ ξ ξ ξ ξ ξ ξ ξ

K

K

K K

) ,

, ,

, ,

| A)p(B

| p(

) ,

, ,

, ,

,

| p(B

) ,

, ,

, ,

| B)p(A

| p(

) ,

, ,

, ,

,

| p(A

(2) (1)

(n) (1)

(0) (3)

(3) (2)

(1) (n)

(1) (0)

(2) (1)

(n) (1)

(0) (3)

(3) (2)

(1) (n)

(1) (0)

+

+

+

+

+

+

ξ ξ

ξ ξ

ξ

ξ ξ ξ ξ ξ ξ

ξ ξ ξ ξ ξ ξ ξ ξ ξ ξ ξ ξ ξ

K

K

K K

) ,

, ,

, ,

,

| A)p(B

| p(

) ,

, ,

, ,

,

| p(B

) ,

, ,

, ,

,

| B)p(A

| p(

) ,

, ,

, ,

,

| p(A

1) (m- (n)

(m)

(m) (n)

1) (m- (n)

(m)

(m) (n)

+

+

+

+

+

+

ξ ξ

ξ ξ

ξ ξ

ξ ξ

ξ ξ

ξ

ξ ξ

ξ ξ

ξ ξ

ξ ξ

ξ ξ

ξ

K K

K K

K K

K K

) 1 ( )

1 ( ) 0 ( ) 1 ( )

1 ( ) 0 (

) 1 ( )

1 ( ) 0 (

) 1 ( )

1 ( ) 0 (

(46)

Relevance feedback

“Sunsets” using color histograms Using combined features (6/12) After 1st feedback (12/12)

CS 484, Fall 2012 ©2012, Selim Aksoy 46

“Sunsets” using color histograms (1/12)

Using combined features (6/12) After 1st feedback (12/12)

(47)

Relevance feedback

“Auto racing” using color Using combined features (9/12) After 1st feedback (12/12)

“Auto racing” using color histograms (3/12)

Using combined features (9/12) After 1st feedback (12/12)

(48)

Indexing for fast retrieval

Use of key images and the triangle inequality for efficient retrieval.

CS 484, Fall 2012 ©2012, Selim Aksoy 48

(49)

Indexing for fast retrieval

Offline

1. Choose a small set of key images.

2. Store distances from database images to keys.

Online (given query Q)

1. Compute the distance from Q to each key.

2. Obtain lower bounds on distances to database images.

3. Threshold or return all images in order of lower bounds.

(50)

Indexing for fast retrieval

Hierarchical cellular tree

CS 484, Fall 2012 ©2012, Selim Aksoy 50

(51)

Indexing for fast retrieval

(52)

Performance evaluation

Two traditional measures for retrieval

performance in the information retrieval literature are precision and recall.

are precision and recall.

Given a particular number of images retrieved,

precision is defined as the percentage of retrieved images that are actually relevant, and

recall is defined as the percentage of relevant images that are retrieved.

CS 484, Fall 2012 ©2012, Selim Aksoy 52

that are retrieved.

(53)

Current research objective

Query Image Retrieved Images

User boat

Image Database User

Animals Buildings

Office Buildings Houses

Transportation

Object-oriented Images

Transportation

•Boats

•Vehicles

(54)

Demos

Blobworld (http://elib.cs.berkeley.edu/blobworld/) Video Google (http://www.robots.ox.ac.uk/~vgg/

research/vgoogle/index.html) research/vgoogle/index.html)

FIDS (http://www.cs.washington.edu/research/

imagedatabase/demo/fids/)

Like Visual Shopping (http://www.like.com/)

Google Image Search (http://images.google.com/) Yahoo Image Search

CS 484, Fall 2012 ©2012, Selim Aksoy 54

Yahoo Image Search

(http://images.search.yahoo.com/) Flickr (http://flickr.com/)

The ESP game (http://www.espgame.org/)

(55)

Demos

Vitalas

http://vitalas.ercim.eu/

Google Similar Images Google Similar Images

http://googleblog.blogspot.com/2009/10/similar- images-graduates-from-google.html

Google Image Swirl

http://googleresearch.blogspot.com/2009/11/explore- images-with-google-image-swirl.html

images-with-google-image-swirl.html

Microsoft Bing

http://www.bing.com/

First use keywords, then mouse over an image and click

References

Related documents

The different channels of communication between employees may be used as a data source to extract corporate social network and results of such network analysis can be used as

Previous work has used modelled temperature on a 1 km grid for London to estimate UHI impacts on health by summing health effects by UHI zones depending on loca- tion [23]

RQ12: Is there a difference in ELA (i.e., Florida Standards Assessment annual English Language Arts achievement test) scores among grade five students by their levels of proficiency

Because the types of implant systems with different macro and microstructure might affect the failure or success of treatment, we performed clinical and radiological evaluations

9: Aspect of environmental degradation known by age 68 Table 5.1: Stakeholders and their stake in the conservation of Nairobi River basin 73 Table 5.2 : Respondents' view on who

The most innovative result of our econometric study is to state, through an analysis of each kind of sport infrastructures, that the sport practice supply in an acceptable distance

Recently-issued guidelines for the administration and prescription of opioids can help to direct prescribers, however all opioid dispensation should be guided by a combination

First Legal has created a Litigation Cost Containment Solution that provides negotiated rates directly to companies for these legal services (court filings, court research,