image and multimedia miningchristos/talks/mld-ss06/mld-ss06-v32.pdf · searching multimedia...
TRANSCRIPT
1
CMU SCS
Image and Multimedia Mining
Christos Faloutsos
CMU
MLD school 06 Copyright: C. Faloutsos, 2006 2
CMU SCS
Outline
• Problem definition and motivation
• Indexing and feature extraction
• Features for images (DWT, morphology,
etc)
• Tools and case studies: PCA, ICA, Random
Walks
• Conclusions
MLD school 06 Copyright: C. Faloutsos, 2006 3
CMU SCS
Problem #1: Similarity search• [Bob Murphy] Sub-cellular protein localization patterns
MLD school 06 Copyright: C. Faloutsos, 2006 4
CMU SCS
Problem #1: Similarity search
NucleolarMitoch. Actin
TubulinEndosomal
MLD school 06 Copyright: C. Faloutsos, 2006 5
CMU SCS
day
$price
1 365
day
$price
1 365
day
$price
1 365
distance function? <later>
Problem#1’: Similarity search:
MLD school 06 Copyright: C. Faloutsos, 2006 6
CMU SCS
Problem #2: Mining• [Bob Murphy] Sub-cellular protein localization patterns
2
MLD school 06 Copyright: C. Faloutsos, 2006 7
CMU SCS
day
$price
1 365
day
$price
1 365
day
$price
1 365
distance function? <later>
Problem#2’: Mining
MLD school 06 Copyright: C. Faloutsos, 2006 8
CMU SCS
Problem definition
• Given: many sequences (images, video-
clips)
x1 , x2 , … , xt , …
(y1, y2, … , yt, …
… )
• Find
– similar sequences / images / video-clips
– patterns; clusters; outliers
MLD school 06 Copyright: C. Faloutsos, 2006 9
CMU SCS
Motivation - applications: Images
• medical/biological images (training;
research)
• biometrics/security
• satellite image analysis
• photo collections
• museum images
• logos
• ... MLD school 06 Copyright: C. Faloutsos, 2006 10
CMU SCS
Motivation - applications: Video
• surveillance
• TV news processing (eg., summarization -www.informedia.cs.cmu.edu)
• 3-d images (medical / biological)
• 3-d and 4-d datasets (x,y,z, time, temp.,
humidity etc) - weather/environment
monitoring
MLD school 06 Copyright: C. Faloutsos, 2006 11
CMU SCS
Motivation - applications: Time
sequences• Financial, sales, economic series
• Medical (ECGs/EKGs, monitoring)
• civil infrastructure; automobile traffic
monitoring
MLD school 06 Copyright: C. Faloutsos, 2006 12
CMU SCS
Motivation
water distribution network
(w/ Jeanne Vanbriesen, CMU)
Phase 1 Phase 2 Phase 3
: : : : : :
: : : : : :
chlorine concentrations
3
MLD school 06 Copyright: C. Faloutsos, 2006 13
CMU SCS
Motivation - Applications
(cont’d)
• Weather, environment/anti-pollution
• computer network traffic monitoring
• data-center traffic monitoring (self-*
system at CMU)
MLD school 06 Copyright: C. Faloutsos, 2006 14
CMU SCS
Outline
• Problem definition and motivation
• Indexing and feature extraction
• Features for images (DWT, morphology,
etc)
• Tools and case studies: PCA, ICA, Random
Walks
• Conclusions
MLD school 06 Copyright: C. Faloutsos, 2006 15
CMU SCS
Indexing
Problem:
• given a set of time sequences,
• find the ones similar to a desirable query
sequence
MLD school 06 Copyright: C. Faloutsos, 2006 16
CMU SCS
day
$price
1 365
day
$price
1 365
day
$price
1 365
distance function: by expert
MLD school 06 Copyright: C. Faloutsos, 2006 17
CMU SCS
Idea: ‘GEMINI’
Eg., ‘find stocks similar to MSFT’
Seq. scanning: too slow
How to accelerate the search?
[Faloutsos96]
MLD school 06 Copyright: C. Faloutsos, 2006 18
CMU SCS
day1 365
day1 365
S1
Sn
F(S1)
F(Sn)
‘GEMINI’ - Pictorially
eg, avg
eg,. std
4
MLD school 06 Copyright: C. Faloutsos, 2006 19
CMU SCS
GEMINI
Solution: Quick-and-dirty' filter:
• extract n features (numbers, eg., avg., etc.)
• map into a point in n-d feature space
• organize points with off-the-shelf spatial
access method (‘SAM’)
• discard false alarms
MLD school 06 Copyright: C. Faloutsos, 2006 20
CMU SCS
Examples of GEMINI
• Time sequences: DFT (up to 100 times
faster) [SIGMOD94];
• [Kanellakis+], [Mendelzon+]
MLD school 06 Copyright: C. Faloutsos, 2006 21
CMU SCS
Examples of GEMINI
Also, on many other data types:
• Images (QBIC) [JIIS94]
• tumor-like shapes [VLDB96]
• video [Informedia + S-R-trees]
• automobile part shapes [Kriegel+97]
MLD school 06 Copyright: C. Faloutsos, 2006 22
CMU SCS
Indexing - SAMs
Q: How do Spatial Access Methods (SAMs)
work?
A: they group nearby points (or regions)
together, on nearby disk pages, and answer
spatial queries quickly (‘range queries’,
‘nearest neighbor’ queries etc)
For example:
MLD school 06 Copyright: C. Faloutsos, 2006 23
CMU SCS
R-trees
• [Guttman84] eg., w/ fanout 4: group nearby
rectangles to parent MBRs; each group ->
disk page
A
B
C
DE
FG
H
I
J
adv
MLD school 06 Copyright: C. Faloutsos, 2006 24
CMU SCS
R-trees
• eg., w/ fanout 4:
A
B
C
DE
FG
H
I
J
P1
P2
P3
P4
F GD E
H I JA B C
adv
5
MLD school 06 Copyright: C. Faloutsos, 2006 25
CMU SCS
R-trees
• eg., w/ fanout 4:
A
B
C
DE
FG
H
I
J
P1
P2
P3
P4
P1 P2 P3 P4
F GD E
H I JA B C
adv
MLD school 06 Copyright: C. Faloutsos, 2006 26
CMU SCS
R-trees - range search?
A
B
C
DE
FG
H
I
J
P1
P2
P3
P4
P1 P2 P3 P4
F GD E
H I JA B C
adv
MLD school 06 Copyright: C. Faloutsos, 2006 27
CMU SCS
R-trees - range search?
A
B
C
DE
FG
H
I
J
P1
P2
P3
P4
P1 P2 P3 P4
F GD E
H I JA B C
adv
MLD school 06 Copyright: C. Faloutsos, 2006 28
CMU SCS
Conclusions
• Fast indexing: through GEMINI
– feature extraction and
– (off the shelf) Spatial Access Methods
[Gaede+98]
MLD school 06 Copyright: C. Faloutsos, 2006 29
CMU SCS
Outline
• Problem definition and motivation
• Indexing and feature extraction
• Features for images (DWT, morphology,
etc)
• Tools and case studies: PCA, ICA, Random
Walks
• Conclusions
MLD school 06 Copyright: C. Faloutsos, 2006 30
CMU SCS
Outline
• Problem definition and motivation
• Indexing and feature extraction
– DFT, DWT etc
– SVD/PCA
– MDS and FastMap
• ...
6
MLD school 06 Copyright: C. Faloutsos, 2006 31
CMU SCS
DFT and cousins
• very good for compressing real signals
• more details on DWT: later
MLD school 06 Copyright: C. Faloutsos, 2006 32
CMU SCS
DFT and stocks
0.00
2000.00
4000.00
6000.00
8000.00
10000.00
12000.00
1 11 21 31 41 51 61 71 81 91 101 111 121
Fourier appx actual
• Dow Jones Industrial
index, 6/18/2001-
12/21/2001
MLD school 06 Copyright: C. Faloutsos, 2006 33
CMU SCS
DFT and stocks
0.00
2000.00
4000.00
6000.00
8000.00
10000.00
12000.00
1 11 21 31 41 51 61 71 81 91 101 111 121
Fourier appx actual
• Dow Jones Industrial
index, 6/18/2001-
12/21/2001
• just 3 DFT
coefficients give very
good approximation
1
10
100
1000
10000
100000
1000000
10000000
1 11 21 31 41 51 61 71 81 91 101 111 121
Series1
freq
Log(ampl)
MLD school 06 Copyright: C. Faloutsos, 2006 34
CMU SCS
Outline
• Problem definition and motivation
• Indexing and feature extraction
– DFT, DWT etc
– SVD/PCA
– MDS and FastMap
• ...
MLD school 06 Copyright: C. Faloutsos, 2006 35
CMU SCS
SVD
• THE optimal method for dimensionality
reduction
– (under the Euclidean metric)
MLD school 06 Copyright: C. Faloutsos, 2006 36
CMU SCS
SVD - Motivation
area
bri
ghtn
ess
7
MLD school 06 Copyright: C. Faloutsos, 2006 37
CMU SCS
SVD - Motivation
area
bri
ghtn
ess
MLD school 06 Copyright: C. Faloutsos, 2006 38
CMU SCS
SVD – dim. reduction
• minimum RMS error
SVD: gives
best axis to project
v1
area
bri
ghtn
ess
MLD school 06 Copyright: C. Faloutsos, 2006 39
CMU SCS
Singular Value Decomposition
(SVD)• SVD (~LSI ~ KL ~ PCA ~ spectral
analysis...)
• LSI: S. Dumais; M. Berry
• KL: eg, Duda+Hart
• PCA: eg., Jolliffe
• Details: [Press+], [Faloutsos96]
MLD school 06 Copyright: C. Faloutsos, 2006 40
CMU SCS
SVD
• Extremely useful tool
– (also behind PageRank/google and Kleinberg’s
algorithm for hubs and authorities)
• But may be slow: O(N * M * M) if N>M
• any approximate, faster method?
MLD school 06 Copyright: C. Faloutsos, 2006 41
CMU SCS
SVD shorcuts• random projections (Johnson-Lindenstrauss
thm [Papadimitriou+ pods98])
MLD school 06 Copyright: C. Faloutsos, 2006 42
CMU SCS
Random projections
• pick ‘enough’ random directions (will be
~orthogonal, in high-d!!)
• distances are preserved probabilistically,
within epsilon
• (also, use as a pre-processing step for SVD
[Papadimitriou+ PODS98])
8
MLD school 06 Copyright: C. Faloutsos, 2006 43
CMU SCS
Outline
• Problem definition and motivation
• Indexing and feature extraction
– DFT, DWT etc
– SVD
– MDS and FastMap
• ...
MLD school 06 Copyright: C. Faloutsos, 2006 44
CMU SCS
MDS / FastMap
• but, what if we have NO points to start
with?
(eg. Time-warping distance)
• A: Multi-dimensional Scaling (MDS) ;
FastMap
MLD school 06 Copyright: C. Faloutsos, 2006 45
CMU SCS
MDS/FastMap
01100100100O5
10100100100O4
100100011O3
100100101O2
100100110O1
O5O4O3O2O1~100
~1
~1
MLD school 06 Copyright: C. Faloutsos, 2006 46
CMU SCS
MDS
Multi Dimensional
Scaling
MLD school 06 Copyright: C. Faloutsos, 2006 47
CMU SCS
FastMap
• Multi-dimensional scaling (MDS) can do
that, but in O(N**2) time
• FastMap [Faloutsos+95] takes O(N) time
MLD school 06 Copyright: C. Faloutsos, 2006 48
CMU SCS
FastMap: Application
VideoTrails [Kobla+97]
scene-cut detection (about 10% errors)
9
MLD school 06 Copyright: C. Faloutsos, 2006 49
CMU SCS
Conclusions - Practitioner’s
guide
Similarity search in time sequences
1) establish/choose distance (Euclidean, time-
warping,…)
2) extract features (SVD, DWT, MDS), and use
an SAM (R-tree/variant) or a Metric Tree (M-
tree)
2’) for high intrinsic dimensionalities, consider sequential
scan (it might win…)
MLD school 06 Copyright: C. Faloutsos, 2006 50
CMU SCS
Books
• William H. Press, Saul A. Teukolsky, William T.
Vetterling and Brian P. Flannery: Numerical Recipes in C,
Cambridge University Press, 1992, 2nd Edition. (Great
description, intuition and code for SVD)
• C. Faloutsos: Searching Multimedia Databases by Content,
Kluwer Academic Press, 1996 (introduction to SVD, and
GEMINI)
MLD school 06 Copyright: C. Faloutsos, 2006 51
CMU SCS
References
• Agrawal, R., K.-I. Lin, et al. (Sept. 1995). Fast Similarity
Search in the Presence of Noise, Scaling and Translation in
Time-Series Databases. Proc. of VLDB, Zurich,
Switzerland.
• Babu, S. and J. Widom (2001). “Continuous Queries over
Data Streams.” SIGMOD Record 30(3): 109-120.
• Breunig, M. M., H.-P. Kriegel, et al. (2000). LOF:Identifying Density-Based Local Outliers. SIGMOD
Conference, Dallas, TX.• Berry, Michael: http://www.cs.utk.edu/~lsi/
MLD school 06 Copyright: C. Faloutsos, 2006 52
CMU SCS
References
• Ciaccia, P., M. Patella, et al. (1997). M-tree: An Efficient
Access Method for Similarity Search in Metric Spaces.
VLDB.
• Foltz, P. W. and S. T. Dumais (Dec. 1992). “Personalized
Information Delivery: An Analysis of Information
Filtering Methods.” Comm. of ACM (CACM) 35(12): 51-
60.
• Guttman, A. (June 1984). R-Trees: A Dynamic Index
Structure for Spatial Searching. Proc. ACM SIGMOD,
Boston, Mass.
MLD school 06 Copyright: C. Faloutsos, 2006 53
CMU SCS
References
• Gaede, V. and O. Guenther (1998). “Multidimensional
Access Methods.” Computing Surveys 30(2): 170-231.
• Gehrke, J. E., F. Korn, et al. (May 2001). On Computing
Correlated Aggregates Over Continual Data Streams.
ACM Sigmod, Santa Barbara, California.
MLD school 06 Copyright: C. Faloutsos, 2006 54
CMU SCS
References
• Gunopulos, D. and G. Das (2001). Time Series Similarity
Measures and Time Series Indexing. SIGMOD
Conference, Santa Barbara, CA.
• Hatonen, K., M. Klemettinen, et al. (1996). Knowledge
Discovery from Telecommunication Network Alarm
Databases. ICDE, New Orleans, Louisiana.
• Jolliffe, I. T. (1986). Principal Component Analysis,Springer Verlag.
10
MLD school 06 Copyright: C. Faloutsos, 2006 55
CMU SCS
References
• Keogh, E. J., K. Chakrabarti, et al. (2001). Locally
Adaptive Dimensionality Reduction for Indexing Large
Time Series Databases. SIGMOD Conference, Santa
Barbara, CA.
• Kobla, V., D. S. Doermann, et al. (Nov. 1997).
VideoTrails: Representing and Visualizing Structure in
Video Sequences. ACM Multimedia 97, Seattle, WA.
MLD school 06 Copyright: C. Faloutsos, 2006 56
CMU SCS
References
• Oppenheim, I. J., A. Jain, et al. (March 2002). A MEMS
Ultrasonic Transducer for Resident Monitoring of Steel
Structures. SPIE Smart Structures Conference SS05, San
Diego.
• Papadimitriou, C. H., P. Raghavan, et al. (1998). Latent
Semantic Indexing: A Probabilistic Analysis. PODS,
Seattle, WA.
• Rabiner, L. and B.-H. Juang (1993). Fundamentals of
Speech Recognition, Prentice Hall.
MLD school 06 Copyright: C. Faloutsos, 2006 57
CMU SCS
References
• Traina, C., A. Traina, et al. (October 2000). Fast feature
selection using the fractal dimension,. XV Brazilian
Symposium on Databases (SBBD), Paraiba, Brazil.
MLD school 06 Copyright: C. Faloutsos, 2006 58
CMU SCS
References• Dennis Shasha and Yunyue Zhu High Performance
Discovery in Time Series: Techniques and Case StudiesSpringer 2004
• Yunyue Zhu, Dennis Shasha ``StatStream: StatisticalMonitoring of Thousands of Data Streams in Real Time'‘VLDB, August, 2002. pp. 358-369.
• Samuel R. Madden, Michael J. Franklin, Joseph M.Hellerstein, and Wei Hong. The Design of an AcquisitionalQuery Processor for Sensor Networks. SIGMOD, June2003, San Diego, CA.
MLD school 06 Copyright: C. Faloutsos, 2006 59
CMU SCS
Outline
• Problem definition and motivation
• Indexing and feature extraction
• Features for images (DWT, morphology,
etc)
• Tools and case studies: PCA, ICA, Random
Walks
• Conclusions
MLD school 06 Copyright: C. Faloutsos, 2006 60
CMU SCS
How to extract features?
• Eg.: [Bob Murphy]: protein localization images
ER
Tubulin DNATfRActin
NucleolinMitoLAMP
gpp130giantin
11
MLD school 06 Copyright: C. Faloutsos, 2006 61
CMU SCS
ER
Tubulin DNATfRActin
NucleolinMitoLAMP
gpp130giantin
How to extract features?
• Eg.:
ERERERER
brightness(?)brightness(?)brightness(?)brightness(?)
area(?)area(?)area(?)area(?) MitMitMitMit
MLD school 06 Copyright: C. Faloutsos, 2006 62
CMU SCS
(Natural) image features
[Flickner+, 95] from IBM’s QBIC:
• Color
• Shape
• Texture
MLD school 06 Copyright: C. Faloutsos, 2006 63
CMU SCS
(Natural) image features
[Flickner+, 95] from IBM’s QBIC:
• Color: average R/G/B; color histograms
• Shape
• Texture
MLD school 06 Copyright: C. Faloutsos, 2006 64
CMU SCS
Images - shapes
• distance function: Euclidean, on the area,
perimeter, and 20 ‘moments’ [QBIC, ’95]
• Q: other ‘features’ / distance functions?
MLD school 06 Copyright: C. Faloutsos, 2006 65
CMU SCS
Images - shapes
• (A1: turning angle)
• A2: wavelets
• A3: morphology: dilations/erosions
• ...
MLD school 06 Copyright: C. Faloutsos, 2006 66
CMU SCS
Images - shapes
• (A1: turning angle)
• A2: wavelets
• A3: morphology: dilations/erosions
• ...
angle
length
θ
12
MLD school 06 Copyright: C. Faloutsos, 2006 67
CMU SCS
Wavelets - example
http://grail.cs.washington.edu/projects/query/Wavelets achieve *great* compression:
20 100 400 16,000
# coefficients
MLD school 06 Copyright: C. Faloutsos, 2006 68
CMU SCS
Wavelets - intuition
• Edges (horizontal; vertical; diagonal)
MLD school 06 Copyright: C. Faloutsos, 2006 69
CMU SCS
Wavelets - intuition
• Edges (horizontal; vertical; diagonal)
• recurse
MLD school 06 Copyright: C. Faloutsos, 2006 70
CMU SCS
Wavelets - intuition
• Edges (horizontal; vertical; diagonal)
• http://www331.jpl.nasa.gov/public/wave.ht
ml
MLD school 06 Copyright: C. Faloutsos, 2006 71
CMU SCS
Wavelets
• Many wavelet basis:
– Haar
– Daubechies (-4, -6, -20)
– Gabor
– ...
MLD school 06 Copyright: C. Faloutsos, 2006 72
CMU SCS
Gabor Function
We can extend the function to generate
Gabor filters by rotating and dilating
13
MLD school 06 Copyright: C. Faloutsos, 2006 73
CMU SCS
Wavelets:
• Extremely useful
• Excellent compression / feature extraction,
for natural images
• fast to compute ( O(N) )
MLD school 06 Copyright: C. Faloutsos, 2006 74
CMU SCS
Crush intro to Haar wavelets
• The simplest to code, explain and
understand
MLD school 06 Copyright: C. Faloutsos, 2006 75
CMU SCS
Wavelets - DWT
• Similarly, DFT suffers on short-duration
waves (eg., baritone, silence, soprano)
time
value
MLD school 06 Copyright: C. Faloutsos, 2006 76
CMU SCS
Haar Wavelets
• subtract sum of left half from right half
• repeat recursively for quarters, eight-ths, ...
MLD school 06 Copyright: C. Faloutsos, 2006 77
CMU SCS
Wavelets - construction
x0 x1 x2 x3 x4 x5 x6 x7
adv
MLD school 06 Copyright: C. Faloutsos, 2006 78
CMU SCS
Wavelets - construction
x0 x1 x2 x3 x4 x5 x6 x7
s1,0
+-
d1,0 s1,1d1,1 .......level 1
adv
14
MLD school 06 Copyright: C. Faloutsos, 2006 79
CMU SCS
Wavelets - construction
d2,0
x0 x1 x2 x3 x4 x5 x6 x7
s1,0
+-
d1,0 s1,1d1,1 .......
s2,0level 2
adv
MLD school 06 Copyright: C. Faloutsos, 2006 80
CMU SCS
Wavelets - construction
d2,0
x0 x1 x2 x3 x4 x5 x6 x7
s1,0
+-
d1,0 s1,1d1,1 .......
s2,0
etc ...
adv
MLD school 06 Copyright: C. Faloutsos, 2006 81
CMU SCS
Wavelets - construction
d2,0
x0 x1 x2 x3 x4 x5 x6 x7
s1,0
+-
d1,0 s1,1d1,1 .......
s2,0
Q: map each coefficient
on the time-freq. plane
t
f
adv
MLD school 06 Copyright: C. Faloutsos, 2006 82
CMU SCS
Wavelets - construction
d2,0
x0 x1 x2 x3 x4 x5 x6 x7
s1,0
+-
d1,0 s1,1d1,1 .......
s2,0
Q: map each coefficient
on the time-freq. plane
t
f
adv
MLD school 06 Copyright: C. Faloutsos, 2006 83
CMU SCS
Haar wavelets - code
#!/usr/bin/perl5
# expects a file with numbers
# and prints the dwt transform
# The number of time-ticks should be a power of 2
# USAGE
# haar.pl <fname>
my @vals=();
my @smooth; # the smooth component of the signal
my @diff; # the high-freq. component
# collect the values into the array @val
while(<>){
@vals = ( @vals , split );
}
my $len = scalar(@vals);
my $half = int($len/2);
while($half >= 1 ){
for(my $i=0; $i< $half; $i++){
$diff [$i] = ($vals[2*$i] - $vals[2*$i + 1] )/ sqrt(2);
print "\t", $diff[$i];
$smooth [$i] = ($vals[2*$i] + $vals[2*$i + 1] )/ sqrt(2);
}
print "\n";
@vals = @smooth;
$half = int($half/2);
}
print "\t", $vals[0], "\n" ; # the final, smooth component
adv
MLD school 06 Copyright: C. Faloutsos, 2006 84
CMU SCS
Images - shapes
• (A1: turning angle)
• A2: wavelets
• A3: morphology: dilations/erosions
• ...
15
MLD school 06 Copyright: C. Faloutsos, 2006 85
CMU SCS
Other shape features
• Morphology (dilations, erosions, openings,
closings) [Korn+, VLDB96]
shape (B/W) “structuring
element”
R=1
MLD school 06 Copyright: C. Faloutsos, 2006 86
CMU SCS
Other shape features
• Morphology (dilations, erosions, openings,
closings) [Korn+, VLDB96]
shape “structuring
element”
R=0.5
R=1
R=2
MLD school 06 Copyright: C. Faloutsos, 2006 87
CMU SCS
Other shape features
• Morphology (dilations, erosions, openings,
closings) [Korn+, VLDB96]
shape “structuring
element”
R=0.5
R=1
R=2
MLD school 06 Copyright: C. Faloutsos, 2006 88
CMU SCS
Morphology: closing
• fill in small gaps
• very similar to ‘alpha contours’
MLD school 06 Copyright: C. Faloutsos, 2006 89
CMU SCS
Morphology: closing
• fill in small gaps
‘closing’,
with R=1MLD school 06 Copyright: C. Faloutsos, 2006 90
CMU SCS
Morphology: opening
• ‘closing’, for the complement =
• trim small extremities
16
MLD school 06 Copyright: C. Faloutsos, 2006 91
CMU SCS
Morphology: opening
‘opening’
with R=1
• ‘closing’, for the complement =
• trim small extremities
MLD school 06 Copyright: C. Faloutsos, 2006 92
CMU SCS
Morphology
• Closing: fills in gaps
• Opening: trims extremities
• All wrt a structuring element:
MLD school 06 Copyright: C. Faloutsos, 2006 93
CMU SCS
Morphology
• Features: areas of openings (R=1, 2, …) and
closings
MLD school 06 Copyright: C. Faloutsos, 2006 94
CMU SCS
Morphology
• resulting areas: ‘pattern spectrum’
– translation ( and rotation) independent
• As described: on b/w images
– can be extended to grayscale ones (eg., by
thresholding)
MLD school 06 Copyright: C. Faloutsos, 2006 95
CMU SCS
Conclusions
Features for color, shape, texture
• Shape: wavelets; math. morphology
• texture: wavelets
we didn’t elaborate:
• color: color histograms; avg R/G/B
• and many more
MLD school 06 Copyright: C. Faloutsos, 2006 96
CMU SCS
References
• Faloutsos, C., R. Barber, et al. (July 1994). “Efficient and
Effective Querying by Image Content.” J. of Intelligent
Information Systems 3(3/4): 231-262.
• Faloutsos, C. and K.-I. D. Lin (May 1995). FastMap: A
Fast Algorithm for Indexing, Data-Mining and
Visualization of Traditional and Multimedia Datasets.
Proc. of ACM-SIGMOD, San Jose, CA.
• Faloutsos, C., M. Ranganathan, et al. (May 25-27, 1994).
Fast Subsequence Matching in Time-Series Databases.
Proc. ACM SIGMOD, Minneapolis, MN.
17
MLD school 06 Copyright: C. Faloutsos, 2006 97
CMU SCS
References
• Christos Faloutsos, Searching Multimedia Databases by
Content, Kluwer 1996
MLD school 06 Copyright: C. Faloutsos, 2006 98
CMU SCS
References
• Flickner, M., H. Sawhney, et al. (Sept. 1995). “Query by
Image and Video Content: The QBIC System.” IEEE
Computer 28(9): 23-32.
• Goldin, D. Q. and P. C. Kanellakis (Sept. 19-22, 1995). On
Similarity Queries for Time-Series Data: Constraint
Specification and Implementation (CP95), Cassis, France.
MLD school 06 Copyright: C. Faloutsos, 2006 99
CMU SCS
References
• Charles E. Jacobs, Adam Finkelstein, and David H. Salesin.
Fast Multiresolution Image Querying SIGGRAPH '95,
pages 277-286. ACM, New York, 1995.
• Flip Korn, Nikolaos Sidiropoulos, Christos Faloutsos, Eliot
Siegel, Zenon Protopapas: Fast Nearest Neighbor Search in
Medical Image Databases. VLDB 1996: 215-226
MLD school 06 Copyright: C. Faloutsos, 2006 100
CMU SCS
Resources - software and urls
• http://www.dsptutor.freeuk.com/jsanalyser/
FFTSpectrumAnalyser.html : Nice java
applets for FFT
• http://www.relisoft.com/freeware/freq.html
voice frequency analyzer (needs
microphone)
MLD school 06 Copyright: C. Faloutsos, 2006 101
CMU SCS
Resources: software and urls
• xwpl: open source wavelet package from
Yale, with excellent GUI
• http://monet.me.ic.ac.uk/people/gavin/java
/waveletDemos.html : wavelets and
scalograms
MLD school 06 Copyright: C. Faloutsos, 2006 102
CMU SCS
Books
• William H. Press, Saul A. Teukolsky, William T.
Vetterling and Brian P. Flannery: Numerical Recipes in C,
Cambridge University Press, 1992, 2nd Edition. (Great
description, intuition and code for DFT, DWT)
• C. Faloutsos: Searching Multimedia Databases by Content,
Kluwer Academic Press, 1996 (introduction to DFT,
DWT)
18
MLD school 06 Copyright: C. Faloutsos, 2006 103
CMU SCS
Outline
• Problem definition and motivation
• Indexing and feature extraction
• Features for images (DWT, morphology,
etc)
• Tools and case studies: PCA, ICA, Random
Walks
• Conclusions
MLD school 06 Copyright: C. Faloutsos, 2006 104
CMU SCS
ICA
• Independent Component Analysis
– better than PCA/SVD
– also known as ‘blind source separation’
– (the `cocktail discussion’ problem)
MLD school 06 Copyright: C. Faloutsos, 2006 105
CMU SCS
Intuition behind ICA:
perimeter
area
MLD school 06 Copyright: C. Faloutsos, 2006 106
CMU SCS
PCAarea
perimeter
Intuition behind ICA:
MLD school 06 Copyright: C. Faloutsos, 2006 107
CMU SCS
ICAPCA
area
perimeter
Intuition behind ICA:
MLD school 06 Copyright: C. Faloutsos, 2006 108
CMU SCS
Intuition behind ICA:
19
MLD school 06 Copyright: C. Faloutsos, 2006 109
CMU SCS
PCA finds the hyperplane.
Intuition behind ICA:
MLD school 06 Copyright: C. Faloutsos, 2006 110
CMU SCS
PCA finds the hyperplane. ICA finds the correct patterns.
Dimensionality reduction
Intuition behind ICA:
MLD school 06 Copyright: C. Faloutsos, 2006 111
CMU SCS
ICA in action
• stock prices - find groups / outliers!
MLD school 06 Copyright: C. Faloutsos, 2006 112
CMU SCS
Eg.: Hidden variables in stock prices
Alcoa
American
Express
Boeing
Caterpillar
Citi Group
(Q) What patterns do you see?
…
DJIA (29 companies)Unimodal data
MLD school 06 Copyright: C. Faloutsos, 2006 113
CMU SCS
Eg.: Hidden variables in stock prices
Alcoa
American Express
Boeing
Caterpillar
Citi Group
Discovery non-obvious hidden variables.(How to do this automatically?)
MLD school 06 Copyright: C. Faloutsos, 2006 114
CMU SCS
Hidden variablesDow Jones Industrial Average
Alcoa
American
Express
Boeing
Caterpillar
Goal:
Find meaningful
hidden variables
Time tick (week)
Weekly DJIA closing prices (01/02/1990-08/05/2002)
n=660 data points, m=29 companies
Data point
adv
20
MLD school 06 Copyright: C. Faloutsos, 2006 115
CMU SCS
(A1) How did stock prices change?
AA1, …, XOM1
…
…
AAn, …, XOMn
H11, H12, …, H1m
…
…
Hn1, Hn2, …, Hnm
=
B11, B12, …, B1m
…
Bm1, Bm2, …, Bmm? ?
Time tickHidden variable
Time tick
Math
29
n=660
MLD school 06 Copyright: C. Faloutsos, 2006 116
CMU SCS
Hidden variables by AutoSplit
Hidden v#1 (meaning??)
Caterpillar Intel
Hidden v#2 (meaning??)
0.940.63 0.03
0.64B1,CAT
B1,INTC B2,CAT
B2,INTC
More…
MLD school 06 Copyright: C. Faloutsos, 2006 117
CMU SCS
Hidden variables by AutoSplit
“General trend” “Internet bubble”
0.940.63 0.03
0.64B1,CAT
B1,INTC B2,CAT
B2,INTC
More…
Caterpillar Intel
MLD school 06 Copyright: C. Faloutsos, 2006 118
CMU SCS
Making the most of
ICA/AutoSplit
• Pattern discovery (hidden variables)
• Clusters (tech vs non-tech stocks)
• Outlier detection
MLD school 06 Copyright: C. Faloutsos, 2006 119
CMU SCS
Companies related to hidden
variable 1
0.658768Hewlett-Packard0.900317Du Pont
0.647774Home Depot0.903858Coca Cola
0.638010Intel0.906542MMM
0.624570WalMart0.911120Boeing
0.021885AT&T0.938512Caterpillar
LowestHighest
B1,j
Hidden variable 1 : “General trend”
MLD school 06 Copyright: C. Faloutsos, 2006 120
CMU SCS
Outlier detection
AT&T
UnitedTechnologies
Walmart
ExxonMobil
“General trend”
Outlier
21
MLD school 06 Copyright: C. Faloutsos, 2006 121
CMU SCS
Conclusions for ICA
• Better than PCA
• Actually, uses PCA as a first step!
MLD school 06 Copyright: C. Faloutsos, 2006 122
CMU SCS
References
• Fukunaga, K. (1990). Introduction to Statistical
Pattern Recognition, Academic Press.
• Jolliffe, I. T. (1986). Principal Component
Analysis, Springer Verlag.
• Aapo Hyvarinen, Juha Karhunen, and Erkki Oja
Independent Component Analysis, John Wiley &
Sons, 2001.
MLD school 06 Copyright: C. Faloutsos, 2006 123
CMU SCS
References
• Jia-Yu Pan, Hiroyuki Kitagawa, Christos
Faloutsos, and Masafumi Hamamoto. AutoSplit:
Fast and Scalable Discovery of Hidden Variables
in Stream and Multimedia Databases. PAKDD
2004
MLD school 06 Copyright: C. Faloutsos, 2006 124
CMU SCS
Outline
• ...
• Tools and case studies: PCA, ICA, Random
Walks
– ICA; case study: visual vocabulary (ViVo)
– Random Walks
• Conclusions
MLD school 06 Copyright: C. Faloutsos, 2006 125
CMU SCS
ViVo: cat retina mining
• with Ambuj Singh, Mark Verardo, Vebjorn
Ljosa, Arnab Bhattacharya (UCSB)
• Jia-Yu Tim Pan, HJ Yang (CMU)
MLD school 06 Copyright: C. Faloutsos, 2006 126
CMU SCS
Retina, its image, and the detachment
• retina
Layers of tissues
stained by 3
antibodies
(R,G,B)
22
MLD school 06 Copyright: C. Faloutsos, 2006 127
CMU SCS
Computer Scientist’s View of
Retinal Detachment
normal detachment 7 days after
MLD school 06 Copyright: C. Faloutsos, 2006 128
CMU SCS
Detachment Development
Normal1 day after detachment
3 days after detachment
7 days after detachment
28 days after detachment
3 months after detachment
MLD school 06 Copyright: C. Faloutsos, 2006 129
CMU SCS
Data and Problem
• (Problem) What happens in retina after
detachment?
– What tissues (regions) are involved?
– How do they change over time?
• How will a program convey this info?
• More than classification
“we want to learn what classifier learned”
MLD school 06 Copyright: C. Faloutsos, 2006 130
CMU SCS
Visual vocabulary?news:
president,
minister,
economic
sports:
baseball,
score,
penalty
MLD school 06 Copyright: C. Faloutsos, 2006 131
CMU SCS
Visual Vocabulary (ViVo)
generation
Step 1:
Tile image
Step 2:
Extract tile
features
Step 3:
ViVo
generation
Visual
vocabulary
V1
V2
Feature 1
Fea
ture
2
8x12 tiles
MLD school 06 Copyright: C. Faloutsos, 2006 132
CMU SCS
Biological interpretation
V11
V8
V10
V1
ID
Co-occurring processes: Müller cellhypertrophy and rod opsin redistribution
Redistribution of rod opsin into cellbodies of rod photoreceptors
Healthy outer segments of rod
photoreceptors
GFAP in inner retina (Müller cells)
Description ConditionViVo
Detached
Detached
Healthy
Healthy
23
MLD school 06 Copyright: C. Faloutsos, 2006 133
CMU SCS
Which tissue is significant on 7-day?
MLD school 06 Copyright: C. Faloutsos, 2006 134
CMU SCS
Automatic ViVo-annotation of
images
• A tile represents a ViVo vk
if the largest coefficient of
the tile is along the kth basis
vector
• A ViVo vk represents a
class ci if the majority of its
tiles are in that class
• For each image, the
representative ViVos for the
class are automatically
highlighted
MLD school 06 Copyright: C. Faloutsos, 2006 135
CMU SCS
Conclusion
• ICA can help us find ``good’’ hidden
variables (= visual vocabulary words)
MLD school 06 Copyright: C. Faloutsos, 2006 136
CMU SCS
Outline
• ...
• Tools and case studies: PCA, ICA, Random
Walks
– ICA
– image captioning - Random Walks
• Conclusions
MLD school 06 Copyright: C. Faloutsos, 2006 137
CMU SCS
Image captioning:
correlation between images and
terms
“sea”, “sun”, “sky”, “water”
“cat”, “forest”, “grass”, “tiger”
“?”, “?”, “?”, “?”
MLD school 06 Copyright: C. Faloutsos, 2006 138
CMU SCS
Idea
• each modality into a set of nodes
• (could have many more modalities: audio,
motion, etc etc)
• random walk, on the resulting m-partite
graph
24
MLD school 06 Copyright: C. Faloutsos, 2006 139
CMU SCS
Image captioning: extract regions
“sea”, “sun”, “sky”, “water”
“cat”, “forest”, “grass”, “tiger”
“?”, “?”, “?”, “?”
MLD school 06 Copyright: C. Faloutsos, 2006 140
CMU SCS
Mixed-Media Graph
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
From training images Image to caption
region
image
term
Object-Attribute-Value(OAV) links
MLD school 06 Copyright: C. Faloutsos, 2006 141
CMU SCS
Mixed-Media Graph
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
From training images Image to caption
region
image
term
MLD school 06 Copyright: C. Faloutsos, 2006 142
CMU SCS
Mixed-Media GraphNearest Neighbor
(NN) links
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
From training images Image to caption
region
image
term
MLD school 06 Copyright: C. Faloutsos, 2006 143
CMU SCS
Random Walk with Restart (at
t=0)
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
Image to caption
region
image
term
MLD school 06 Copyright: C. Faloutsos, 2006 144
CMU SCS
Random Walk with Restart (at
t=1)
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
Image to caption
region
image
term
25
MLD school 06 Copyright: C. Faloutsos, 2006 145
CMU SCS
Random Walk with Restart (at
t=2)
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
Image to caption
region
image
term
MLD school 06 Copyright: C. Faloutsos, 2006 146
CMU SCS
Random Walk with Restart (at
t=3)
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
Image to caption
region
image
term
MLD school 06 Copyright: C. Faloutsos, 2006 147
CMU SCS
Random Walk with Restart (at
t=0)
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
Image to caption
region
image
term
Blue step: restart at the query node (with probability c)Red step: randomly walk among one link (with prob. 1-c)
Query/Restart node
(1-c)/2 (1-c)/2
c
MLD school 06 Copyright: C. Faloutsos, 2006 148
CMU SCS
Random Walk with Restart (at
t>0)
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
Image to caption
region
image
term
Blue step: restart at the query node (with probability c)Red step: randomly walk among one link (with prob. 1-c)
Query/Restart node
(1-c)/3 (1-c)/3
c(1-c)/3
MLD school 06 Copyright: C. Faloutsos, 2006 149
CMU SCS
Steady state probability of RWR
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
Image to caption
region
image
term Query/Restart node
Dark green: higher probability to be visited
Light green: lower probability to be visited
MLD school 06 Copyright: C. Faloutsos, 2006 150
CMU SCS
Steady state probability of RWR
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
Image to caption
region
image
term Query/Restart node
Dark green: higher probability to be visited
Light green: lower probability to be visited
26
MLD school 06 Copyright: C. Faloutsos, 2006 151
CMU SCS
Compute the steady state
probability
yprobabilitrestart :
matrix transition:
ctorrestart ve :
yprobabilit statesteady :
))1((
)1(1
c
cc
cc
A
v
u
vAIu
vuAu
v
v
vv
vvv
−−−=⇒
+−=
Math
MLD school 06 Copyright: C. Faloutsos, 2006 152
CMU SCS
Putting MMG+RWR to work
• Tasks:
– Image captioning: GCap [Pan+, MDDE 2004]
– ( Multi-modal retrieval: MMSS [Pan+, ICDM
2004] )
MLD school 06 Copyright: C. Faloutsos, 2006 153
CMU SCS
GCap: MMG+RWR for image
captioning
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
Image to caption
region
image
term
Query/Restart nodegrasscat tigerPredicted caption:
MLD school 06 Copyright: C. Faloutsos, 2006 154
CMU SCS
Examples of captioning results
tree, water,
building, sky
lion, grass, cat, manegrass, cat, tiger,
waterOur
caption
sun, water,
tree, sky
mane, cat, lion, grasscat, grass, tiger,
waterTruth
Image
Predicted terms are listed in the order of likeliness.
MLD school 06 Copyright: C. Faloutsos, 2006 155
CMU SCS
Extension: other cross-modal
queries
• e.g., text-to-text
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5 t6 t7 t8
….
….
….
….
MLD school 06 Copyright: C. Faloutsos, 2006 156
CMU SCS
(Extension) Other cross-modal
queries
• For example, the term-to-term correlation
– “Given a term, find other similar terms.”
prototypeTurnBuildingsStreetTracksCar
BoatsStoneSkyArchWaterBridge
HawkNestOwlNightBirdsBranch
54321Term
27
MLD school 06 Copyright: C. Faloutsos, 2006 157
CMU SCS
Extension: group captioning
r1 r2 r3 r4 r5 r6 r7 r8 r9 ….
i1 i2 ij
t1
ri ri+1
itest
….
….
t2 t3 t4 t5
….
….
….
….
MLD school 06 Copyright: C. Faloutsos, 2006 158
CMU SCS
(Extension) Captioning images in
groups
sky, water, tree, sunGroup
caption
sky, sunwater, tree, people,
sky
tree, people, sky,
water
GCap
caption
sun, watersun, clouds, sky,
horizon
sun, water, tree,
skyTruth
Image
MLD school 06 Copyright: C. Faloutsos, 2006 159
CMU SCS
Summary
• GCap = MMG+RWR, for image captioning
– Easy to apply to all kinds of cross-modal data
– Outperforms the best previous image captioning
results
MLD school 06 Copyright: C. Faloutsos, 2006 160
CMU SCS
OVERALL CONCLUSIONS
Powerful tools for image/multimedia mining:
• GEMINI + R-trees for similarity search
• Feature extraction with
– Wavelets,
– PCA, ICA
• Cross-modal mining / auto-captioning:
– graph-based methods + Random Walks
MLD school 06 Copyright: C. Faloutsos, 2006 161
CMU SCS
christos <at> cs.cmu.edu
www.cs.cmu.edu/~christos