Why cannot hybrid forward accept None input?

Hybrid forward supports None defaults, but not None inputs. I was wondering if there are fundamental differences - if I am still using the same static computation graph but only adding None input for convenience?

An minimal example is None default in rnn_layer. All I want to do is to call rnn_layer with explicit None as input.

rnn = mx.gluon.rnn.GRU(10)
rnn(mx.nd.zeros((3,2,10)), ) # this is okay
rnn(mx.nd.zeros((3,2,10)), None) # this is not okay


Just confirmed with Sheng. I listed it as a feature request:

1 Like

Thanks for following up @yifeim