Data2Model / README.md
Nausad's picture
Upload 25 files
facf506 verified
|
Raw History Blame Contribute Delete
3.86 kB
metadata
title: Data2Model
emoji: πŸš€
colorFrom: indigo
colorTo: red
sdk: docker
app_port: 7860
pinned: false
license: mit
short_description: Upload data, train models, deploy instantly
tags:
  - machine-learning
  - automl
  - flask
  - scikit-learn
  - classification
  - regression
  - clustering

πŸš€ Data2Model

Automated Machine Learning Pipeline β€” From Raw Data to Deployable Web App

Upload a dataset β†’ Configure preprocessing β†’ Train models β†’ Download a ready-to-deploy prediction app


✨ Features

Feature Description
One-Click AutoML Upload CSV/Excel/JSON and automatically train & compare 8+ ML algorithms
Smart Type Detection Automatically distinguishes numeric vs categorical columns with manual override
Per-Column Preprocessing Configure scaling (Standard, MinMax, Robust, Normalizer) and encoding (One-Hot, Label, Ordinal, Binary) individually per column
Flexible Null Handling Per-column imputation: mean, median, mode, custom constant, or row deletion
Column Dropping Exclude irrelevant columns (IDs, timestamps, etc.) before training
Flexible Data Splits Train/Test or Train/Test/Validation with configurable percentages
Data Dashboard Auto-generated visualizations: histograms, correlation heatmaps, distributions
Deployable App Export Download a complete Flask web app (ZIP) with your trained model built-in
Prediction Interface Upload new data for batch predictions with a trained model
Auto Cleanup Uploaded datasets are automatically deleted after training and on server shutdown

🧠 Supported Algorithms

Classification

Logistic Regression Β· Random Forest Β· Gradient Boosting Β· Decision Tree Β· KNN Β· Naive Bayes Β· SVM Β· AdaBoost Β· XGBoost Β· LightGBM

Regression

Linear Regression Β· Random Forest Β· Gradient Boosting Β· Decision Tree Β· KNN Β· SVR Β· AdaBoost Β· XGBoost Β· LightGBM

Unsupervised

K-Means Β· DBSCAN Β· Agglomerative Clustering Β· PCA


πŸ”§ How to Use

  1. Upload β€” Drop your CSV, Excel, or JSON dataset
  2. Configure β€” Set null handling, scaling, encoding, and column selection per column
  3. Train β€” Choose problem type, target column, and data split strategy
  4. Evaluate β€” View metrics (Accuracy, F1, RΒ², RMSE) and preprocessing summary
  5. Deploy β€” Download the trained model or a complete Flask prediction app (ZIP)

πŸ“ Project Structure

β”œβ”€β”€ app.py                  # Flask web application
β”œβ”€β”€ model_pipeline.py       # AutoML pipeline engine
β”œβ”€β”€ Dockerfile              # Container configuration for HF Spaces
β”œβ”€β”€ requirements.txt        # Python dependencies
β”œβ”€β”€ templates/              # Jinja2 HTML templates
β”‚   β”œβ”€β”€ base.html           #   Base layout
β”‚   β”œβ”€β”€ index.html          #   Home / upload page
β”‚   β”œβ”€β”€ configure.html      #   Preprocessing & training config
β”‚   β”œβ”€β”€ result.html         #   Training results & metrics
β”‚   β”œβ”€β”€ predict.html        #   Prediction interface
β”‚   └── ...                 #   About, docs, feedback, error pages
β”œβ”€β”€ static/                 # CSS & JavaScript
β”œβ”€β”€ uploads/                # Temporary uploads (auto-cleaned)
└── saved_models/           # Trained models & deployable ZIPs

πŸ›‘οΈ Data Privacy

  • Uploaded datasets are never stored permanently
  • Files are deleted immediately after training completes
  • All remaining uploads are wiped on server shutdown

πŸ’» Run Locally

git clone https://huggingface.co/spaces/YOUR_USERNAME/Data2Model
cd Data2Model
pip install -r requirements.txt
python app.py

Open http://localhost:5000 in your browser.


Built with ❀️ using Flask & scikit-learn