Title: Lab 13 — Clean It, Compress It, Compare It
Course: AIINFRA 100: AI Systems & Development Environments > Section: Week 13 — Data & Storage Infrastructure for AI

🛠️ Lab 13 — Clean It, Compress It, Compare It (50 pts)

Goal: Get hands-on practice identifying data-quality problems in a real (messy) dataset, cleaning it with pandas, and comparing how file format affects storage size — all for free, in your browser, with no installation required. Steps:

1. Create a free Kaggle account at kaggle.com if you don't already have one.
2. Search Kaggle for the "Cafe Sales — Dirty Data for Cleaning Training" dataset (or the Pandas Practice Dataset if you prefer). Open it and click "New Notebook" to launch a free, browser-based Jupyter notebook — you do not need to install anything on your computer.
3. Load the dataset into a pandas DataFrame with pd.read_csv() and take a first look using .head(), .info(), and .isnull().sum().
4. Identify problems: write code to count missing values and duplicate rows in the dataset. Note what you find.
5. Clean the data: use fillna() to fill in missing values where appropriate (e.g., filling a missing category with "Unknown"), dropna() to remove rows that are missing critical information, and drop_duplicates() to remove duplicate rows.
6. Export and compare formats: save your cleaned DataFrame twice — once with df.to_csv("cleaned_data.csv") and once with df.to_parquet("cleaned_data.parquet"). Check the file size of each (in Kaggle's file browser, or with Python's os.path.getsize()) and record the difference.
7. Reflect: in 3–4 sentences, describe which data-quality dimensions (completeness, consistency, accuracy) the raw dataset violated, and explain in your own words why the Parquet file came out smaller (or larger) than the CSV.

Deliverables: Submit your notebook (download as .ipynb or share the Kaggle notebook link) along with your 3–4 sentence written reflection, either pasted into the text-entry box or included as a markdown cell at the end of your notebook.