File size: 1,077 Bytes
da019cd 7d72a3c da019cd 7d72a3c da019cd 7d72a3c da019cd 7d72a3c da019cd 7d72a3c da019cd 7d72a3c da019cd |
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 |
import gradio as gr
import matplotlib
#matplotlib.use("Agg")
import matplotlib.pyplot as plt
# import numpy as np
# import plotly.express as px
# import pandas as pd
def outbreak(plot_type, r, month, countries, social_distancing):
return " 145 Fcfa/ for 2Kg"
inputs = [
gr.Dropdown(["Matplotlib", "Plotly", "Altair"], label="Plot Type"),
gr.Dropdown(["January", "February", "March", "April", "May"], label="Month"),
gr.Dropdown(["January", "February", "March", "April", "May"], label="Month"),
gr.Dropdown(["January", "February", "March", "April", "May"], label="Month"),
gr.Dropdown(["January", "February", "March", "April", "May"], label="Month"),
]
outputs = "label"
demo = gr.Interface(
fn=outbreak,
inputs=inputs,
outputs=outputs,
# examples=[
# ["Matplotlib", 2, "March", ["Mexico", "UK"], True],
# ["Altair", 2, "March", ["Mexico", "Canada"], True],
# ["Plotly", 3.6, "February", ["Canada", "Mexico", "UK"], False],
# ],
cache_examples=True,
)
if __name__ == "__main__":
demo.launch()
|