This message was deleted.
# ask-for-help
s
This message was deleted.
👀 1
l
Hi Bharath, if the GPU is available then it will be used by the runner automatically
b
@larme (shenyang) its throwing runtime error as below
Copy code
RuntimeError: Expected all tensors to be on the same device, but found at least two devices, cpu and cuda:0! (when 
checking argument for argument index in method wrapper_CUDA__index_select)
_input is
Copy code
{'input_ids': tensor([[   259,  74606, 207850,  74295]], device='cuda:0'), 'attention_mask': tensor([[1, 1, 1, 1]], device='cuda:0')}
which is using cuda but model_runner is not using cuda.
l
i Bharath, could you post your service.py? If you are using
bentoml.transformers
it should automatically lift tensor to cuda. Your error message means some tensor are lifted to cuda but some are not. Very strange behavior.