You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Perhaps I'm missing something big, but the models I'm loading are generic functions, not Flux models, with no trainable params. I tried this on resnet and shufflenet since someone had mentioned in issue #25 that they were able to load that model into Flux but it failed later, but I wasn't able to even get that far.
What am I doing wrong? Running Julia v1.1.1, Flux v0.8.3, ONNX v0.1.1, and following the README:
using Flux, ONNX
ONNX.load_model("model.onnx")
weights = ONNX.load_weights("weights.bson")
model = include("model.jl")
Thank you for your help!
The text was updated successfully, but these errors were encountered:
Sorry for not getting back at the issues raised over the past week on time. Yes, the model from your above code is just a function, not specifically a Flux model. (params(model) will return Params([])). Hence, at the moment the ONNX models can be used only for inference. However, some of the ONNX models have been ported to Metalhead.jl, which maybe be what you're looking for.
Thanks for the clarification Ayush! Just needed a sanity check, and maybe we should adjust the README.md since by my reading it implied a returned Flux model. I also wonder if with the newest Zygote.jl advances in AD we could make these models trainable, but certainly not a priority :)
Perhaps I'm missing something big, but the models I'm loading are generic functions, not Flux models, with no trainable params. I tried this on resnet and shufflenet since someone had mentioned in issue #25 that they were able to load that model into Flux but it failed later, but I wasn't able to even get that far.
What am I doing wrong? Running Julia v1.1.1, Flux v0.8.3, ONNX v0.1.1, and following the README:
Thank you for your help!
The text was updated successfully, but these errors were encountered: