Traceback (most recent call last):
File "./test_pytorch.sh", line 7, in <module>
matrix1 = torch.tensor([[1.0, 2.0], [3.0, 4.0]], device=device)
RuntimeError: CUDA error: out of memory
[AVHWDeviceContext @ 0x38d4b00] cu->cuCtxCreate(&hwctx->cuda_ctx, 4, cu_device) failed -> CUDA_ERROR_OUT_OF_MEMORY: out of memory
[h264_cuvid @ 0x3725c00] Error creating a CUDA device
cuvid hwaccel requested for input stream #:1, but cannot be initialized.
[h264_cuvid @ 0x3725c00] ff_get_format failed: -1
然后又使用pytorch做了简单的矩阵乘法运算,也是报错:
Traceback (most recent call last):
File "./test_pytorch.sh", line 7, in <module>
matrix1 = torch.tensor([[1.0, 2.0], [3.0, 4.0]], device=device)
RuntimeError: CUDA error: out of memory