dglai / WWW20-Hands-on-Tutorial

Materials for DGL hands-on tutorial in WWW 2020
502 stars 145 forks source link

Where to find Zachary Karate Club dataset #7

Open Maulpy opened 3 years ago

Maulpy commented 3 years ago

Dear All

This is sound silly, where do i could get sample of zkc files? the csv version of nodes and edges, i can't find it anywhere even when i'm googling it. i try to make a dummy node with 5 node-features and i get

Feed the features to graph

g.ndata['age'] = age print(g) ... DGLError: Expect number of features to match number of nodes (len(u)). Got 5 and 10 instead.

I don't know what went wrong and where it get 10 nodes.

Can you please help me Mr.@BarclayII ? Thank you very much.

Maulpy commented 3 years ago

I write randomly, and it turn out in the jupyter notebook as follow

age title 0 43 1 1 36 2 2 27 3 3 52 4 4 46 9

source destination weight 0 1 2 0.7 1 2 3 0.9 2 3 4 1.0 3 4 9 0.2 4 9 1 0.3

Maybe it cannot ignore the nodes in between (0,5,6,7,8) and that is why it got 10?yeah.