scxpand.lightgbm.lightgbm_params#

Classes

BoostingType(*values)

Enumeration of supported LightGBM boosting types.

LightGBMParams([use_log_transform, ...])

Parameters for LightGBM model.

MetricType(*values)

Enumeration of supported LightGBM metric types.

ObjectiveType(*values)

Enumeration of supported LightGBM objective types.

class scxpand.lightgbm.lightgbm_params.BoostingType(*values)#

Enumeration of supported LightGBM boosting types.

DART = 'dart'#
GBDT = 'gbdt'#
GOSS = 'goss'#
RF = 'rf'#
class scxpand.lightgbm.lightgbm_params.LightGBMParams(use_log_transform=True, use_zscore_norm=True, num_leaves=31, max_depth=-1, learning_rate=0.1, n_estimators=100, min_child_samples=20, reg_alpha=0.0, reg_lambda=0.0, random_seed=42, force_col_wise=True, deterministic=True, class_weight='balanced', n_jobs=-1, feature_fraction=1.0, bagging_fraction=1.0, min_split_gain=0.0, min_child_weight=0.001, boosting_type=BoostingType.GBDT, objective=ObjectiveType.BINARY, metric=MetricType.BINARY_LOGLOSS, verbose=-1)#

Parameters for LightGBM model.

Note: When max_depth > 0, num_leaves should be <= 2^max_depth to avoid overfitting.

classmethod get_model_type()#

Return the model type identifier for this parameter class.

Return type:

ModelType

__init__(use_log_transform=True, use_zscore_norm=True, num_leaves=31, max_depth=-1, learning_rate=0.1, n_estimators=100, min_child_samples=20, reg_alpha=0.0, reg_lambda=0.0, random_seed=42, force_col_wise=True, deterministic=True, class_weight='balanced', n_jobs=-1, feature_fraction=1.0, bagging_fraction=1.0, min_split_gain=0.0, min_child_weight=0.001, boosting_type=BoostingType.GBDT, objective=ObjectiveType.BINARY, metric=MetricType.BINARY_LOGLOSS, verbose=-1)#
bagging_fraction: float = 1.0#
boosting_type: BoostingType = 'gbdt'#
class_weight: str | None = 'balanced'#
deterministic: bool = True#
feature_fraction: float = 1.0#
force_col_wise: bool = True#
learning_rate: float = 0.1#
max_depth: int = -1#
metric: MetricType = 'binary_logloss'#
min_child_samples: int = 20#
min_child_weight: float = 0.001#
min_split_gain: float = 0.0#
n_estimators: int = 100#
n_jobs: int = -1#
num_leaves: int = 31#
objective: ObjectiveType = 'binary'#
random_seed: int = 42#
reg_alpha: float = 0.0#
reg_lambda: float = 0.0#
use_log_transform: bool = True#
use_zscore_norm: bool = True#
verbose: int = -1#
class scxpand.lightgbm.lightgbm_params.MetricType(*values)#

Enumeration of supported LightGBM metric types.

AUC = 'auc'#
BINARY_LOGLOSS = 'binary_logloss'#
MAE = 'mae'#
MULTICLASS_LOGLOSS = 'multi_logloss'#
NDCG = 'ndcg'#
RMSE = 'rmse'#
class scxpand.lightgbm.lightgbm_params.ObjectiveType(*values)#

Enumeration of supported LightGBM objective types.

BINARY = 'binary'#
LAMBDARANK = 'lambdarank'#
MULTICLASS = 'multiclass'#
REGRESSION = 'regression'#