Confusion matrix on the test set using the standard LightGBM classifier
Confusion matrix on the test set using LightGBM and the customized multi-class Focal Loss class (OneVsRestLightGBMWithCustomizedLoss)
This repository contains the source code of the medium post Multi-Class classification using Focal Loss and LightGBM
The post details how focal loss can be used for a multi class classification LightGBM model.
By using Focal Loss, sample weight balancing, or artificial addition of new samples to reduce the imbalance is not required. On an artificially generated multi-class imbalanced dataset, the use of Focal loss increased the recall value and eliminated some false positives and negatives in the minority classes.