Tabular Classification
Scikit-learn
Joblib
English
malware-detection
lightgbm
scikit-learn
Eval Results (legacy)
Instructions to use mihai-chindris/malware-detection-lgbm with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Scikit-learn
How to use mihai-chindris/malware-detection-lgbm with Scikit-learn:
from huggingface_hub import hf_hub_download import joblib model = joblib.load( hf_hub_download("mihai-chindris/malware-detection-lgbm", "sklearn_model.joblib") ) # only load pickle files from sources you trust # read more about it here https://skops.readthedocs.io/en/stable/persistence.html - Notebooks
- Google Colab
- Kaggle
Improve model card: add Intended Use, Training, Limitations, Citation sections
Browse files
README.md
CHANGED
|
@@ -34,22 +34,57 @@ model-index:
|
|
| 34 |
|
| 35 |
# Malware Detection LightGBM
|
| 36 |
|
| 37 |
-
LightGBM-based static malware detector for PE files.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 38 |
|
| 39 |
## Performance (hold-out test set)
|
| 40 |
|
| 41 |
-
|
| 42 |
-
-
|
| 43 |
-
|
|
|
|
|
|
|
| 44 |
|
| 45 |
## Artifacts
|
| 46 |
|
| 47 |
-
- `production_model.joblib`
|
| 48 |
-
- `preprocessing_pipeline.joblib`
|
| 49 |
-
- `feature_names.json`
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 50 |
|
| 51 |
-
|
| 52 |
|
| 53 |
-
|
| 54 |
-
-
|
| 55 |
-
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| 34 |
|
| 35 |
# Malware Detection LightGBM
|
| 36 |
|
| 37 |
+
LightGBM-based static malware detector for PE (Portable Executable) files. Classifies Windows executables as benign or malicious using structural PE header features.
|
| 38 |
+
|
| 39 |
+
## Intended Use
|
| 40 |
+
|
| 41 |
+
- **Primary**: Static analysis of PE files for malware classification
|
| 42 |
+
- **Secondary**: Educational demonstration of ML-based malware detection
|
| 43 |
+
- **Not suitable for**: Dynamic analysis, packed/obfuscated samples, or production-grade antivirus replacement
|
| 44 |
+
|
| 45 |
+
## Training Data
|
| 46 |
+
|
| 47 |
+
- **Dataset**: [fabriciojoc/brazilian-malware-dataset](https://huggingface.co/datasets/fabriciojoc/brazilian-malware-dataset)
|
| 48 |
+
- **Features**: Structural PE header fields (imports, sections, resources, etc.)
|
| 49 |
+
- **Split**: 80/20 train/test with stratification
|
| 50 |
+
|
| 51 |
+
## Training Procedure
|
| 52 |
+
|
| 53 |
+
- **Model**: LightGBM (gradient boosting)
|
| 54 |
+
- **Preprocessing**: Custom pipeline in `preprocessing_pipeline.joblib`
|
| 55 |
+
- **Hyperparameters**: See `model_metrics.json` for full configuration
|
| 56 |
|
| 57 |
## Performance (hold-out test set)
|
| 58 |
|
| 59 |
+
| Metric | Value |
|
| 60 |
+
|--------|-------|
|
| 61 |
+
| AUC | 0.9978 |
|
| 62 |
+
| Accuracy | 0.9895 |
|
| 63 |
+
| Confusion Matrix | [[4158, 66], [39, 5774]] |
|
| 64 |
|
| 65 |
## Artifacts
|
| 66 |
|
| 67 |
+
- `production_model.joblib` - trained LightGBM model
|
| 68 |
+
- `preprocessing_pipeline.joblib` - feature extraction pipeline
|
| 69 |
+
- `feature_names.json` - feature name mapping
|
| 70 |
+
- `model_metrics.json` - training metrics and configuration
|
| 71 |
+
|
| 72 |
+
## Limitations
|
| 73 |
+
|
| 74 |
+
- Trained on PE header features only; does not analyze code behavior
|
| 75 |
+
- Performance may degrade on obfuscated or packed samples
|
| 76 |
+
- Tested on Brazilian malware dataset; generalization to other regions unverified
|
| 77 |
+
|
| 78 |
+
## Citation
|
| 79 |
|
| 80 |
+
If you use this model, please cite the original dataset:
|
| 81 |
|
| 82 |
+
```bibtex
|
| 83 |
+
@dataset{fabriciojoc2024brazilian-malware,
|
| 84 |
+
author = {Fabricio, Joc},
|
| 85 |
+
title = {Brazilian Malware Dataset},
|
| 86 |
+
year = {2024},
|
| 87 |
+
publisher = {Hugging Face},
|
| 88 |
+
url = {https://huggingface.co/datasets/fabriciojoc/brazilian-malware-dataset}
|
| 89 |
+
}
|
| 90 |
+
```
|