Skip to main content

A universal Python toolkit for detecting and fixing data imbalance.

Project description

balens

A universal Python toolkit for detecting and fixing data imbalance with support for SMOTE, ADASYN, class weighting, intelligent binning, and auto export. Ideal for ML pipelines, AutoML, and data science workflows.

Features

  • Automatic imbalance detection
  • Smart binning for regression targets
  • Resampling (SMOTE, ADASYN, etc.)
  • Class weights computation
  • Export balanced datasets and reports
  • CLI and Python SDK

Installation

pip install .

CLI Usage

balens fix --file data.csv --target Outcome --method smote --auto-bin --export

Python SDK Usage

from balens import auto_balance
X_res, y_res = auto_balance(df, target="Outcome", method="smote")

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

balens-0.0.2.tar.gz (50.0 kB view details)

Uploaded Source

Built Distribution

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

balens-0.0.2-py3-none-any.whl (53.4 kB view details)

Uploaded Python 3

File details

Details for the file balens-0.0.2.tar.gz.

File metadata

  • Download URL: balens-0.0.2.tar.gz
  • Upload date:
  • Size: 50.0 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for balens-0.0.2.tar.gz
Algorithm Hash digest
SHA256 bc43e117aff65f898830eee3395a2ed7ee28039f6ee13b9a16891347a9603fe4
MD5 aecaab18be3c59b3a7fd43a8d99dd5f0
BLAKE2b-256 1d97a5512dc0e932a8531f7c7fbc8a3150514111fad5076b5325eff8d46b156a

See more details on using hashes here.

File details

Details for the file balens-0.0.2-py3-none-any.whl.

File metadata

  • Download URL: balens-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 53.4 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.1.0 CPython/3.12.8

File hashes

Hashes for balens-0.0.2-py3-none-any.whl
Algorithm Hash digest
SHA256 586ec2a6ea35b97a638e0f7f7878472a99439451bd7a1dbf9a7bce29c50a1b6e
MD5 df20697c88c979cd0257de388c57e184
BLAKE2b-256 7f985d92efabd98950e7a7f549f5db409e43592fb803b6cb94767a61f253c351

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