Skip to main content

An ensemble classifier that combines multiple base models using learned weights

Project description

LestariClassifier

LESTARI (Layered Ensemble Stacking Technique with Adaptive Regression of Individual-errors) is an advanced ensemble classifier that intelligently combines multiple base models using a weighted ensemble approach. The weights are dynamically learned based on the prediction errors of individual instances across each base model. LESTARI was developed as part of my Master of Computer Science thesis at BINUS University, and is lovingly dedicated to my beloved wife, whose surname Lestari inspired the name of this technique.

Installation

pip install lestari-classifier

Quick Start

from lestari_classifier import LestariClassifier
from lightgbm import LGBMClassifier
from catboost import CatBoostClassifier
from sklearn.ensemble import RandomForestClassifier

# Define base models
estimators = [
    ('rf', RandomForestClassifier(n_estimators=100, random_state=42)),
    ('lgbm', LGBMClassifier(n_estimators=100, random_state=42)),
    ('cb', CatBoostClassifier(iterations=100, verbose=0, random_state=42))
]

# Initialize and use LestariClassifier
clf = LestariClassifier(estimators=estimators)
clf.fit(X_train, y_train)
predictions = clf.predict(X_test)
probabilities = clf.predict_proba(X_test)

Features

  • Supports multiple base models
  • Automatic weight learning
  • Compatible with scikit-learn API
  • Probability estimates support
  • Internal cross-validation

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

lestari_classifier-0.1.0.tar.gz (4.7 kB view details)

Uploaded Source

Built Distribution

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

lestari_classifier-0.1.0-py3-none-any.whl (4.9 kB view details)

Uploaded Python 3

File details

Details for the file lestari_classifier-0.1.0.tar.gz.

File metadata

  • Download URL: lestari_classifier-0.1.0.tar.gz
  • Upload date:
  • Size: 4.7 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/5.1.1 CPython/3.10.12

File hashes

Hashes for lestari_classifier-0.1.0.tar.gz
Algorithm Hash digest
SHA256 3625e15ed924c377d6a39d90e7974d16b4b122b62df70411ee4aabfdcb8c5f6b
MD5 8de4b2569aa24b25d51beb9079545ac1
BLAKE2b-256 f315201942ff4bc56f964816d6cfe8c076cffc45a875d1ff6837cd613f4b2294

See more details on using hashes here.

File details

Details for the file lestari_classifier-0.1.0-py3-none-any.whl.

File metadata

File hashes

Hashes for lestari_classifier-0.1.0-py3-none-any.whl
Algorithm Hash digest
SHA256 2725706c6456326dc7890b350aa1e9cf0add94aa890ea495d6bee0f869fe73bc
MD5 4f8527748009ed4c57394519b4ab2157
BLAKE2b-256 e751d3f8a8ac3eaa11970d248cffa7af4b3abde5e45965947ebee9a3660bb8fc

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