Spaces:
Sleeping
Sleeping
import gradio as gr | |
import spaces | |
import torch | |
tensor = torch.zeros(3).cuda() | |
print(tensor.device) | |
def greet(name): | |
print(tensor.device) | |
return "Hello pixi pablo " + name + "!!" | |
demo = gr.Interface(fn=greet, inputs="text", outputs="text") | |
demo.launch() |