phanein / deepwalk

DeepWalk - Deep Learning for Graphs
http://www.perozzi.net/projects/deepwalk/
Other
2.68k stars 826 forks source link

Make deepwalk usable from within python? #128

Open apwest opened 3 years ago

apwest commented 3 years ago

I'm using deepwalk to generate embeddings for thousands of graphs, which I then process with python scripts. It would be great to use deepwalk as a python module instead of having to use it as a command line tool (which is also great, just not for this scenario).

I currently wrap the command using subprocess.call(), open the resulting out-file, read in the embeddings data, and carry out my processing. It would also be nice if the python module made writing the embeddings to a file optional, and allow returning the embeddings data as a python object (e.g. list, dictionary, etc.).