P-GNN icon indicating copy to clipboard operation
P-GNN copied to clipboard

AttributeError: 'Data' object has no attribute 'mask_link_positive'

Open mtli77 opened this issue 4 years ago • 4 comments

Hi, @JiaxuanYou Thanks for sharing your code! When I run the scripts according to the README.md, some errors occurs: -----------------Final------------------- 0.73879 0.014555 Loading data... Using only features.. Traceback (most recent call last): File "main.py", line 51, in <module> data_list = get_tg_dataset(args, dataset_name, use_cache=args.cache, remove_feature=args.rm_feature) File "/disk/P-GNN/dataset.py", line 93, in get_tg_dataset infer_link_positive=True if args.task == 'link' else False) File "/disk/P-GNN/utils.py", line 120, in get_link_mask split_edges(data.mask_link_positive, remove_ratio) AttributeError: 'Data' object has no attribute 'mask_link_positive'

It seems that there is something trouble with the input graph data. Could you help to solve this problem? And give some further introduction for the input data of the project?

Thank you very much! Waiting for your reply!

mtli77 avatar Dec 10 '19 07:12 mtli77

same error here

qiuhaolu avatar Dec 13 '19 06:12 qiuhaolu

same error here

yhcc avatar Dec 18 '19 10:12 yhcc

Facing the same issue here.

Abhyuday99 avatar Feb 26 '20 12:02 Abhyuday99

Hi, @JiaxuanYou Thanks for sharing your code! When I run the scripts according to the README.md, some errors occurs: -----------------Final------------------- 0.73879 0.014555 Loading data... Using only features.. Traceback (most recent call last): File "main.py", line 51, in <module> data_list = get_tg_dataset(args, dataset_name, use_cache=args.cache, remove_feature=args.rm_feature) File "/disk/P-GNN/dataset.py", line 93, in get_tg_dataset infer_link_positive=True if args.task == 'link' else False) File "/disk/P-GNN/utils.py", line 120, in get_link_mask split_edges(data.mask_link_positive, remove_ratio) AttributeError: 'Data' object has no attribute 'mask_link_positive'

It seems that there is something trouble with the input graph data. Could you help to solve this problem? And give some further introduction for the input data of the project?

Thank you very much! Waiting for your reply!

Grid dataset is not used to link_pair task, so you can use Communities ,Emails, and Protein dataset for pairwised node classification tast.

Excute command:

python main.py --model PGNN --layer_num 2 --dataset communities

Instead of --dataset grid.

dreamhomes avatar May 24 '20 14:05 dreamhomes