Notifications
Clear all

Question Error when training model

3 Posts
2 Users
0 Likes
252 Views
(@ze-en)
New Member Member
Joined: 8 months ago
Posts: 2
Topic starter  

Hi, our group is trying to train the SenticGCN model and this is the error that our group has faced. 

AssertionError: Torch not compiled with CUDA enabled

May I know if there are any workarounds for this issue? Currently, our group members are not using any NVIDIA GPU so does that mean we are not able to train the model? Thanks!


   
Quote
Raymond Ng
(@raymond_aisg)
Eminent Member AISG Staff
Joined: 12 months ago
Posts: 35
 

Hi,

To train the SenticGCN model with CPU, please ensure that your PyTorch version supports CPU.

https://pytorch.org/

image

Next, in your SenticGCN training config file, change the `device` value to `cpu`, line 36 here,

https://github.com/aisingapore/sgnlp/blob/main/sgnlp/models/sentic_gcn/config/sentic_gcn_bert_config.json#L36

Next, run the training script again to start training.

 

Please note that training with CPU is generally not recommended as it is usually 10x~20x slower than training with GPU, depending on the size of the training data, the training could take hours or days to complete.

Hope this helps.

All things NLP


   
ReplyQuote
(@ze-en)
New Member Member
Joined: 8 months ago
Posts: 2
Topic starter  

Thank you for your prompt response!


   
ReplyQuote
Share: