Downloads · 30 days
13
26% of all-time downloads
MartinRodrigo/distilbert-sentiment-imdb
distilbert-sentiment-imdb is a text classification model from MartinRodrigo. Use it when you need a label for a piece of text. It is set up for transformers. The card lists the license as apache-2.0.
This model is a fine-tuned version of unknown for sentiment analysis on the UNKNOWN dataset.
Downloads · 30 days
13
26% of all-time downloads
All-time downloads
50
Public
Parameters
67M
1.6 GB on disk
Likes
0
Public
Click a slice to open those files.
.pt1.1 GB · 57%
From the Hugging Face model README
This model is a fine-tuned version of unknown for sentiment analysis on the UNKNOWN dataset.
Model Architecture: unknown
Task: Binary Sentiment Classification (Positive/Negative)
Language: English
Training Date: N/A
| Metric | Score |
|---|---|
| Accuracy | 0.0000 |
| F1 Score | 0.0000 |
| Precision | 0.0000 |
| Recall | 0.0000 |
| Loss | 0.0000 |
{}
from transformers import pipeline
# Load the model
classifier = pipeline("sentiment-analysis", model="YOUR_USERNAME/YOUR_MODEL_NAME")
# Predict
result = classifier("I love this movie!")
print(result)
# [{'label': 'POSITIVE', 'score': 0.9998}]
from transformers import AutoTokenizer, AutoModelForSequenceClassification
import torch
# Load model and tokenizer
model_name = "YOUR_USERNAME/YOUR_MODEL_NAME"
tokenizer = AutoTokenizer.from_pretrained(model_name)
model = AutoModelForSequenceClassification.from_pretrained(model_name)
# Prepare input
text = "This is an amazing product!"
inputs = tokenizer(text, return_tensors="pt", truncation=True, max_length=512)
# Predict
with torch.no_grad():
outputs = model(**inputs)
predictions = torch.nn.functional.softmax(outputs.logits, dim=-1)
# Get result
label_id = torch.argmax(predictions).item()
score = predictions[0][label_id].item()
labels = ["NEGATIVE", "POSITIVE"]
print(f"Label: {labels[label_id]}, Score: {score:.4f}")
Training history visualization is available in the model files.
0: NEGATIVE
1: POSITIVE
{}
If you use this model, please cite:
@misc{sentiment-model-unknown,
author = {Your Name},
title = {unknown Fine-tuned for Sentiment Analysis},
year = {2025},
publisher = {Hugging Face},
howpublished = {\url{https://huggingface.co/YOUR_USERNAME/YOUR_MODEL_NAME}}
}
For questions or feedback, please open an issue in the repository.
Apache 2.0
Generated with MLflow tracking 🚀