4
$\begingroup$

I'm not sure if this is the right community to post this in but I would appreciate any help. As the title states, I'm trying to train a neural network using some unconventional input. I'm wondering if anyone has any experience or has read any papers that involve using a partially ordered set or alternatively a directed graph as an input for a neural network? Is there a way something like a directed graph can be effectively embedded as a vector? If so, I would greatly appreciate some guidance. Thanks

$\endgroup$
4
  • 1
    $\begingroup$ Your question might be a better fit for: stats.stackexchange.com. $\endgroup$ Commented Oct 4, 2020 at 21:49
  • $\begingroup$ Neural networks are not my area, but couldn't you use an incidence matrix or something? $\endgroup$ Commented Oct 4, 2020 at 23:59
  • $\begingroup$ If we have a graph with 1 million nodes, then the incidence matrix will have 1 trillion entries, and each row that corresponds to a node on the directed graph will have 1 million entries. Neural networks do not like dealing with very long vectors of variable length. A better option would be to associate the vertices in a digraph with vectors in $\mathbb{R}^n$ in such a way so that similar vertices are associated with similar vectors. Various graph embeddings like Node2Vec exist. But it is probably a good idea to get a handle of word embeddings before going to graph embeddings. $\endgroup$ Commented Dec 30, 2022 at 17:00
  • $\begingroup$ It seems like poset embeddings should be used in natural language processing. In natural language processing, we typically split text into tokens such as "The oversimplification of transactions causes suffering." becoming ' The' ' oversimplification' ' of' ' transactions' ' causes' ' suffering', but we can also tokenize this text like 'The' ' over' 'simpli' 'fication' ' of' ' trans' 'actions' ' causes' ' suffer' 'ing'. Since there is typically multiple ways to split text into tokens, these tokens should be partially ordered, so we need a poset embedding to represent this. $\endgroup$ Commented May 7, 2023 at 18:34

1 Answer 1

7
$\begingroup$

This is most definitely NOT the right spot to ask such a question, thought it is a good one. I happen to dabble precisely with these things in these days, for my own work and research, so I think I can help you.

The first thing you have to look up is GRAPH DEEP LEARNING: here is an excellent survey for this new area of Deep Neural Networks.

There are also several libraries you can use to do experiments and to get some tutorials, for instance DGL and StellarGraph (both Python).

Now, as to your question: you can either follow the simple suggestion by Todd Trimble, which in fact goes a long way, or you also have some ready-made data structures which encode whatever you need from your graph (directed, undirected, weighted, property based, etc) and then the libraries I mentioned will provide you suitable layers to handle your use case.

Good luck!

$\endgroup$
1
  • 2
    $\begingroup$ Thank you very much for your help! $\endgroup$ Commented Oct 5, 2020 at 14:20

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .