yuetan031/TADDY_pytorch

ValueError: row index exceeds matrix dimensions

Opened this issue · 3 comments

File "C:\Users\16645\Desktop\代码\Anomaly Detection in Dynamic Graphs via\1_train.py", line 56, in
setting_obj.run()
File "C:\Users\16645\Desktop\代码\Anomaly Detection in Dynamic Graphs via\codes\Settings.py", line 8, in run
loaded_data = self.dataset.load()
File "C:\Users\16645\Desktop\代码\Anomaly Detection in Dynamic Graphs via\codes\DynamicDatasetLoader.py", line 173, in load
adjs, eigen_adjs = self.get_adjs(rows, cols, weights, nb_nodes)
File "C:\Users\16645\Desktop\代码\Anomaly Detection in Dynamic Graphs via\codes\DynamicDatasetLoader.py", line 142, in get_adjs
adj = sp.csr_matrix((weights[i], (rows[i], cols[i])), shape=(nb_nodes, nb_nodes), dtype=np.float32)
File "C:\aconda\envs\python38\lib\site-packages\scipy\sparse\compressed.py", line 54, in init
other = self.class(coo_matrix(arg1, shape=shape))
File "C:\aconda\envs\python38\lib\site-packages\scipy\sparse\coo.py", line 196, in init
self._check()
File "C:\aconda\envs\python38\lib\site-packages\scipy\sparse\coo.py", line 283, in _check
raise ValueError('row index exceeds matrix dimensions')

换一台有gpu的机器跑就ok了

请问这个问题解决了吗?我电脑有GPU还是报错。

My dataframe index was using DatetimeIndex, so resetting this fixed the issue for me.