Table Of Contents
Table Of Contents

Symbol.__call__

Symbol.__call__(*args, **kwargs)[source]

Composes symbol using inputs.

x.__call__(y, z) <=> x(y,z)

This function internally calls _compose to compose the symbol and returns the composed symbol.

Example

>>> data = mx.symbol.Variable('data')
>>> net1 = mx.symbol.FullyConnected(data=data, name='fc1', num_hidden=10)
>>> net2 = mx.symbol.FullyConnected(name='fc3', num_hidden=10)
>>> composed = net2(fc3_data=net1, name='composed')
>>> composed
<Symbol composed>
>>> called = net2.__call__(fc3_data=net1, name='composed')
>>> called
<Symbol composed>
Parameters:
  • args – Positional arguments.
  • kwargs – Keyword arguments.
Returns:

Return type:

The resulting symbol.