PetarV- / GAT

Graph Attention Networks (https://arxiv.org/abs/1710.10903)
https://petar-v.com/GAT/
MIT License
3.15k stars 643 forks source link

Usage with image data #67

Open rsi2018502 opened 3 years ago

rsi2018502 commented 3 years ago

How can we use this with an image database instead of using it with citation databases?

gcucurull commented 3 years ago

First you would have to convert your image into a graph. For images you must decide what do your nodes and connections represent. For example, each pixel could be a node, with edges to its adjacent pixels, or the nodes could be groups of pixels or objects detected in the image.

Then you could store your graphs following the same format as Cora https://github.com/PetarV-/GAT/tree/master/data

rsi2018502 commented 3 years ago

can you suggest any method to generate the format as Cora https://github.com/PetarV-/GAT/tree/master/data

after generating the graph? Because I tried to convert the graph to this format, but I didn't get success till date.