Text Classification
Transformers
TensorBoard
Safetensors
distilbert
Generated from Trainer
text-embeddings-inference
Instructions to use kdrucshi/DistilBERT_IMDB with libraries, inference providers, notebooks, and local apps. Follow these links to get started.
- Libraries
- Transformers
How to use kdrucshi/DistilBERT_IMDB with Transformers:
# Use a pipeline as a high-level helper from transformers import pipeline pipe = pipeline("text-classification", model="kdrucshi/DistilBERT_IMDB")# Load model directly from transformers import AutoTokenizer, AutoModelForSequenceClassification tokenizer = AutoTokenizer.from_pretrained("kdrucshi/DistilBERT_IMDB") model = AutoModelForSequenceClassification.from_pretrained("kdrucshi/DistilBERT_IMDB", device_map="auto") - Notebooks
- Google Colab
- Kaggle
Demo
DistilBERT_IMDB
This model is a fine-tuned version of distilbert-base-uncased on an unknown dataset. It achieves the following results on the evaluation set:
- Loss: 0.2407
- Accuracy: 0.9156
- F1: 0.9153
Model description
- Base Model - Distilbert-base-uncased
- Fine-tuned for binary classification
- Achieved ~90% accuracy on test set
Training procedure
Training hyperparameters
The following hyperparameters were used during training:
- learning_rate: 2e-05
- train_batch_size: 32
- eval_batch_size: 32
- seed: 42
- optimizer: Use OptimizerNames.ADAMW_TORCH_FUSED with betas=(0.9,0.999) and epsilon=1e-08 and optimizer_args=No additional optimizer arguments
- lr_scheduler_type: linear
- lr_scheduler_warmup_ratio: 0.06
- num_epochs: 10
- mixed_precision_training: Native AMP
Training results
| Training Loss | Epoch | Step | Validation Loss | Accuracy | F1 |
|---|---|---|---|---|---|
| 0.5779 | 0.16 | 100 | 0.5232 | 0.8628 | 0.8565 |
| 0.3239 | 0.32 | 200 | 0.3461 | 0.8596 | 0.8408 |
| 0.2367 | 0.48 | 300 | 0.2935 | 0.8806 | 0.8863 |
| 0.2037 | 0.64 | 400 | 0.2547 | 0.9006 | 0.8968 |
| 0.2215 | 0.8 | 500 | 0.2354 | 0.908 | 0.9064 |
| 0.1866 | 0.96 | 600 | 0.2462 | 0.9046 | 0.9063 |
| 0.161 | 1.12 | 700 | 0.2435 | 0.911 | 0.9095 |
| 0.2101 | 1.28 | 800 | 0.2407 | 0.9156 | 0.9153 |
Framework versions
- Transformers 4.56.1
- Pytorch 2.8.0+cu126
- Datasets 4.0.0
- Tokenizers 0.22.0
- Downloads last month
- 7
Model tree for kdrucshi/DistilBERT_IMDB
Base model
distilbert/distilbert-base-uncased