Discovery of Meaningful Rules in Time Series SIGKDD2015

Preview:

Citation preview

Discovery of Meaningful Rules in Time Series

SIGKDD2015

What is rule

• 静夜思• 唐 李白• 床前明月光,• 疑是地上霜。• 举头望明月,• 低头思故乡。

• 秋浦歌• 唐 李白• 炉火照天地,• 红星乱紫烟。• 赧郎明月夜,• 歌曲动寒川。

明 -> 月

The Raven

• A poem by Edgar Allan Poe

“Once upon a midnight dreary, while I pondered weak and …”

chamber( 房间 ) → door

chamber: antecedent

door: consequent

Rule in Time Series

• A major difference between text and time series is that the latter does not have a natural segmentation

• onceuponamidnightdrearywhileIponderedweak....

• qncexauponwamidmightmtdreerydwgileuIpponderediweek...

• dist(“chamber”, substring) ≤ t → door

• For example: t = 2 chanbet -> door

About lag

The consequent may not immediately followed the antecedent.

chamberdoor, chamberzdoor, chamberxydoor

So we need to define a parameter, maxlag, which is the maximum number of characters between the the antecedent and the consequent

Example:if maxlag = 2,the above predictions is valid

The formal definition of rule in Time Series

“If we see a substring of length ρ that is within distance of the word chamber, then we fire the rule and expect to see a similar substring to word door, within a learned distance , in the next maxlag time steps.”

Rule is like this

Time Series Motif

The method is based on Time Series Motif, which has been extensively studied in many literature

Definitions

Definitions

DATA DISCRETIZATION

Find the minimum value and maximum value, then we set bin boundaries that are uniformly sized between min and max. The resulting bin width is then: (max - min) / cardinality

MDL

• MDL is used as a scoring function, which is novel in this paper

• Why MDL? Why not ED?

• The Euclidean distance does not allow us to compare the quality of consequents with different lengths.

• The Euclidean distance between two subsequences of length ρ can actually decrease when we expand to length ρ + 1 due to the (re)normalization of the data. So not only is the effect of length not linear, it is not even monotonic.

What is MDL• MDL or Minimum Description Length is used to

score a rule based on how many bits that can be saved.

A hypothesis (green/bold) can be used to score subsequences by subtracting it from them (producing the small integers shown top) and encoding the difference vector with Huffman encoding

Here the left sequence requires 57 bits, whereas the right sequence requires 84.

After encoding, how many bits it cost to save the sequence:

RULE DISCOVERY ALGORITHM

1. A scoring function

2. A search algorithm which repeatedly invokes this scoring function while searching for high quality rules

Rule Scoring

• For clarity, we begin to consider maxlag is 0

Motif-Based Rule Searching

• Efficient algorithms for discovering the top K motifs in a time series are well-known.In this paper, we use MK algorithm

EXPERIMENT-Zebra finch

EXPERIMENT-Energy Disaggregation

Clothes Washer Clothes Dryer

Conclusion

1. Applid MDL to score time series rules

2. Rule representation is expressive enough to allow rules with different length antecedents/consequents/lags/firing thresholds

Future work

1. On some datasets, Dynamic Time Warping, in single or multi-dimensional cases, may be more robust than the Euclidean distance, but to massive datasets remains an issue.

2. It may be possible to generalize the rule representation to allow more expressive logical connectives

3. There are currently no standard benchmarks for time series rule discovery.

Recommended