Transforms an object into a function that initializes a module.

init is used to create Modules from other Python data structures or objects. For example, init-ing function would involve tracing it to find variable and assign primitives, which would then be used to define a module's variables() and its call_and_update method. Another example would be a neural network template object, which can be init-ed to return a function that returns a neural network layer module.

obj The object to be initialized.
name A string name for the initialized module.. Default value: None

A function that when called, returns an initialized Module object.