Spaces:
Runtime error
Runtime error
| { | |
| "model": { | |
| "name": "indian_food_prediction", | |
| "base_model": "google/vit-base-patch16-224-in21k", | |
| "fine_tuning_checkpoint": "aishrica/indian_food_prediction", | |
| "published_as": "aishrica/indian_food_prediction", | |
| "architecture": "Vision Transformer (ViT-Base, patch 16, 224x224)", | |
| "framework": "PyTorch + HuggingFace Transformers", | |
| "trainable_params_millions": 85.86, | |
| "weights_size_mb": 343, | |
| "input": "RGB image -> 224x224, normalised -> tensor [3, 224, 224]", | |
| "output": "80-class logits -> softmax probabilities (argmax = dish)" | |
| }, | |
| "dataset": { | |
| "source": "Kaggle - Indian Food Images Dataset", | |
| "total_images": 4000, | |
| "classes": 80, | |
| "per_class": 50, | |
| "train_images": 2400, | |
| "test_images": 1600, | |
| "split": "60 / 40 stratified, shuffled", | |
| "balanced": true | |
| }, | |
| "augmentations": [ | |
| "Resize 224x224", | |
| "RandomRotation(90)", | |
| "RandomAdjustSharpness(2)", | |
| "RandomHorizontalFlip(0.5)", | |
| "Normalize (ViT mean/std)" | |
| ], | |
| "hyperparameters": { | |
| "epochs": 20, | |
| "learning_rate": "1e-6", | |
| "train_batch_size": 64, | |
| "eval_batch_size": 32, | |
| "weight_decay": 0.02, | |
| "warmup_steps": 50, | |
| "optimizer_steps": 760, | |
| "runtime_min": 31 | |
| }, | |
| "metrics": { | |
| "accuracy": 0.7519, | |
| "macro_f1": 0.7352, | |
| "macro_precision": 0.7813, | |
| "macro_recall": 0.7519, | |
| "baseline_accuracy": 0.7494, | |
| "test_loss": 3.1539 | |
| }, | |
| "pipeline": [ | |
| { | |
| "step": "Dataset", | |
| "detail": "4,000 photos - 80 dishes" | |
| }, | |
| { | |
| "step": "Preprocess", | |
| "detail": "oversample - cast Image/ClassLabel" | |
| }, | |
| { | |
| "step": "Augment", | |
| "detail": "resize - rotate - flip - sharpen - normalise" | |
| }, | |
| { | |
| "step": "ViT Encoder", | |
| "detail": "ViT-Base patch16 - 85.9M params" | |
| }, | |
| { | |
| "step": "Classifier Head", | |
| "detail": "80-class linear layer" | |
| }, | |
| { | |
| "step": "Prediction", | |
| "detail": "top-3 dishes + confidence" | |
| }, | |
| { | |
| "step": "Calorie DB", | |
| "detail": "label -> calories & category" | |
| } | |
| ], | |
| "limitations": [ | |
| "Confidence scores are poorly calibrated (softmax is very flat, top score ~0.04).", | |
| "No separate held-out test set - the 40% split is used for both validation and test.", | |
| "Marginal fine-tuning effect (74.9% -> 75.2%) due to a near-converged base and lr=1e-6.", | |
| "Visually similar dishes (curries, milk-based sweets) are frequently confused.", | |
| "Small dataset (50 images/class) limits real-world generalisation.", | |
| "Single-dish assumption - no food segmentation or multi-item plate detection yet." | |
| ], | |
| "per_class": [ | |
| { | |
| "label": "adhirasam", | |
| "precision": 0.9412, | |
| "recall": 0.8, | |
| "f1": 0.8649, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "aloo_gobi", | |
| "precision": 0.7857, | |
| "recall": 0.55, | |
| "f1": 0.6471, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "aloo_matar", | |
| "precision": 0.85, | |
| "recall": 0.85, | |
| "f1": 0.85, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "aloo_methi", | |
| "precision": 0.7407, | |
| "recall": 1.0, | |
| "f1": 0.8511, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "aloo_shimla_mirch", | |
| "precision": 0.7619, | |
| "recall": 0.8, | |
| "f1": 0.7805, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "aloo_tikki", | |
| "precision": 1.0, | |
| "recall": 0.75, | |
| "f1": 0.8571, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "anarsa", | |
| "precision": 1.0, | |
| "recall": 0.7, | |
| "f1": 0.8235, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "ariselu", | |
| "precision": 0.7692, | |
| "recall": 1.0, | |
| "f1": 0.8696, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "bandar_laddu", | |
| "precision": 0.8333, | |
| "recall": 0.75, | |
| "f1": 0.7895, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "basundi", | |
| "precision": 0.2254, | |
| "recall": 0.8, | |
| "f1": 0.3516, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "bhatura", | |
| "precision": 0.76, | |
| "recall": 0.95, | |
| "f1": 0.8444, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "bhindi_masala", | |
| "precision": 0.8636, | |
| "recall": 0.95, | |
| "f1": 0.9048, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "biryani", | |
| "precision": 0.8571, | |
| "recall": 0.9, | |
| "f1": 0.878, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "boondi", | |
| "precision": 0.9474, | |
| "recall": 0.9, | |
| "f1": 0.9231, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "butter_chicken", | |
| "precision": 0.4419, | |
| "recall": 0.95, | |
| "f1": 0.6032, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "chak_hao_kheer", | |
| "precision": 0.9474, | |
| "recall": 0.9, | |
| "f1": 0.9231, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "cham_cham", | |
| "precision": 1.0, | |
| "recall": 0.4, | |
| "f1": 0.5714, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "chana_masala", | |
| "precision": 0.7692, | |
| "recall": 1.0, | |
| "f1": 0.8696, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "chapati", | |
| "precision": 0.7407, | |
| "recall": 1.0, | |
| "f1": 0.8511, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "chhena_kheeri", | |
| "precision": 0.0, | |
| "recall": 0.0, | |
| "f1": 0.0, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "chicken_razala", | |
| "precision": 0.8, | |
| "recall": 1.0, | |
| "f1": 0.8889, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "chicken_tikka", | |
| "precision": 0.9091, | |
| "recall": 0.5, | |
| "f1": 0.6452, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "chicken_tikka_masala", | |
| "precision": 0.7273, | |
| "recall": 0.4, | |
| "f1": 0.5161, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "chikki", | |
| "precision": 0.7308, | |
| "recall": 0.95, | |
| "f1": 0.8261, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "daal_baati_churma", | |
| "precision": 0.6957, | |
| "recall": 0.8, | |
| "f1": 0.7442, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "daal_puri", | |
| "precision": 1.0, | |
| "recall": 0.3, | |
| "f1": 0.4615, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "dal_makhani", | |
| "precision": 0.8182, | |
| "recall": 0.9, | |
| "f1": 0.8571, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "dal_tadka", | |
| "precision": 0.6552, | |
| "recall": 0.95, | |
| "f1": 0.7755, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "dharwad_pedha", | |
| "precision": 1.0, | |
| "recall": 0.8, | |
| "f1": 0.8889, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "doodhpak", | |
| "precision": 0.6667, | |
| "recall": 0.1, | |
| "f1": 0.1739, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "double_ka_meetha", | |
| "precision": 0.7917, | |
| "recall": 0.95, | |
| "f1": 0.8636, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "dum_aloo", | |
| "precision": 0.8462, | |
| "recall": 0.55, | |
| "f1": 0.6667, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "gajar_ka_halwa", | |
| "precision": 0.8, | |
| "recall": 1.0, | |
| "f1": 0.8889, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "gavvalu", | |
| "precision": 0.8095, | |
| "recall": 0.85, | |
| "f1": 0.8293, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "ghevar", | |
| "precision": 1.0, | |
| "recall": 0.8, | |
| "f1": 0.8889, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "gulab_jamun", | |
| "precision": 0.5429, | |
| "recall": 0.95, | |
| "f1": 0.6909, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "imarti", | |
| "precision": 0.8333, | |
| "recall": 1.0, | |
| "f1": 0.9091, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "jalebi", | |
| "precision": 0.9474, | |
| "recall": 0.9, | |
| "f1": 0.9231, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "kachori", | |
| "precision": 0.6364, | |
| "recall": 0.7, | |
| "f1": 0.6667, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "kadai_paneer", | |
| "precision": 0.6923, | |
| "recall": 0.9, | |
| "f1": 0.7826, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "kadhi_pakoda", | |
| "precision": 0.85, | |
| "recall": 0.85, | |
| "f1": 0.85, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "kajjikaya", | |
| "precision": 0.9412, | |
| "recall": 0.8, | |
| "f1": 0.8649, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "kakinada_khaja", | |
| "precision": 0.8824, | |
| "recall": 0.75, | |
| "f1": 0.8108, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "kalakand", | |
| "precision": 0.7692, | |
| "recall": 0.5, | |
| "f1": 0.6061, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "karela_bharta", | |
| "precision": 1.0, | |
| "recall": 0.2, | |
| "f1": 0.3333, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "kofta", | |
| "precision": 0.9333, | |
| "recall": 0.7, | |
| "f1": 0.8, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "kuzhi_paniyaram", | |
| "precision": 0.6667, | |
| "recall": 0.9, | |
| "f1": 0.766, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "lassi", | |
| "precision": 0.8, | |
| "recall": 1.0, | |
| "f1": 0.8889, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "ledikeni", | |
| "precision": 0.5714, | |
| "recall": 0.2, | |
| "f1": 0.2963, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "litti_chokha", | |
| "precision": 1.0, | |
| "recall": 0.8, | |
| "f1": 0.8889, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "lyangcha", | |
| "precision": 0.8947, | |
| "recall": 0.85, | |
| "f1": 0.8718, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "maach_jhol", | |
| "precision": 0.9375, | |
| "recall": 0.75, | |
| "f1": 0.8333, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "makki_di_roti_sarson_da_saag", | |
| "precision": 1.0, | |
| "recall": 0.85, | |
| "f1": 0.9189, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "malapua", | |
| "precision": 1.0, | |
| "recall": 0.7, | |
| "f1": 0.8235, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "misi_roti", | |
| "precision": 0.8571, | |
| "recall": 0.9, | |
| "f1": 0.878, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "misti_doi", | |
| "precision": 0.6364, | |
| "recall": 0.7, | |
| "f1": 0.6667, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "modak", | |
| "precision": 0.7826, | |
| "recall": 0.9, | |
| "f1": 0.8372, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "mysore_pak", | |
| "precision": 0.7917, | |
| "recall": 0.95, | |
| "f1": 0.8636, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "naan", | |
| "precision": 0.9091, | |
| "recall": 1.0, | |
| "f1": 0.9524, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "navrattan_korma", | |
| "precision": 0.9286, | |
| "recall": 0.65, | |
| "f1": 0.7647, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "palak_paneer", | |
| "precision": 0.7917, | |
| "recall": 0.95, | |
| "f1": 0.8636, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "paneer_butter_masala", | |
| "precision": 0.6667, | |
| "recall": 0.7, | |
| "f1": 0.6829, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "phirni", | |
| "precision": 0.55, | |
| "recall": 0.55, | |
| "f1": 0.55, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "pithe", | |
| "precision": 1.0, | |
| "recall": 0.25, | |
| "f1": 0.4, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "poha", | |
| "precision": 0.6786, | |
| "recall": 0.95, | |
| "f1": 0.7917, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "poornalu", | |
| "precision": 0.9, | |
| "recall": 0.9, | |
| "f1": 0.9, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "pootharekulu", | |
| "precision": 0.8636, | |
| "recall": 0.95, | |
| "f1": 0.9048, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "qubani_ka_meetha", | |
| "precision": 1.0, | |
| "recall": 0.65, | |
| "f1": 0.7879, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "rabri", | |
| "precision": 0.0, | |
| "recall": 0.0, | |
| "f1": 0.0, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "ras_malai", | |
| "precision": 0.7083, | |
| "recall": 0.85, | |
| "f1": 0.7727, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "rasgulla", | |
| "precision": 0.5263, | |
| "recall": 1.0, | |
| "f1": 0.6897, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "sandesh", | |
| "precision": 0.6, | |
| "recall": 0.15, | |
| "f1": 0.24, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "shankarpali", | |
| "precision": 0.8333, | |
| "recall": 1.0, | |
| "f1": 0.9091, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "sheer_korma", | |
| "precision": 0.4643, | |
| "recall": 0.65, | |
| "f1": 0.5417, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "sheera", | |
| "precision": 0.8667, | |
| "recall": 0.65, | |
| "f1": 0.7429, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "shrikhand", | |
| "precision": 0.8, | |
| "recall": 0.6, | |
| "f1": 0.6857, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "sohan_halwa", | |
| "precision": 1.0, | |
| "recall": 0.5, | |
| "f1": 0.6667, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "sohan_papdi", | |
| "precision": 0.5556, | |
| "recall": 1.0, | |
| "f1": 0.7143, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "sutar_feni", | |
| "precision": 0.8571, | |
| "recall": 0.9, | |
| "f1": 0.878, | |
| "support": 20 | |
| }, | |
| { | |
| "label": "unni_appam", | |
| "precision": 0.5556, | |
| "recall": 0.75, | |
| "f1": 0.6383, | |
| "support": 20 | |
| } | |
| ] | |
| } | |