mirror of
https://github.com/gradio-app/gradio.git
synced 2024-12-21 02:19:59 +08:00
13 lines
245 B
Python
13 lines
245 B
Python
import gradio as gr
|
|
import numpy as np
|
|
import random
|
|
|
|
def transpose(matrix):
|
|
print(matrix)
|
|
return matrix.T
|
|
|
|
gr.Interface(transpose,
|
|
gr.inputs.Dataframe(type="numpy", datatype="number", row_count=5, col_count=3),
|
|
"numpy"
|
|
).launch()
|