Spaces:
Running on Zero
Running on Zero
Download test_gradio.py from prateeksharmacoder/satellite: direct link, hf CLI and curl.
- Browser
- Download file 268 Bytes
-
https://huggingface.co/spaces/prateeksharmacoder/satellite/resolve/main/test_gradio.py
- Command line
-
hf download hf://spaces/prateeksharmacoder/satellite/test_gradio.py
-
curl -L -o test_gradio.py https://huggingface.co/spaces/prateeksharmacoder/satellite/resolve/main/test_gradio.py
268 Bytes
| import gradio as gr | |
| import shutil | |
| def test_fn(img_path): | |
| print("Received path:", img_path) | |
| return img_path | |
| demo = gr.Interface(fn=test_fn, inputs=gr.Image(type="filepath"), outputs="text") | |
| if __name__ == "__main__": | |
| demo.launch(prevent_thread_lock=True) | |