muzammal-shafique/hateful-memes-classifier
0
Hateful Meme Classifier ๐ซ๐ผ๏ธ๐ค
This is a Gradio web application that classifies memes as hateful or not hateful. It uses a fine-tuned CLIP model that analyzes both image and text in a meme to detect hatefulness.
How to Use
- Upload a meme image (JPEG/PNG) using the file uploader. (If the meme has text, the model will analyze the image and embedded text together.)
- Click Submit. The model will output either "Hateful Meme" or "Not Hateful".
- Results also include a confidence score.
Model Details
- The model is based on OpenAI's CLIP (ViT-B/32) architecture, fine-tuned on the Facebook Hateful Memes challenge data.
- Model file size is ~300MB. It is included in this app for inference.
- The CLIPProcessor is used to preprocess images (and text).
About
- Author: Muzammal Shafique
- Dataset: Facebook Hateful Memes (2020), containing multimodal memes with labels.
Check out the configuration reference at https://huggingface.co/docs/hub/spaces-config-reference
