Skip to main content

Automated machine learning preprocessing and modeling tool

Project description

Auto ML Processor

A Python package for automated machine learning preprocessing and model training. This package streamlines common data preprocessing tasks and model training for classification and regression problems.

Features

  • Automated data loading from multiple sources:
    • Local files (CSV, Excel, JSON, Parquet, Feather, Pickle)
    • URLs (direct downloads with format detection)
    • Hugging Face datasets
    • Kaggle datasets
    • OpenML datasets
  • Intelligent missing value handling with configurable thresholds
  • Automatic feature type detection (categorical vs. numerical)
  • Standardized preprocessing pipeline for feature engineering
  • Built-in model training for common algorithms (XGBoost, KNN, Random Forest)
  • Simple evaluation and saving of models
  • One-line full processing option for quick execution

Installation

pip install auto-ml-processor

Quick Start

from auto_ml_processor import AutoMLProcessor

# Initialize processor
processor = AutoMLProcessor()

# Process data and train model in one line
metrics = processor.full_process(
    file_path='your_data.csv',
    target_col='target_column',
    fill_na_threshold=0.6,  # Remove columns with ≥60% missing values
    model_name='xgboost'
)

print(f"Model performance: {metrics}")

Loading Data from Different Sources

# From a URL
processor.load_data(
    'https://archive.ics.uci.edu/ml/machine-learning-databases/iris/iris.data',
    source_type='url'
)

# From Hugging Face datasets
processor.load_data(
    'mnist',
    source_type='huggingface',
    split='train'  # Load the training split
)

# From Kaggle
processor.load_data(
    'uciml/iris',
    source_type='kaggle',
    download_path='./kaggle_data'
)

# From OpenML
processor.load_data(
    'iris',  # Dataset name or ID
    source_type='openml'
)

Step-by-Step Usage

# Initialize
processor = AutoMLProcessor(verbose=True)

# Load data
df = processor.load_data('dataset.csv')

# Handle missing values
processor.handle_missing_values(fill_na_threshold=0.6)

# Prepare data
processor.prepare_data(target_col='target', test_size=0.2)

# Train model
processor.train_model(model_name='knn')

# Evaluate
metrics = processor.evaluate_model()

# Save model
processor.save_model('output_directory')

Making Predictions

# Load saved model
loaded_processor = AutoMLProcessor.load_model('output_directory')

# Make predictions on new data
import pandas as pd
new_data = pd.read_csv('new_data.csv')
predictions = loaded_processor.predict(new_data)

License

MIT License

Project details


Download files

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

Source Distribution

auto_ml_processor-0.1.1.tar.gz (9.8 kB view details)

Uploaded Source

Built Distribution

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

auto_ml_processor-0.1.1-py3-none-any.whl (8.9 kB view details)

Uploaded Python 3

File details

Details for the file auto_ml_processor-0.1.1.tar.gz.

File metadata

  • Download URL: auto_ml_processor-0.1.1.tar.gz
  • Upload date:
  • Size: 9.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.9.21

File hashes

Hashes for auto_ml_processor-0.1.1.tar.gz
Algorithm Hash digest
SHA256 c43ee893941f650b7ea8d35f0cb973e1f5d221948c1f5e6a3425ead94fbc077e
MD5 52f333f9833520806d377c7b706076fd
BLAKE2b-256 1e2dfcda569e0efd15b7928695530a0a471a1ea749664636cfd780682d0ca940

See more details on using hashes here.

File details

Details for the file auto_ml_processor-0.1.1-py3-none-any.whl.

File metadata

File hashes

Hashes for auto_ml_processor-0.1.1-py3-none-any.whl
Algorithm Hash digest
SHA256 8b920cbae2d2d0912a4da185a8b48086ef91b6f5e7dcbb7cda1325bdce815ff9
MD5 12ebc9fd2c3488092da2e88a89d3bdb9
BLAKE2b-256 cb046c55359482a5b801078570335fb392d6e2bffa00c21a245a0cd97108596e

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