orion / app.py
andreslu's picture
Update app.py
c926a01
raw
history blame
330 Bytes
import gradio as gr
import torch
if torch.cuda.is_available():
device = torch.device("cuda")
print('GPU is available')
else:
device = torch.device("cpu")
print('GPU is not available')
def uppercase(text):
return text.upper()
iface = gr.Interface(fn=uppercase, inputs="text", outputs="text")
iface.launch()