Skip to main content

SmartClean

An intelligent Python library for automated data cleaning with profiling, preprocessing, and detailed reporting.

SmartClean simplifies the data cleaning process by automatically identifying and handling common data quality issues such as missing values, duplicate records, and outliers. It generates comprehensive profiling reports before and after cleaning, making datasets ready for analysis and machine learning.


Features

  • Automated missing value detection and handling
  • Duplicate row detection and removal
  • Outlier detection using the IQR method
  • Automatic data profiling
  • Before and after cleaning reports
  • Configurable cleaning pipeline
  • Modular and extensible architecture
  • Simple and intuitive API
  • Open-source and developer friendly

Installation

Clone the repository:

git clone https://github.com/yourusername/SmartClean.git

cd SmartClean

Install dependencies:

pip install -r requirements.txt

Quick Start

import pandas as pd
from smartclean import Cleaner

# Load dataset
df = pd.read_csv("data/raw/Kaggle/1.csv")

# Initialize SmartClean
cleaner = Cleaner()

# Clean dataset
result = cleaner.clean(df)

print(result.cleaned_df.head())
print(result.report)

Example Output

========== Missing Value Cleaning ==========

✓ Column: Age              | Missing: 177 | Strategy: mean
✓ Column: Cabin            | Missing: 687 | Strategy: most_frequent
✓ Column: Embarked         | Missing: 2   | Strategy: most_frequent

========== Duplicate Cleaning ==========

✓ No duplicate rows found.

========== Outlier Cleaning ==========

✓ Outlier Values Capped : 441

CleaningResult(rows=891, columns=12)

Project Structure

SmartClean/
│
├── smartclean/
│   ├── cleaning/
│   ├── config/
│   ├── core/
│   ├── handlers/
│   ├── utils/
│   ├── cleaner.py
│   ├── result.py
│   └── __init__.py
│
├── example/
│   └── demo.py
│
├── data/
│
├── reports/
│
├── README.md
└── requirements.txt

Cleaning Pipeline

Dataset
    │
    ▼
Data Profiling
    │
    ▼
Missing Value Handling
    │
    ▼
Duplicate Removal
    │
    ▼
Outlier Detection
    │
    ▼
Updated Profiling
    │
    ▼
Cleaning Report
    │
    ▼
Clean Dataset

Current Cleaning Capabilities

Missing Values

  • Mean imputation
  • Median imputation
  • Most frequent value imputation
  • Drop columns with excessive missing values

Duplicates

  • Detect duplicate rows
  • Remove duplicate records

Outliers

  • IQR-based outlier detection
  • Outlier capping
  • Outlier removal

Output

SmartClean returns a CleaningResult object.

result = Cleaner().clean(df)

result.cleaned_df
result.before_profile
result.after_profile
result.report

Roadmap

Version 1.0

  • Data profiling
  • Missing value handling
  • Duplicate removal
  • Outlier detection
  • Cleaning reports

Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

smartclean_ai-1.0.0.tar.gz (13.7 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

smartclean_ai-1.0.0-py3-none-any.whl (17.7 kB view details)

Uploaded Python 3

File details

Details for the file smartclean_ai-1.0.0.tar.gz.

File metadata

  • Download URL: smartclean_ai-1.0.0.tar.gz
  • Upload date:
  • Size: 13.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for smartclean_ai-1.0.0.tar.gz
Algorithm Hash digest
SHA256 74989f1180847609296dd508d3c4946e62208624a71b243012128616bb51d1f8
MD5 c89ac00a77b8cb334cb1ad4ad5c45b25
BLAKE2b-256 8d94a8c1089d99a0765c4236f7811b5c734f343191a896df33c9b31d1d882063

See more details on using hashes here.

File details

Details for the file smartclean_ai-1.0.0-py3-none-any.whl.

File metadata

  • Download URL: smartclean_ai-1.0.0-py3-none-any.whl
  • Upload date:
  • Size: 17.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/7.0.0 CPython/3.13.14

File hashes

Hashes for smartclean_ai-1.0.0-py3-none-any.whl
Algorithm Hash digest
SHA256 68a61b4c6058f2319c6bff4f767dfeb21dc5a5a0f79f0e49518ba70f7a1ca115
MD5 39cccfb88d3c8acb99614e9e83a4b65b
BLAKE2b-256 b3c6eeda9c67fc47956d7987ea5c74d5fdd71a20a2a0c1603b2a0d1d7eea39e3

See more details on using hashes here.

Supported by

AWS Cloud computing and Security Sponsor Datadog Monitoring Depot Continuous Integration Fastly CDN Google Download Analytics Pingdom Monitoring Sentry Error logging StatusPage Status page