File size: 427 Bytes
98acb70
 
 
 
 
 
 
 
 
 
 
 
 
1
2
3
4
5
6
7
8
9
10
11
12
13
14
"""Optional free ZeroGPU hosting; CPU/Docker entry points stay independent."""
import spaces
from space.models import tiny_weights
from space.runtime import run_experiment

# ZeroGPU emulates CUDA placement during startup, then materializes these
# same tensors when a decorated function obtains a GPU.
tiny_weights('cuda')


@spaces.GPU(duration=120)
def run_tiny(**kwargs):
    return run_experiment(**kwargs, device='cuda')