Upload folder using huggingface_hub
Browse files
run.ipynb
CHANGED
@@ -1 +1 @@
|
|
1 |
-
{"cells": [{"cell_type": "markdown", "id": "302934307671667531413257853548643485645", "metadata": {}, "source": ["# Gradio Demo: webcam"]}, {"cell_type": "code", "execution_count": null, "id": "272996653310673477252411125948039410165", "metadata": {}, "outputs": [], "source": ["!pip install -q gradio "]}, {"cell_type": "code", "execution_count": null, "id": "288918539441861185822528903084949547379", "metadata": {}, "outputs": [], "source": ["\n", "import gradio as gr\n", "\n", "
|
|
|
1 |
+
{"cells": [{"cell_type": "markdown", "id": "302934307671667531413257853548643485645", "metadata": {}, "source": ["# Gradio Demo: webcam"]}, {"cell_type": "code", "execution_count": null, "id": "272996653310673477252411125948039410165", "metadata": {}, "outputs": [], "source": ["!pip install -q gradio "]}, {"cell_type": "code", "execution_count": null, "id": "288918539441861185822528903084949547379", "metadata": {}, "outputs": [], "source": ["\n", "import gradio as gr\n", "\n", "def snap(image, video):\n", " return [image, video]\n", "\n", "demo = gr.Interface(\n", " snap,\n", " [gr.Image(sources=[\"webcam\"]), gr.Video(sources=[\"webcam\"])],\n", " [\"image\", \"video\"],\n", ")\n", "\n", "if __name__ == \"__main__\":\n", " demo.launch()\n"]}], "metadata": {}, "nbformat": 4, "nbformat_minor": 5}
|
run.py
CHANGED
@@ -1,11 +1,9 @@
|
|
1 |
|
2 |
import gradio as gr
|
3 |
|
4 |
-
|
5 |
def snap(image, video):
|
6 |
return [image, video]
|
7 |
|
8 |
-
|
9 |
demo = gr.Interface(
|
10 |
snap,
|
11 |
[gr.Image(sources=["webcam"]), gr.Video(sources=["webcam"])],
|
|
|
1 |
|
2 |
import gradio as gr
|
3 |
|
|
|
4 |
def snap(image, video):
|
5 |
return [image, video]
|
6 |
|
|
|
7 |
demo = gr.Interface(
|
8 |
snap,
|
9 |
[gr.Image(sources=["webcam"]), gr.Video(sources=["webcam"])],
|