Create variables in module given input_spec; return output_spec.

Here module can be a Network, and we will soon also support Keras layers (and possibly Sonnet layers).

module The instance we would like to create layers on.
input_spec The input spec (excluding batch dimensions).
**kwargs Extra arguments to module.__call__, e.g. training=True.

Output specs, a nested tf.TypeSpec describing the output signature.

ValueError If module is a generic Keras layer but input_spec is None.
TypeError If module is a tf.keras.layers.{RNN,LSTM,GRU,...}. These must be wrapped in tf_agents.keras_layers.RNNWrapper.