-
-
Notifications
You must be signed in to change notification settings - Fork 29
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Metagraphs.jl integraion #6
Comments
Accepting constructing layers from MetaGraph #10 |
I'd be very interested in this feature. Since I can imagine it takes awhile to implement (I was playing around with trying to do it myself but a lot about MetaGraphs seems to work pretty differently from e.g. SimpleWeightedGraphs), I'm curious for interim solutions – in particular, I'd like to do something akin to the |
@rkurchin Thank you for appreciating this project. I am willing to make something different. However, I am curious. What do you mean by a layer which is able to accept different graphs? What purpose are these different graphs for? Could you give more detail about this? |
Sure, apologies if it wasn't clear. Basically, I'm trying to make a Julia implementation of Crystal Graph Convolutional Neural Nets. In these models, the inputs are different crystal structures (represented as graphs, with feature vectors for each node representing atomic features) and the outputs are quantities we wish to predict. Does this clarify? I actually have an almost working (very) preliminary version right now that I plan to post on Github as soon as I debug a few last things with the actual training of the network, which will hopefully make it even more clear what I'm looking for. |
I have seen your post on Julia discourse. I am kind of understand what you want. So, in other words, You want a layer accepts two streams, one for feature and the other for graph structure. So that the graph with in layer can be changed dynamically, and adapted with the same layer parameter. Is that right? |
Yes. The way I've been trying to implement it is that the layer accepts two inputs: one for the adjacency matrix of the graph (say, dimensions n x n), and another for the feature matrix representing the features of each node (say, dimensions f x n). I've been talking to Dhairya Gandhi about this as well and he's going to help me try to debug some things – if you'd like to have a look I can send you the code too. |
Is this what you want? #31 |
I merged #31, You may try in master branch. |
So this doesn't work for a few reasons.
except for I've been having problems with type inference with that
But with my current solution (even if I turn off the bias) I'm unable to get the model to train; I think there's still some kind of type inference issue that I haven't been able to sort out. I made a simple example with the application I've been working on, for which I'm attaching the files here if you're curious. The simple_graphcon.jl file in here is the one you want to run, it’ll import a small subset of the data I’m working with that I’ve packaged up in JLD files. I’ve demonstrated the behaviors I can’t figure out at the end of the file with some comments for elaboration, and instructions to reproduce the hcat issue also. |
Okay, Dhairya fixed it; I needed to add the following:
|
I separate the input graph from the layer in #34. Input graph and features are kept in the new type called |
ohhh this makes a ton of sense – will try this out in the next few days, thanks a lot! |
So far, Metagraph and related objects are not available to put into the model directly.
We should provide a way to let user specify which node/edge features to be used in model.
The text was updated successfully, but these errors were encountered: