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
Expected Behaviour:
Expected to be able to grab the converted input by looking up model.input, analogous to how it's done here: https://www.nengo.ai/nengo-loihi/examples/keras-to-loihi.html, but instead using the Sequential() API. It looks like the issue is that the name in the sequential model ("dense_18_input:0") doesn't match the one in the converter ("input_10:0")?
When you pass in a Sequential model the Converter automatically converts it to a Functional model for you, and then that functional model is what is used for the actual conversion process. So all the converter data structures will be with respect to that functional model, not the sequential one. If you change your code to nengo_input = nengo_converter.inputs[nengo_converter.model.input] (note, using nengo_converter.model instead of model), then everything should work as expected.
I'll add a sentence to the warning that gets raised when you pass in a Sequential model to make this more obvious.
Thanks! That worked. As a quick note I was also seeing this when similarly trying to lookup a particular layer, e.g., via nengo_converter.layers[model.get_layer("layer_name").output]. I also tried nengo_converter.model instead of model. As well as model.layers[index]. Just mentioning this as a nice-to-have or in case I'm doing the wrong thing.
Minimal Reproducer:
Output:
Expected Behaviour:
Expected to be able to grab the converted input by looking up
model.input
, analogous to how it's done here: https://www.nengo.ai/nengo-loihi/examples/keras-to-loihi.html, but instead using theSequential()
API. It looks like the issue is that the name in the sequential model ("dense_18_input:0") doesn't match the one in the converter ("input_10:0")?Current Workaround:
The text was updated successfully, but these errors were encountered: