A machine learning framework.
Project description
Lunax is a machine learning framework specifically designed for the processing and analysis of tabular data. The name Lunax is derived from the name of a beloved feline mascot at South China University of Technology
猸愶笍 Star it if you like it 猸愶笍
Installation
conda create -n your_env_name python=3.11
conda activate your_env_name
pip install lunax
Features
- Data loading and Data pre-processing
- EDA analysis
- Supports multi-model training and Hyperparameter tuning
- Comprehensive model evaluation and Explainable AI (XAI)
Quick Start
Data Loading and Pre-processing
from lunax.data_processing.utils import *
df_train = load_data('train.csv') # or df = load_data('train.parquet',mode='parquet')
target = 'label_column_name'
df_train = preprocess_data(df_train,target) # data pre-processing, including missing value handling, feature encoding, feature scaling
X_train, X_val, y_train, y_val = split_data(df_train, target)
Exploratory Data Analysis
from lunax.viz import numeric_eda, categoric_eda
numeric_eda([df_train,df_test],['train','test'],target=target) # numeric feature analysis
categoric_eda([df_train,df_test],['train','test'],target=target) # categorical feature analysis
Automation Machine Learning Modeling
from lunax.models import xgb_clf # or xgb_reg, lgbm_reg, lgbm_clf, cat_clf, cat_reg
from lunax.hyper_opt import OptunaTuner
tuner = OptunaTuner(n_trials=10,model_class="XGBClassifier") # Hyperparameter optimizer, n_trials is the number of optimization times
# or "XGBRegressor", "LGBMRegressor", "LGBMClassifier" , "CatClassifier", "CatRegressor"
results = tuner.optimize(X_train, y_train, X_val, y_val)
best_params = results['best_params']
model = xgb_clf(best_params)
model.fit(X_train, y_train)
Model Evaluation and Explainable AI (XAI)
model.evaluate(X_val, y_val)
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
lunax-0.0.6.tar.gz
(15.1 kB
view details)
File details
Details for the file lunax-0.0.6.tar.gz.
File metadata
- Download URL: lunax-0.0.6.tar.gz
- Upload date:
- Size: 15.1 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: twine/6.1.0 CPython/3.11.11
File hashes
| Algorithm | Hash digest | |
|---|---|---|
| SHA256 |
788e01cc0e898d39b941a6be563270e8f980a7af7de4e22b8354c600d60a82b6
|
|
| MD5 |
3ffc1bc59be3152d7a17acf83452973b
|
|
| BLAKE2b-256 |
5a7d3e8868ed7b4a6d5f8388360b9b19c214a9ce4052643729d41579f28d775e
|