Spaces:
Sleeping
Sleeping
| title: Image Captioner | |
| emoji: 🖼️ | |
| colorFrom: indigo | |
| colorTo: blue | |
| sdk: gradio | |
| app_file: app.py | |
| pinned: false | |
| license: mit | |
| # 🖼️ Image Captioner | |
| A lightweight, CPU-friendly image captioning demo built with 🤗 Transformers + Gradio. | |
| Upload an image and the model will generate a concise caption. | |
| We provide a few test images in `samples/`. | |
| Run: | |
| ```bash | |
| # from project root (with venv active) | |
| python -m image_captioner.scripts.run_batch --dir image_captioner/samples --jsonl-out captions.jsonl --csv-out captions.csv | |
| ``` | |
| You’ll see progress like: | |
| [1/2] living_room.jpg -> a living room with a couch and chairs | |
| [2/2] street.jpg -> a busy street with cars and pedestrians | |
| Outputs: | |
| • captions.jsonl → one JSON record per image | |
| • captions.csv → tabular view (image, caption, elapsed time) | |
| --- |