Open mmaashraf opened 1 year ago
It seems that the script can't detect your GPU so that args.n_gpu = 0. Please check whether your GPU works.
GPU is active. Also, does it refer to the GPU cores? or the GPU itself? Can it be hard-coded in the script? or what is the workaround?
No, it cannot be hard-coded. You can try using the Python code torch.cuda.is_available()
to check if your torch library supports GPU. If it doesn't, you will need to investigate the issues and find solutions.
Is possible to run using just CPU? this torch.cuda.is_available() returns False. any of the 4 downstream tasks? related to GraphCodeBERT
If you want to use CPU, you can change args.n_gpu =1
in https://github.com/microsoft/CodeBERT/blob/03631d3d718fd816aeee49f7de9340f773807fa1/GraphCodeBERT/codesearch/run.py#L464
Other downstream tasks are the same.
Hi,
I am on an M1 Mac Pro, I am trying to run the step "Fine-Tune" by executing the script run.py mentioned in https://github.com/microsoft/CodeBERT/tree/master/GraphCodeBERT/codesearch .
As per apple, the device has 10-core CPU and 16-core GPU.
However, I am getting an error
What could be the fix?
Thanks!