Presentation on theme: "Advance Database Systems and Applications COMP 6521"— Presentation transcript:
1Advance Database Systems and Applications COMP 6521 Professor: Dr. Gosta Grahne Lab Instructor: ashkan azarnik Group 15 Aditya Dewal Mohammad Iftekharul Hoque Saleh Ahmed
2PROJECT 1Develop a program which sort numbers in ascending order using 2 Phase Multiway Merge Sort(2PMMS) with limitation of 5MB of virtual memory.External sorting is required when the data being sorted do not fit into the main memory of a computing device and instead they must reside in slower external memory (usually hard drive).
3Our approached to solve the problem External sorting typically uses a sort-merge technique.In the sorting phase, chunks of data small enough to fit in main memory are read, sorted in ascending order using quick sort algorithm and written out to a temporary file.In the merge phase, the sorted temporary files are combined using 2 phase multiway merge sort into a single larger file.
4Challenges Which algorithm to choose ? Quicksort is one of the fastest and simplest sorting algorithm because its inner loop can be efficiently implemented on most architectures.Efficient average case compared to other sort algorithms.The complexity of quick sort in the average case is O(n log(n)
5List of Data Structures Primitive Types:Boolean, Integer, LongAbstract Types:Array, StringArrays (Linear Data Structure)Integer Array, Boolean Array, Long ArrayI/O:Scanner, PrintWriter
7ConclusionAfter our buffer size experiments we concluded that for number of data which occupying 2.5mb of memory gives best execution time for us.
8Results from DemoThe execution time to run our program during the demo was 3 minutes.The reason for taking too much timewas the way we were taking our input and writing output in our program.
9Project 2Mining Frequent Itemsets from Secondary Memory Build an application that will compute the frequent itemsets of all sizes (Pairs, Triples, Quadruples, etc.) from a set of transactions based on input support threshold percentage.
10Algorithms Considered AprioriEclatHorizontal Data LayoutVertical Data Layout
11Algorithms Considered AprioriEclatBreadth-First TraversalDepth-First Traversal
12ECLAT Better Execution Time Memory Efficient Explore the unexplored Execution time is better than AprioriMemory EfficientRequire less amount of memory compare to Apriori if itemsets are small in numberDepth-First SearchExplore the unexplored
13ECLAT Algorithm For each item, store a list of transaction ids (tids) TID-list
14 ECLAT Algorithm Determine support of any k-itemset by intersecting tid-lists of two of its (k-1) subsets.3 traversal approaches:top-downbottom-uphybrid
16List of Data Structures ECLAT ImplementationList of Data StructuresPrimitive TypesArrays (Linear Data Struc.)Boolean, Integer, DoubleHash Map (Hash Table)Abstract TypesHash Set (Hash Map)Map, Set, List, Array,Array List (Dynamic Array)StringBit Set (Bit Array)String ArrayTreesSearch Tree
17ECLAT ImplementationOur implementation denotes the set of transactions as a bit set.Intersects rows to determine the support of item sets.The search follows a depth first traversal of a prefix tree as it is shown in Figure 1.
18Divide and Conquer Phase ECLAT ImplementationDivide and Conquer PhaseDivide the file in N partitions.If an item is frequent in one partition we don’t check it again.Merge PhaseSuppose an item is not frequent in any partition but it is frequent globally, it is going to come when we would merge.In the merge part we would run the algorithm again with the infrequent items.
19ECLAT Implementation File size = 10000, Threshold = 2% An item is frequent if it occurs >= 200 timesWe would get intermediate results by checking all the partitions.Merge part we would work with the infrequent items for each partition, and then merge the results to get the final output list of frequent items
20Eclat Execution TimeExecution time of Eclat for Small and Medium datasets:
21Eclat VS AprioriWe have compared the execution time for Apriori and Eclat for Small and Medium datasets and found the following:
22Benefits of Divide and Conquer Program executes for Large files.Gives better performance.