Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

too many indices for array #22

Open
khadkarajesh opened this issue Jan 23, 2022 · 2 comments
Open

too many indices for array #22

khadkarajesh opened this issue Jan 23, 2022 · 2 comments

Comments

@khadkarajesh
Copy link

I was trying to run the code on amazon-book data for few epoch. I got the error mentioned below.

Used Command

python LightGCN.py --dataset amazon-book --regs \[1e-4\] --embed_size 64 --layer_size \[64,64,64\] --lr 0.001 --batch_size 8192 --epoch 10

Error

Traceback (most recent call last):
  File "/Users/rajeshkhadka/PycharmProjects/LightGCN_v2/LightGCN.py", line 714, in <module>
    best_rec_0 = max(recs[:, 0])
IndexError: too many indices for array: array is 1-dimensional, but 2 were indexed
@huzuoliang
Copy link

got the same error like you, have you saved the problem?

@huzuoliang
Copy link

I find the reason
just because when the epoch<20, it will not excute test method,so rec is []
image

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

No branches or pull requests

2 participants