SDCCA / DGL-PTM

The deep graph library implementation of the poverty trap model
GNU Lesser General Public License v2.1
0 stars 0 forks source link

Possible bug: edge properties not correctly propagated with global attachment #85

Open meiertgrootes opened 2 months ago

meiertgrootes commented 2 months ago

The globala attachement method uses dgl.to_simple to remove potential duplicate edges. To this end, it reasssigns the result to agent_graph. Default behaviour of .to_simple(), however, is to NOT copy edge properties. This imolies that all graph edge properties are being wiped on use of global_attachment().

TO DO:

possible fix:

SarahAlidoost commented 1 month ago

@meiertgrootes according to dgl.to_simple doc, copy_ndata is True by default whereas copy_edata is False! I added a test to check this and fixed it by adding copy_edata=True to to_simple() function in global_attachment, see here.