Replies: 2 comments 3 replies
-
I think you are right, implementing a version of |
Beta Was this translation helpful? Give feedback.
-
I gave it a try, and edited I hit a few other issues that were fine to get past (Can't use a layer directly, need to swap to using layer.forward, can't pass data and decompose it, should just pass the elements around directly), but I couldn't work around an issue with I can of course, just remove it, but its potentially going to be an issue for someone else in the future. (If anyone is wondering, you get a keyword arg error again, and if you try and avoid that, it complains about My model at least loads into my example app now, so just need to work out what tensor shape it is expecting. |
Beta Was this translation helpful? Give feedback.
Uh oh!
There was an error while loading. Please reload this page.
-
Hey!
Thanks for the library, its been a big help so far.
I'm now looking into how easy it is to move a model from Python to C++ via Torchscript.
I've looked through it for basic pytorch, then the bits in the docs for pytorch_geometric.
I was testing it on the
ogbn_proteins_deepgcn.py
example, as it uses some of the same modules I use.I stuck
.jittable()
on the two geo bits, but receieved an error when trying to apply that toDeepGCNLayer
(saying it doesn't havejittable
), so I dropped it there thinking maybe since its a wrapper bit it doesn't need that.(Code in a Gist for completeness. I dropped the dataset loading since I figured it wasn't going to change all that much, and I'd need to install another package into my venv.)
However I instead get this issue:
My (naive) assumption here would be I should just make my own "copy" of
deepgcn
and swap to using non-keyword arguments. Is that the best process here, or am I doing something wrong? Its entirely possible I've misunderstood the documentation and I'm missing a step/part of the process is missing at the moment.Also, if you have any examples/documentation of building a graph or similar in C++, that would be appreciated!
I understand the process of Python Model -> Torchscript Model -> Load Model, but I've struggled to find how that model will then expect my data to look in C++.
I'd be happy to make a PR later on with an extended torchscript example, assuming I get this working.
Beta Was this translation helpful? Give feedback.
All reactions