- 82 Views
- Uploaded on
- Presentation posted in: General

Efficiently Evaluating Order Preserving Similarity Queries over Historical Market-Basket Data

Download Policy: Content on the Website is provided to you AS IS for your information and personal use and may not be sold / licensed / shared on other websites without getting consent from its author.While downloading, if for some reason you are not able to download a presentation, the publisher may have deleted the file from their server.

- - - - - - - - - - - - - - - - - - - - - - - - - - E N D - - - - - - - - - - - - - - - - - - - - - - - - - -

Efficiently Evaluating Order Preserving Similarity Queries over Historical Market-Basket Data

Reza Sherkat and Davood Rafiei

Department of Computing Science

University of Alberta

Canada

Travel assistance provided by the Mary Louise Imrie Graduate Student Award

ICDE06

- Introduction
- Histories and Time-series
- Similarity model for histories

- Problem Definition
- Proposed Approach
- Results Highlight
- Conclusions

ICDE06

- Querying multiple snapshots of data
- Temporal selection, projection, and join queries

- Finding similar time-series
- Finding companies having similar stocks

- Is it possible to define a notion of similarity for objects based on the similarity of their histories?

ICDE06

- the history of a web-page

: bag of word

History: A sequence of time-stamped observations

- Time-series: observations are real-values
- Observations can be more general

the history of a patient

ICDE06

History for 3 patients

- Similarity of two histories depends on:
- Pair-wise similarity of their observations

ICDE06

History for 3 patients

- Similarity of two histories depends on:
- Pair-wise similarity of their observations

- The order that similar observations are recorded
- Constraints on time-stamps of observations

ICDE06

Given a history as a query:

- Evaluate k-NN and Range queries efficiently.
- For each history in the result, find its common signature with the query - where the similarity comes from?

ICDE06

Alignment of histories:

- An approach to line-up subsequences of two histories
- Denoted by a sequence of matches:
- is an observation in A (B) or a gap ( ).
- is the score of a match.
- Alignment score measures the quality of an alignment.

ICDE06

The best alignment of two histories:

Alignment score can be the sum of the score of matches in the alignment.

ICDE06

Alignment score can be the sum of the score of matches in the alignment.

The best alignment of two histories:

What is the best alignment of length 3?

ICDE06

Alignment score can be the sum of the score of matches in the alignment.

The best alignment of two histories:

What is the best alignment of length 3?

If the match could not be considered, what would be the best alignment of length 2?

ICDE06

- The number of matches in the alignment.
- l-alignment: alignment with l matches

- The r-neighborhood constraint
- For each match

- r ,l : parameters of the similarity query.

ICDE06

p(A)

p(B)

s(A)

s(B)

: optimal alignment of p(A) and p(B)

: optimal alignment of s(A) and s(B)

: optimal alignment of A and B

: concatenation operator

The principle of optimality holds if:

ICDE06

b

,

,

b

,

b

,

,

b

K

K

+

1

1

j

j

n

- Optimal l-alignment of suffixes can formed by:
- Concatenating with optimal (l-1)-alignment of suffixes

- Matching with gap, and considering l-alignment of suffixes

- Matching with gap, and considering l-alignment of suffixes

ICDE06

- can be used to find common signature of histories:
- A sequence of observations that appear in the same order in
- two histories.
- Generalizes the notion of longest common subsequence.

: the score of optimal l-alignment of two histories.

ICDE06

- Straightforward (not practical) approach: naïve scan
- Indexing techniques are proposed for metric spaces,
but is not metric:

- when the distance between observations is not metric.
- when an r-neighberhood constraint is specified.

- We propose upper bounds to prune history search space.

ICDE06

Intuition: The score of an optimal relaxed l-alignment is not less than the score of optimal l-alignment.

- For each observation, find an optimal match.
- Aggregate the scores for top l optimal matches to find an upper bound for .

This upper bound can prune some extra computations,

but still all histories will be accessed to evaluate a query.

ICDE06

This upper bound can be evaluated efficiently by exploiting an inverted index if is Cosine or Extended Jaccard Coefficient.

- Intuitions:
- Observations are sparse in real life applications.
- The score of an optimal relaxed match is not less
- than the score of an optimal match.
- The score of an optimal relaxed alignment is not
- less than the score of optimal relaxed l-alignment.

ICDE06

- Experiments performed on AMD/XP 2600 512 Mb RAM
- Datasets:
- DBLP
- Synth1: Our synthetic data
- Synth2: Modified IBM synthetic data generator

- Investigated:
- Effectiveness of similarity measure
- Efficiency of our approach
- Pruning power, Running time, Saleability

ICDE06

ICDE06

…

…

…

…

: Poisson distribution

V(i+1): bit string following V(i)

in a pre-determined order

[Cho et al. VLDB 2000]

V(1)

V( i+1 )

V( n )

V( i )

- Synth2 dataset contains:
- 20,000 histories
- for each history is selected randomly from {1,…,10}
- Length of histories: {32,…,64}

observation: document modeled as bit string

First observation: randomly selected

…

…

ICDE06

Mean deviation of from for k-NN queries:

* For 2,000 randomly generated queries

ICDE06

Fraction of database examined

0 20 40 60 80 100

1 10 100 1024

No. of neighbours in k-NN query (LOG scale)

ICDE06

Time (msec)

0 100 200 300 400 500 600

1 10 100 1024

Dataset: Synth2, 8,000 Histories, 1,000 items

No. of neighbours in k-NN query (LOG scale)

ICDE06

Time (msec)

8,000 16,000 32,000 64,000

No. of histories in the collection

ICDE06

Time (msec)

256 512 1,024 2,048 4,096 8,092

No. of items (LOG scale)

ICDE06

- Introduced a domain-independent framework to formulate and evaluate similarity queries over historical data.
- Generalized few concepts, including edit distance and longest common subsequence to histories.
- Developed upper bounds to efficiently evaluate queries. One of our upper bounds can directly take advantage of an index even though it is not metric.
- Our experiments confirm the effectiveness and efficiency of our approach.

ICDE06

Thank you for your attention!

ICDE06

- Detecting, representing, querying histories
- [Chawathe 1998], [Chien 2001]

- Similarity-based sequence matching
- [Altschul 1990], [Pearson 1990], [Bieganski 1994]

- Finding similar sequence of events
- [Wang 2003]

- Finding similar time series
- [Agrawal 1995], [Rafiei 1997], [Keogh 2002], [Vlachos 2002, 2003], ...

ICDE06