VIETNAM NATIONAL UNIVERSITY HO CHI MINH CITY UNIVERSITY OF TECHNOLOGY FACULTY OF COMPUTER SCIENCE AND ENGINEERING GRADUATION THESIS OPENK : DATA CLEANSING SYSTEM - A CLUSTERING-BASED APPROACH FOR DETECTING DATA ANOMALIES Council: Information System Instructor: Assoc. Dang Tran Khanh Reviewer: Dr. Phan Trong Nhan Student: Nguyen Dinh Khuong - 1752306 Ho Chi Minh City, August 2021 ĐẠI HỌC QUỐC GIA TP.HCM CỘNG HÒA XÃ HỘI CHỦ NGHĨA VIỆT NAM ---------- Độc lập - Tự do - Hạnh phúc TRƯỜNG ĐẠI HỌC BÁCH KHOA KHOA:KH & KT Máy tính NHIỆM VỤ LUẬN ÁN TỐT NGHIỆP BỘ MÔN:KHMT Chú ý: Sinh viên phải dán tờ này vào trang nhất của bản thuyết trình HỌ VÀ TÊN: NGUYỄN ĐÌNH KHƯƠNG MSSV: 1752306 NGÀNH: COMPUTER SCIENCE LỚP: KHM2 1. Đầu đề luận án: OPENK : DATA CLEANSING SYSTEM – CLUSTERING-BASED APPROACH FOR DETECTING DATA ANOMALIES 2.
Nhiệm vụ (yêu cầu về nội dung và số liệu ban đầu): - Learn requirements, analysis, design and implementation of data cleansing system running on web app platform. Research and apply Edit-based similarity algorithms, using knowledge and methodologies from Algorithm Design and Analysis, Database Management System, Clustering Methods, Web development to provide reasonable and optimized approach in detecting and clustering cluster of anomalies data, which will be ready for the next steps. - Reading scientific papers and proposing a solution to prevent inconsistent and duplicate data based on clustering methods. - Researching different related works - others data cleansing systems such as GoogleRefine, BigDansing, NADEEF,.
thereby making reasonable assessments and comparisons for the advantages and disadvantages of the current system. After that, developing further functions performance and system optimization. - Apply K-NN methods (LD, Damerau LD, Hamming), Similarity (Jaro, Jaro-Winkler) methods and Key Collision (Fingerprint, N-gram Fingerprint) for detecting and clustering. - Test and evaluate the proposed system.
Ngày giao nhiệm vụ luận án: 02/02/2021 4. Ngày hoàn thành nhiệm vụ: 26/07/2021 5. Họ tên giảng viên hướng dẫn: Dr. Đặng Trần Khánh Phần hướng dẫn: All thesis Nội dung và yêu cầu LVTN đã được thông qua Bộ môn.
CHỦ NHIỆM BỘ MÔN GIẢNG VIÊN HƯỚNG DẪN CHÍNH (Ký và ghi rõ họ tên) (Ký và ghi rõ họ tên) PGS. Đặng Trần Khánh PHẦN DÀNH CHO KHOA, BỘ MÔN: Người duyệt (chấm sơ bộ): Đơn vị: Ngày bảo vệ: Điểm tổng kết: Nơi lưu trữ luận án: TRƯỜNG ĐẠI HỌC BÁCH KHOA CỘNG HÒA XÃ HỘI CHỦ NGHĨA VIỆT NAM KHOA KH & KT MÁY TÍNH Độc lập - Tự do - Hạnh phúc ---------------------------- Ngày 10 tháng 08 năm 2021 PHIẾU CHẤM BẢO VỆ LVTN (Dành cho người hướng dẫn) 1. Họ và tên SV: Nguyễn Đình Khương MSSV: 1752306 Ngành (chuyên ngành): Khoa học máy tính K 2. Đề tài: OPEN : DATA CLEANSING SYSTEM – A CLUSTERING-BASED APPROACH FOR DETECTING DATA ANOMALIES 3.
Họ tên người hướng dẫn: PGS. Đặng Trần Khánh 4. Tổng quát về bản thuyết minh: Số trang: Số chương: Số bảng số liệu Số hình vẽ: Số tài liệu tham khảo: Phần mềm tính toán: Windows, Python, … Hiện vật (sản phẩm) 5. Tổng quát về các bản vẽ: - Số bản vẽ: Bản A1: Bản A2: Khổ khác: - Số bản vẽ vẽ tay Số bản vẽ trên máy tính: 6.
Những ưu điểm chính của LVTN: Developed a cleansing tool for improving (big) data quality in order to achieve the high utility in businesses. Moreover, the student had finished the following: - Studying Pandas, Numpy, JSON Python library, and other relevent programming tools. - Investigating algorithms for measuring text similarity using different methods. - Studying cleansing and validating data tools such as OpenRefine, Cerberus.
- Reading scientific papers and proposing a solution to prevent inconsistent and duplicate data based on the clustering method. - Build a visualization method for users to have a better view about the collected data. - Build an API-based library for the developer community. Những thiếu sót chính của LVTN: The thesis presentation can be improved.
Đề nghị: Được bảo vệ □ Bổ sung thêm để bảo vệ □ Không được bảo vệ □ 9. 3 câu hỏi SV phải trả lời trước Hội đồng: a. Point out a better functionality of OPENk comparing with the known existing work/systems? 10. Đánh giá chung (bằng chữ: xs/giỏi, khá, TB): Xuất sắc Điểm: 10 /10 Ký tên (ghi rõ họ tên) PGS.
Đặng Trần Khánh TRƯỜNG ĐẠI HỌC BÁCH KHOA CỘNG HÒA XÃ HỘI CHỦ NGHĨA VIỆT NAM KHOA KH & KT MÁY TÍNH Độc lập - Tự do - Hạnh phúc ---------------------------- Ngày 03 tháng 08 năm 2021 PHIẾU CHẤM BẢO VỆ LVTN (Dành cho người phản biện) 1. Họ và tên SV: Nguyễn Đình Khương MSSV: 1752306 Ngành (chuyên ngành): Khoa học Máy tính 2. Đề tài: Openk: Data Cleansing System - A Clustering-based Approach for Detecting Data Anomalies 3. Họ tên người phản biện: TS.
Phan Trọng Nhân 4. Tổng quát về bản thuyết minh: Số trang: Số chương: Số bảng số liệu Số hình vẽ: Số tài liệu tham khảo: Phần mềm tính toán: Hiện vật (sản phẩm) 5. Tổng quát về các bản vẽ: - Số bản vẽ: Bản A1: Bản A2: Khổ khác: - Số bản vẽ vẽ tay Số bản vẽ trên máy tính: 6. Những ưu điểm chính của LVTN: -The student has developed a web application that supports users recognizing data anomalies by a clustering-based approach with some built-in methods.
-The student has employed modern technologies for development such as flask, jinja, pandas, numpy, html, css, javascript, and performed some basic empiriments (loading time, error, running time). -The system can connect to files and cloud-based database management systems. Những thiếu sót chính của LVTN: -The way of identifying data anomalies based on a clustering approach does not really show the anomalies. For example, it shows the two different texts as abnormal.
-The evaluation and comparison are simple and towards time than accuracy. In addition, it does not clearly show how effective the system helps in anomaly detection. -The system is inflexible to add more methods. Moreover, how to choose the parameter values is a problem to a user (e., k parameter, the limitation of records loading from Azure database).
Đề nghị: Được bảo vệ Bổ sung thêm để bảo vệ Không được bảo vệ 9. 3 câu hỏi SV phải trả lời trước Hội đồng: a. Would you please show a use-case in that a user can benefit from your system? b. Any comparison with some related work (e.
Đánh giá chung (bằng chữ: giỏi, khá, TB): Good Điểm: 9/10 Ký tên (ghi rõ họ tên) Phan Trọng Nhân Ho Chi Minh City University of Technology, VNU-HCM Faculty of Computer Science and Engineering Acknowledgements First and foremost we would like to thank my supervisor Dr. Dang Tran Khanh, not only for his academic guidance and assistance, but also for his patience and personal support which made me truly grateful. I would like to guarantee that this research is my own, conducted under the su- pervision and guidance of Dr. Dang Tran Khanh.
The result of my research is legitimate and has not been published in any forms prior to this. All materials used within this researched are collected by myself, by various sources and are appropriately listed in the references section. In addition, within this research, we also used the results of sev- eral other authors and organizations. They have all been aptly referenced.
In any case of plagiarism, we stand by my actions and are to be responsible for it. Ho Chi Minh city University of Technology therefore is not responsible for any copyright infringements conducted within my research. GRADUATION THESIS Page 4/83 Ho Chi Minh City University of Technology, VNU-HCM Faculty of Computer Science and Engineering Abstract At the moment, massive amounts of data are created every second over the inter- net, making the most efficient decisions has become a critical goal. Assume that we had all of the information, but that extracting the valuable knowledge would be extremely difficult.
The following are the reasons for this assumption: data is not always clean or at least correct since data obtained from many sources may be redundant, some of them can be duplicated. These data must be cleaned before they can be utilized for further processing. Any inconsistencies or duplication in the datasets should be detected using a de- tection procedure. Widowing, blocking, and machine learning are among of the methods that are utilized to identify anomalous data.
The goals of this thesis are to offer OpenK , a simple yet efficient data cleansing system based on clustering approaches. In this sce- nario, a cluster will comprise all data that are similarity-based assumptions, is detected by several techniques: Nearest Neighbor (Levenshtein Distance, Damerau-Levenshtein Distance, Hamming Distance), Similarity Measurement (Jaro Similarity, Jaro-Winkler Similarity) and Key Collision (Fingerprints, N-gram Fingerprints). This tool will be evaluated in order to see how the efficiency of it and compare to other tool for better view of assessment. We used airlines dataset from https://assets.
com/production/repositories/5737/datasets and special case study - Real Estate dataset which is crawled from https://batdongsan. OpenK also aids the user in loading and viewing data. Beside that, CRUD procedures, Pagina- tion, Toggle column ON/OFF, Sort column, and Search keywords are being used for analyzing and wrangling input data. Keywords: Data Cleansing, Levenshtein Distance, Jaro-Winkler Similarity, Fin- gerprints, Anomaly detection GRADUATION THESIS Page 5/83 Ho Chi Minh City University of Technology, VNU-HCM Faculty of Computer Science and Engineering Contents 1 Introduction 10 1.2 Data Anomalies Detection .c Damerau-Levenshtein distance .d Jaro Distance - Jaro-Winkler Distance.
23 3 Methodologies And Design 26 GRADUATION THESIS Page 6/83 Ho Chi Minh City University of Technology, VNU-HCM Faculty of Computer Science and Engineering 3.2 Detecting anomaly execution flow .3 Use-case of clustering data site .a Actor determination and following use-case .b Use-case diagram and specification .2 Existing System and Design .1 Technologies and Framework. 40 5 System Evaluation 50 6 Thesis Denouement 54 6.2 Assessment of Thesis Connotation. 55 7 APPENDIX A : USER MANUAL 59 GRADUATION THESIS Page 7/83 Ho Chi Minh City University of Technology, VNU-HCM Faculty of Computer Science and Engineering List of Figures 2.1 Example of applying fingerprint algorithm for name .2 Formula of Hamming distance calculation .3 3-bit binary cube for finding Hamming distance .4 Levenshtein Distance calculation formula .5 Example of Levenshtein distance calculation table.6 Example of Damerau-Levenshtein distance calculation table.7 Formula of Jaro similarity calculation .8 Jaro-Winkler similarity calculation example .9 Comparision of barcode correction using different techniques .1 Overall architecture of OpenK system .2 Data type format converter .3 Data cleansing component illustration .4 Clustering Operations illustration .5 Activity diagram of OpenK system .6 Use case diagram of Data site of OpenK system .7 Use case specification of viewing data .8 Use case specification of paging data .9 Use case specification of searching data keywords .10 Use case specification of sorting data column .11 Use case specification of export data .12 Use case specification of Hiding column data. 34 GRADUATION THESIS Page 8/83 Ho Chi Minh City University of Technology, VNU-HCM Faculty of Computer Science and Engineering 3.13 Use case specification of Manage data cluster .14 Use case specification of cluster data using knn method .15 Use case specification of cluster data using similarity method .16 Use case specification of cluster data using key collision method .17 Overall architecture of BigDansing .18 Overall architecture of NADEEF .1 Relation diagram of OpenK routing system .2 Flow chart diagram of Upload function implementation .3 Flow chart diagram of Data function implementation .4 Class diagram of clustering method .5 Flow of clustering data with KNN class .6 Flow of clustering data with Similarity class .7 Implementation code of clustering data with Fingerprint algorithm .8 Flow of clustering data with Fingerprint algorithm .1 Time performance for loading & visualizing input dataset of OpenK and OpenRefine .2 Time performance for detecting & clustering input dataset of OpenK and OpenRefine .