Inverted Matrix Efficient Discovery of Frequent Items in






















- Slides: 22
Inverted Matrix: Efficient Discovery of Frequent Items in Large Datasets in the Context of Interactive Mining Mohammad El-Hajj, Osmar R. Zaiane The Ninth ACM SIGKDD International Conference on Knowledge Discovery and Data Mining, 2003 2021/2/22 報告人: 吳建良 1
Abstract n Two problems of association rule mining algorithms n n n High memory dependency Repetitive and interactive discovery process Disk-based association rule mining algorithm n n n New database layout Inverted Matrix Co-Occurrence Frequent-Item tree (COFI tree) Simple and non-recursive mining algorithm 2
Superfluous Processing n n n If support threshold changes, the mining algorithms must re-scan database Frequent and non-frequent items more than once generate huge amount of useless work Previous accumulated knowledge is not taken into account 3
Transaction Layout n Horizontal: support threshold is 4 4
Transaction Layout (cont. ) n Vertical 5
Advantage vs. Shortcoming n Horizontal Layout n Advantage n n Shortcoming n n Combine all items in one transaction together No index on items superfluous processing Vertical Layout n Advantage n n An index on the items, reduce the database size Shortcoming n Expensive candidate generation phase intersect 6
Inverted Matrix Construction T# T 1 Items D B C E A T 2 G H C E A T 3 D B C E A (10, 2 ) (5, 1) (4, 1) (6, 2) T 4 F J G H A T 5 I B C E A T 6 K I C E A T 7 I G H E A T 8 O K L M N (13, 2) (8, 2) (9, 2) (15, 1) (15, 2) (12, 2 ) (10, 1 ) (11, 1 ) ψ) (ψ, (9, 1) (18, 8 ) (11, 2 )(15, 4 ) (16, 5 ) (14, 2) T 9 Q R O L A (15, 3 ) (14, 1) T 10 P N B A (16, 2) (18, 4) (16, 1) (16, 3) (17, 1) (17, 2) ) (17, 3) (18, 1) (18, 2) (18, 3) (ψ, ψ) M (13, 3 ) (14, 3 ) (17, 6 )(16, 4 (18, 9 ) (17, 4 ) (18, 5 ) (ψ, ψ) (17, 5 ) (18, 6 ) (ψ, ψ) (18, 7 ) (ψ, ψ) 7 (ψ, ψ)
COFI-Tree Characteristic n Similar to conditional FP-tree n n Header table, horizontal pointers, prefix tree, and bi-directional vertical links Node n n Item label, frequency counter, participation counter Different n Contain only nodes that are more frequent or as frequent as root 8
COFI-Tree Construction n n Build independent relatively small trees for each frequent item Start from the least frequent item I, COFI-tree for I is built by following the chain of pointers in the Inverted Matrix 9
support threshold = 3 (15, 3) (16, 5) (13, 3) (14, 3) (17, 6) (16, 4) (17, 5) (18, 6) (18, 7) (ψ, ψ) COFI-tree of frequent item I I: 3: 0 I: 2: 0 I: 1: 0 G H B: 1: 0 B C: 1: 0 C E A E: 1: 0 A: 1: 0 C: 1: 0 E: 1: 0 A: 1: 0 G: 1: 0 H: 1: 0 E: 1: 0 A: 1: 0 10
support threshold = 3 (14, 1) (14, 2) (14, 3) (16, 2) (18, 4) (17, 6) (17, 2) (18, 2) (ψ, ψ) (18, 7) (ψ, ψ) COFI-tree of frequent item G G: 3: 0 H C: 1: 0 C E A E: 1: 0 A: 1: 0 11
COFI-tree of frequent item H COFI-tree of frequent item C H: 3: 0 C: 5: 0 C: 1: 0 C E A: 1: 0 E: 1: 0 A E: 5: 0 A: 1: 0 COFI-tree of frequent item B COFI-tree of frequent item E B: 4: 0 E: 6: 0 C: 3: 0 C E A A: 1: 0 A A: 6: 0 E: 3: 0 A: 3: 0 12
Mining COFI-Tree n n n Mine each tree separately when it is built Mine branch by branch, starting with the node of the most frequent item Go upward to identify candidate pattern and generate all sub-patterns containing root item Update the frequencies of patterns in the candidate list Discard the tree as soon as mined 13
Mining COFI-Tree (cont. ) n In the branch: n n n Frequency of pattern = (the frequency of first item)- (participation value of the same item) Participation values for all node in this branch are added by the frequency of pattern Example: support threshold =2 Ordered frequent item: F: 3, D: 3, E: 4, C: 8, B: 8, A: 9 14
COFI-Tree for item F F: 3: 0 B B: 3: 0 COFI-Tree for item D C A Item B Frequency of pattern BF=3 -0=3 Participation values are added by frequency of pattern BF Candidate list: BF: 3: 3 B B: 3: 3 Item A D: 3: 0 Frequency of pattern ACD=1 -0=1 Add participation values C: 3: 0 Candidate list: BF: 3, ACD: 1, AD: 1, CD: 1 A: 1: 0 D: 3: 1 C: 3: 1 D: 3: 3 C A C: 3: 3 A: 1: 1 Item C Frequency of pattern CD=3 -1=2 Add participation values A: 1: 1 Candidate list: BF: 3, ACD: 1, AD: 1, CD: 3 15
COFI-Tree for item E E: 4: 0 A A Candidate list: BF: 3, ACD: 1, AD: 1, CD: 3 AE: 4 C: 6: 0 B: 5: 0 E: 4: 4 Frequency of pattern AE=4 -0=4 Add participation values COFI-Tree for item C B Item A A: 1: 0 A: 4: 0 Item A C: 6: 4 Frequency of pattern ABC=4 -0=4 Add participation values B: 5: 4 Candidate list: BF: 3, ACD: 1, AD: 1, CD: 3 AE: 4, ABC: 4, AC: 4, BC: 4 A: 1: 0 A: 4: 4 Item A Item B C: 6: 5 Frequency of pattern BC=5 -4=1 Add participation values Candidate list: BF: 3, ACD: 1, AD: 1, CD: 3 AE: 4, ABC: 4, AC: 5, BC: 5 A: 4: 4 B: 5: 4 A: 4: 4 A: 1: 1 Frequency of pattern AC =1 -0=1 Add participation values Candidate list: BF: 3, ACD: 1, AD: 1, CD: 3 AE: 4, ABC: 4, AC: 5, BC: 416
C: 6: 6 B: 5: 5 B A A: 4: 4 COFI-Tree for item B A A: 1: 1 Item A B: 4: 0 Frequency of pattern AB=4 -0=4 Add participation values A: 4: 0 Candidate list: BF: 3, ACD: 1, AD: 1, CD: 3 AE: 4, ABC: 4, AC: 5, BC: 5 AB: 4: 4 A A: 4: 4 Remove non-frequent patterns (frequency <2) Result: AB: 4, AC: 5, AE: 4, BC: 5, BF: 3, CD: 3, ABC: 4 17
Experiment(1) n Different transaction size n n Support threshold = 0. 01% Average transaction length: 24 items 1 M transaction database: 10, 000 unique items 5 M~25 M transaction database: 100, 000 unique items 18
Experiment(2) n Different support level n n Build Inverted Matrix: 763 seconds Four cases: n n n FP-tree: 15607 s Inverted Matrix: 4540+763=5303 s Build-once-mine-many 19
20
21
22






















