Code
Hub
Workspaces
Following
Trending
Connect
MCP
copy
Create free account
hub
/
github.com/NVIDIA/FasterTransformer
/ cuda
Method
cuda
examples/pytorch/gpt/utils/gpt_decoder.py:361–364 ·
view source on GitHub ↗
(self, device=None)
Source
from the content-addressed store, hash-verified
359
return
self.weight.device
360
361
def
cuda(self, device=None):
362
assert torch.cuda.is_available()
363
self.weight.cuda(device)
364
return
self
365
366
def
to(self, device=None):
367
self.weight.to(device)
Callers
nothing calls this directly
Calls
1
cuda
Method · 0.45
Tested by
no test coverage detected