Skip to content

RuntimeError: torch.cuda.FloatTensor is not enabled. #380

@irazakharchenko

Description

@irazakharchenko

run code this way for imagenet:
python main.py -a alexnet --lr 0.01 [path]

Gets:
=> creating model 'alexnet'
Traceback (most recent call last):
File "main.py", line 314, in
main()
File "main.py", line 84, in main
model.cuda()
File "/mnt/home.stud/zakhairy/myPy/local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 249, in cuda
return self._apply(lambda t: t.cuda(device))
File "/mnt/home.stud/zakhairy/myPy/local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 176, in _apply
module._apply(fn)
File "/mnt/home.stud/zakhairy/myPy/local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 176, in _apply
module._apply(fn)
File "/mnt/home.stud/zakhairy/myPy/local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 176, in _apply
module._apply(fn)
File "/mnt/home.stud/zakhairy/myPy/local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 182, in _apply
param.data = fn(param.data)
File "/mnt/home.stud/zakhairy/myPy/local/lib/python2.7/site-packages/torch/nn/modules/module.py", line 249, in
return self._apply(lambda t: t.cuda(device))
RuntimeError: torch.cuda.FloatTensor is not enabled.

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

    Milestone

    No milestone

    Relationships

    None yet

    Development

    No branches or pull requests

    Issue actions