You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
If I set the code to run with cpu instead of gpu, I get the above error.
This happens because in train function of FewShotNERFramework in framework.py, label is only defined if torch.cuda.isavailable is true. So then there is an assert statement a few lines later that is outside of that if block which uses label, that is assert logits.shape[0] == label.shape[0], print(logits.shape, label.shape). But further lines also depend upon label being present.
I get a RuntimeError: CUDA error: out of memory should I try to run with the GPU.
The else case for cuda not available should be dealt with better other than this assert statement in my opinon even if running this code with cpu would not be supported.
The text was updated successfully, but these errors were encountered:
If I set the code to run with cpu instead of gpu, I get the above error.
This happens because in train function of FewShotNERFramework in framework.py, label is only defined if
torch.cuda.isavailable
is true. So then there is an assert statement a few lines later that is outside of that if block which uses label, that isassert logits.shape[0] == label.shape[0], print(logits.shape, label.shape)
. But further lines also depend upon label being present.I get a
RuntimeError: CUDA error: out of memory
should I try to run with the GPU.The else case for cuda not available should be dealt with better other than this assert statement in my opinon even if running this code with cpu would not be supported.
The text was updated successfully, but these errors were encountered: