Downloads · 30 days
0
sdhaos/isHotdog
isHotdog is a machine learning model from sdhaos. Use it for the machine learning task on the model card, and read the license before you ship it in a product. The card lists the license as mit.
isHotdog is a small MobileNetV3 image classifier inspired by the Silicon Valley "Hotdog / Not Hotdog" joke.
Downloads · 30 days
0
Access
Public
Updated Jul 10, 2026
Repo size
6.2 MB
Likes
0
Public
Click a slice to open those files.
.pt6.2 MB · 100%
From the Hugging Face model README
isHotdog is a small MobileNetV3 image classifier inspired by the Silicon Valley "Hotdog / Not Hotdog" joke.
It answers one question:
Hotdog
Not Hotdog
hotvision/
app.py Gradio UI
hotvision_model.py model loading and prediction logic
prepare_data.py creates Food-101 binary dataset
train.py trains MobileNetV3 Small
predict.py CLI prediction
requirements.txt dependencies
README.md internal project notes
Generated local folders:
dataset/ prepared train/val image-folder dataset
raw_data/ Food-101 cache
model/isHotdog.pt trained model checkpoint
photos/ local test images
cd models/hotvision
python3.12 -m venv .venv
source .venv/bin/activate
pip install -r requirements.txt
isHotdog can use three sources:
hot_dog as Hotdog, selected other foods as Not Hotdogantareepdey/Hotdog-or-not-a-hotdog: local hotdog / others imageshotdog-nothotdog: local train/test hotdog / nothotdog imagesbghira/not-a-hotdog: hard negative not-hotdog imagesYour downloaded Hugging Face datasets should be here:
datasets/
datasets--antareepdey--Hotdog-or-not-a-hotdog/
datasets--bghira--not-a-hotdog/
hotdog-nothotdog/
Prepare the best mixed dataset:
python prepare_data.py --overwrite
Prepare only from the local Hugging Face datasets, without downloading Food-101:
python prepare_data.py --overwrite --no-food101
Use all bghira hard negatives instead of the default quick subset:
python prepare_data.py --overwrite --no-food101 --max-bghira 0
Output:
dataset/train/hotdog
dataset/train/not_hotdog
dataset/val/hotdog
dataset/val/not_hotdog
Recommended: use the mixed dataset if you can download Food-101. Use local-only if you want the fastest setup with the datasets already downloaded.
python train.py --epochs 8 --batch 32
On macOS the default uses --num-workers 0 because it is the most stable option with local functions and Python multiprocessing.
If training on CPU, use a smaller batch:
python train.py --epochs 8 --batch 16
If pretrained MobileNetV3 weights cannot be downloaded, train from scratch:
python train.py --epochs 12 --batch 16 --no-pretrained
The model is saved to:
model/isHotdog.pt
Put images into:
photos/
Run:
python predict.py
Or run one image:
python predict.py path/to/image.jpg
Example output:
test.jpg: ✅ Hotdog confidence=94.20% hotdog_probability=94.20%
python app.py
The interface shows:
✅ Hotdog
or:
❌ Not Hotdog
Default threshold:
0.60
Meaning: isHotdog says Hotdog only if hotdog probability is at least 60%.
Use a stricter threshold for fewer false hotdogs:
python predict.py photo.jpg --threshold 0.75
dataset/, raw_data/, model/, runs/, or local photos.