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
I can reproduce the Baselines without error, however RuntimeError appeared when I ran the HIST model. I have set all the package to the according version as mentioned in the requirements.txt. But error keeps appearing when it starts training.
[2022-02-17 11:43:15] - Running 0 Epoch: 0
[2022-02-17 11:43:15] - training...
0%|
[2364:MainThread](2022-02-17 11:43:15,750) ERROR - qlib.workflow - [utils.py:38] - An exception has been raised[RuntimeError: Device index must not be negative].
File "learn.py", line 450, in
main(args)
File "learn.py", line 288, in main
train_epoch(epoch, model, optimizer, train_loader, writer, args, stock2concept_matrix)
File "learn.py", line 116, in train_epoch
pred = model(feature, stock2concept_matrix[stock_index], market_value)
File "D:\anaconda3\envs\qlib\lib\site-packages\torch\nn\modules\module.py", line 889, in _call_impl
result = self.forward(*input, **kwargs)
File "D:\Codes\HIST\model.py", line 79, in forward
device = torch.device(torch.get_device(x+1))
RuntimeError: Device index must not be negative
I wonder why it is the case and how can I fix it? Thank you for your time!
请问应该怎么解决这一问题呢?谢谢!
The text was updated successfully, but these errors were encountered:
Dear author @Wentao-Xu ,
I can reproduce the Baselines without error, however
RuntimeError
appeared when I ran the HIST model. I have set all the package to the according version as mentioned in therequirements.txt
. But error keeps appearing when it starts training.我可以复现Baselines的模型,但是在跑HIST的时候会出现
RuntimeError
报错。我已经把要求的库都降级到相应的版本,但是仍然出现如下报错。I wonder why it is the case and how can I fix it? Thank you for your time!
请问应该怎么解决这一问题呢?谢谢!
The text was updated successfully, but these errors were encountered: