Downloads · 30 days
8
8% of all-time downloads
real-jiakai/NLP_with_Disaster_Tweets
NLP_with_Disaster_Tweets is a text classification model from real-jiakai. Use it when you need a label for a piece of text. It is set up for transformers. The card lists the license as mit.
This model is fine-tuned BERT for classifying whether a tweet is about a real disaster or not.
Downloads · 30 days
8
8% of all-time downloads
All-time downloads
100
Public
Parameters
109M
438 MB on disk
Likes
0
Public
Click a slice to open those files.
.safetensors438 MB · 100%
From the Hugging Face model README
This model is fine-tuned BERT for classifying whether a tweet is about a real disaster or not.
bert-base-uncasedfrom transformers import AutoConfig, AutoTokenizer, AutoModelForSequenceClassification
# Load model and tokenizer
tokenizer = AutoTokenizer.from_pretrained("real-jiakai/NLP_with_Disaster_Tweets")
model = AutoModelForSequenceClassification.from_pretrained("real-jiakai/NLP_with_Disaster_Tweets")
# Example usage
text = "There was a major earthquake in California"
inputs = tokenizer(text, return_tensors="pt", padding=True, truncation=True, max_length=512)
outputs = model(**inputs)
predicted_class = outputs.logits.argmax(-1).item()
This model is licensed under the MIT License.
If you use this model in your work, please cite:
@misc{NLP_with_Disaster_Tweets,
author = {real-jiakai},
title = {NLP_with_Disaster_Tweets},
year = {2024},
url = {https://huggingface.co/real-jiakai/NLP_with_Disaster_Tweets},
publisher = {Hugging Face}
}