DataFrameTest / app.py
Krebzonide's picture
Update app.py
7bee06a verified
raw
history blame
385 Bytes
import gradio as gr
def pri(df):
print(len(df))
for i in range(len(df)):
print(df[i])
for item in df:
print(item)
with gr.Blocks() as demo:
df = gr.Dataframe(
headers=["name"],
datatype=["str"],
row_count=(4, "fixed"),
col_count=(1, "fixed"))
btn = gr.Button()
btn.click(pri, df)
demo.launch()