MetaHIN icon indicating copy to clipboard operation
MetaHIN copied to clipboard

cur_training_u_movies variable not found in YelpProcessor.ipynb

Open joey-wang123 opened this issue 4 years ago • 3 comments

Hello,

       Thank you for your awesome work, I am using your scripts of YelpProcessor.ipynb to preprocess data. But it indicates that "cur_training_u_movies" not defined. Could you help me with it? Thank you!

joey-wang123 avatar Sep 26 '21 20:09 joey-wang123

Hello,

       Thank you for your awesome work, I am using your scripts of YelpProcessor.ipynb to preprocess data. But it indicates that "cur_training_u_movies" not defined. Could you help me with it? Thank you!

Have you solved the problem yet?I have the same problem.

linhongxiang avatar Jan 06 '22 12:01 linhongxiang

Hi, the last two code blocks are copied from elsewhere for referenc and can be commented out.

rootlu avatar Jan 08 '22 08:01 rootlu

Hi, I have the same problem outlined above. I have tried commenting out the last two block as suggested by @rootlu but then when I try to launch main.py on Yelp it fails with this message:

{'dataset': 'yelp', 'mp': ['ub', 'ubcb', 'ubtb', 'ubub'], 'use_cuda': True, 'file_num': 12, 'num_stars': 9, 'num_postalcode': 6127, 'num_fea_item': 2, 'item_fea_len': 2, 'num_fans': 412, 'num_avgrating': 359, 'num_fea_user': 2, 'embedding_dim': 32, 'user_embedding_dim': 64, 'item_embedding_dim': 64, 'first_fc_hidden_dim': 64, 'second_fc_hidden_dim': 64, 'mp_update': 1, 'local_update': 1, 'lr': 0.0005, 'mp_lr': 0.001, 'local_lr': 0.001, 'batch_size': 32, 'num_epoch': 50, 'neigh_agg': 'mean', 'mp_agg': 'mean'}
--------------- mp_update ---------------
loading train data...
0it [00:00, ?it/s]
#support set: 0, #query set: 0
training model...
Traceback (most recent call last):
  File "main.py", line 152, in <module>
    training(hml, model_save=True, model_file=model_filename,device=cuda_or_cpu)
  File "main.py", line 36, in training
    supp_xs_s, supp_ys_s, supp_mps_s, query_xs_s, query_ys_s, query_mps_s = zip(*train_data)  # supp_um_s:(list,list,...,2553)
ValueError: not enough values to unpack (expected 6, got 0)

So it seems that the processing script isn't producing any training or testing data. Do you have any suggestions?

Thank you in advance for your help.

DavideBuffelli avatar Sep 18 '22 07:09 DavideBuffelli