aliabd HF staff commited on
Commit
3cceb56
1 Parent(s): 6804fec

Upload folder using huggingface_hub

Browse files
Files changed (3) hide show
  1. requirements.txt +1 -1
  2. run.ipynb +1 -1
  3. run.py +1 -3
requirements.txt CHANGED
@@ -1,2 +1,2 @@
1
  vega_datasets
2
- https://gradio-main-build.s3.amazonaws.com/2883a12c1fe643ff0b6c9077786548529f7a9abb/gradio-3.36.0-py3-none-any.whl
 
1
  vega_datasets
2
+ https://gradio-main-build.s3.amazonaws.com/b4173886bab24d47bef9936a96801ce6ac6aba0e/gradio-3.36.0-py3-none-any.whl
run.ipynb CHANGED
@@ -1 +1 @@
1
- {"cells": [{"cell_type": "markdown", "id": 302934307671667531413257853548643485645, "metadata": {}, "source": ["# Gradio Demo: scatterplot_component"]}, {"cell_type": "code", "execution_count": null, "id": 272996653310673477252411125948039410165, "metadata": {}, "outputs": [], "source": ["!pip install -q gradio vega_datasets"]}, {"cell_type": "code", "execution_count": null, "id": 288918539441861185822528903084949547379, "metadata": {}, "outputs": [], "source": ["import gradio as gr\n", "from vega_datasets import data\n", "\n", "cars = data.cars()\n", "\n", "css = \"footer {display: none !important;} .gradio-container {min-height: 0px !important;}\"\n", "\n", "with gr.Blocks(css=css) as demo:\n", " gr.ScatterPlot(show_label=False,\n", " value=cars,\n", " x=\"Horsepower\",\n", " y=\"Miles_per_Gallon\",\n", " color=\"Origin\",\n", " tooltip=\"Name\",\n", " title=\"Car Data\",\n", " y_title=\"Miles per Gallon\",\n", " color_legend_title=\"Origin of Car\").style(container=False)\n", "\n", "if __name__ == \"__main__\":\n", " demo.launch()"]}], "metadata": {}, "nbformat": 4, "nbformat_minor": 5}
 
1
+ {"cells": [{"cell_type": "markdown", "id": 302934307671667531413257853548643485645, "metadata": {}, "source": ["# Gradio Demo: scatterplot_component"]}, {"cell_type": "code", "execution_count": null, "id": 272996653310673477252411125948039410165, "metadata": {}, "outputs": [], "source": ["!pip install -q gradio vega_datasets"]}, {"cell_type": "code", "execution_count": null, "id": 288918539441861185822528903084949547379, "metadata": {}, "outputs": [], "source": ["import gradio as gr\n", "from vega_datasets import data\n", "\n", "cars = data.cars()\n", "\n", "with gr.Blocks() as demo:\n", " gr.ScatterPlot(show_label=False,\n", " value=cars,\n", " x=\"Horsepower\",\n", " y=\"Miles_per_Gallon\",\n", " color=\"Origin\",\n", " tooltip=\"Name\",\n", " title=\"Car Data\",\n", " y_title=\"Miles per Gallon\",\n", " color_legend_title=\"Origin of Car\").style(container=False)\n", "\n", "if __name__ == \"__main__\":\n", " demo.launch()"]}], "metadata": {}, "nbformat": 4, "nbformat_minor": 5}
run.py CHANGED
@@ -3,9 +3,7 @@ from vega_datasets import data
3
 
4
  cars = data.cars()
5
 
6
- css = "footer {display: none !important;} .gradio-container {min-height: 0px !important;}"
7
-
8
- with gr.Blocks(css=css) as demo:
9
  gr.ScatterPlot(show_label=False,
10
  value=cars,
11
  x="Horsepower",
 
3
 
4
  cars = data.cars()
5
 
6
+ with gr.Blocks() as demo:
 
 
7
  gr.ScatterPlot(show_label=False,
8
  value=cars,
9
  x="Horsepower",