Spaces:
No application file
No application file
Commit History
-
Upload csvjson.json
Verified signatureimport gradio as gr import json from PIL import Image # Load JSON images with open("images.json") as f: data = json.load(f) # Dummy similarity search (for example purpose) def search_image(uploaded_image): # In real setup, compute embeddings + compare with JSON top_results = data[:5] # top 5 results (placeholder) return [d["url"] for d in top_results] # Gradio Interface demo = gr.Interface( fn=search_image, inputs=gr.Image(type="pil"), outputs=gr.Gallery(label="Top Matching Images") ) demo.launch()cbe3461