본문 바로가기
인공지능

How to Use Gradio

by YJHTPII 2024. 12. 9.
반응형

 

Building Your First Demo

You can run Gradio in your favorite code editor, Jupyter notebook, Google Colab, or anywhere else you write Python. Let's write your first Gradio app:

pip install gradio

 

import gradio as gr

def greet(name, intensity):
    return "Hello, " + name + "!" * int(intensity)

demo = gr.Interface(
    fn=greet,
    inputs=["text", "slider"],
    outputs=["text"],
)

demo.launch()

 

 

 

 

https://www.gradio.app/guides/quickstart#building-your-first-demo

 

Quickstart

A Step-by-Step Gradio Tutorial

www.gradio.app

 

 

반응형

댓글