codeKgu / Text-GCN

A PyTorch implementation of "Graph Convolutional Networks for Text Classification." (AAAI 2019)
MIT License
123 stars 25 forks source link

Building graph #1

Open NandhaKishorM opened 3 years ago

NandhaKishorM commented 3 years ago

How to build the graph?, and what is the result that can be viewed in gephi?. I didn't see any output after running the script

codeKgu commented 3 years ago

The graph is built using the build_text_graph_dataset function. This creates a sparse graph and it is placed in a TextDataset object. You can create a networkx graph from this graph by for example using the provided function to convert to a PyTorch geometric graph and converting a pyg graph to networkx graph. Then you can save the networkx graph as a gexf file to be viewed in gephi.