Module Import alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias Import alias ImportFrom alias ImportFrom alias ImportFrom alias ImportFrom alias alias ImportFrom alias alias alias alias ImportFrom alias alias alias alias alias ImportFrom alias FunctionDef arguments args NameParam NameParam defaults body Expr Str If AttributeLoad NameLoad attr body Return Call NameLoad NameLoad NameLoad NameLoad If AttributeLoad NameLoad attr body Return NameLoad decorator_list Assign NameStore NameLoad ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam defaults vararg kwarg body Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body If Call NameLoad NameLoad NameLoad body Expr Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body If CompareEq NameLoad Str body Raise NameLoad For NameStore AttributeLoad NameLoad attr body If CompareEq Call NameLoad NameLoad Str NameLoad NameLoad body Return NameLoad Raise NameLoad decorator_list decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam defaults vararg kwarg body Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body If CompareIsNot NameLoad NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index NameLoad If CompareIsNot NameLoad NameLoad body Expr Call AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body Expr Str Assign NameStore ListLoad FunctionDef arguments args NameParam NameParam defaults body Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Dict decorator_list FunctionDef arguments args NameParam defaults body If Call NameLoad NameLoad Str body Return AttributeLoad NameLoad attr Return Call NameLoad AttributeLoad NameLoad attr BinOpAdd Str AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam NameParam defaults body Expr Str If UnaryOpNot Call NameLoad NameLoad AttributeLoad NameLoad attr body Raise NameLoad FunctionDef arguments args NameParam defaults body Assign SubscriptStore AttributeLoad NameLoad attr Index NameLoad AttributeLoad NameLoad attr Return NameLoad decorator_list Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Assign AttributeStore NameLoad attr AttributeLoad NameLoad attr Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str If CompareIs NameLoad NameLoad body Return NameLoad If UnaryOpNot Call NameLoad NameLoad Str body Assign AttributeStore NameLoad attr Dict Assign NameStore Call AttributeLoad Str attr AttributeLoad AttributeLoad NameLoad attr attr AttributeLoad NameLoad attr Return Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad Call NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If BoolOpAnd CompareIn Str AttributeLoad NameLoad attr CompareIn NameLoad AttributeLoad NameLoad attr body Return Call NameLoad Call NameLoad Call NameLoad NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad AttributeLoad NameLoad attr Raise NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body If BoolOpAnd CompareIn Str AttributeLoad NameLoad attr CompareIn NameLoad AttributeLoad NameLoad attr body Raise Call NameLoad Str Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam NameParam defaults body Assign TupleStore NameStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr If UnaryOpNot Call NameLoad GeneratorExp CompareIn NameLoad BinOpAdd NameLoad ListLoad NameLoad comprehension NameStore NameLoad body Raise Call NameLoad Str Assign AttributeStore NameLoad attr NameLoad decorator_list AttributeLoad NameLoad attr FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam NameParam defaults vararg kwarg body If BoolOpAnd UnaryOpNot Call NameLoad NameLoad NameLoad AttributeLoad NameLoad attr body Raise NameLoad Assign NameStore Call AttributeLoad NameLoad attr NameLoad AttributeLoad NameLoad attr Return Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults vararg kwarg body Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad Assign NameStore Call AttributeLoad NameLoad attr Str NameLoad If BoolOpAnd NameLoad NameLoad body Raise NameLoad Assign NameStore AttributeLoad NameLoad attr Assign TupleStore NameStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr AttributeLoad NameLoad attr Assign NameStore SubscriptLoad NameLoad Slice Num Assign NameStore Call NameLoad NameLoad Assign NameStore Call NameLoad NameLoad If CompareIn Str NameLoad body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Str NameLoad If CompareIn Str NameLoad body Expr Call AttributeLoad NameLoad attr Call AttributeLoad NameLoad attr Str NameLoad If UnaryOpNot AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr FunctionDef arguments args NameParam NameParam NameParam defaults body Expr Str Assign NameStore Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Expr Call NameLoad NameLoad NameLoad Expr Call NameLoad NameLoad NameLoad Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad Expr Call NameLoad NameLoad NameLoad Return NameLoad decorator_list For TupleStore NameStore NameStore Call NameLoad NameLoad body If Call NameLoad NameLoad AttributeLoad NameLoad attr body If CompareLt NameLoad Call NameLoad NameLoad body Assign NameStore SubscriptLoad NameLoad Index NameLoad orelse Assign NameStore Call AttributeLoad Str attr NameLoad BinOpSub NameLoad Call NameLoad NameLoad Assign SubscriptStore NameLoad Index NameLoad Call NameLoad NameLoad NameLoad NameLoad For TupleStore NameStore NameStore Call AttributeLoad NameLoad attr body If Call NameLoad NameLoad AttributeLoad NameLoad attr body Assign SubscriptStore NameLoad Index NameLoad Call NameLoad NameLoad NameLoad NameLoad Assign NameStore IfExp AttributeLoad NameLoad attr SubscriptLoad AttributeLoad NameLoad attr Index Num NameLoad If BoolOpAnd NameLoad CompareIsNot NameLoad NameLoad CompareNotIn NameLoad AttributeLoad NameLoad attr body Raise Call NameLoad BinOpAdd BinOpAdd BinOpAdd BinOpAdd Str Call NameLoad SubscriptLoad AttributeLoad NameLoad attr Index Num Str Call NameLoad AttributeLoad NameLoad attr Str Expr Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad TryFinally body Assign NameStore Call AttributeLoad NameLoad attr NameLoad NameLoad NameLoad Assign NameStore Call NameLoad NameLoad finalbody Expr Call AttributeLoad AttributeLoad NameLoad attr attr For TupleStore NameStore NameStore Call NameLoad NameLoad body If Call NameLoad NameLoad AttributeLoad NameLoad attr body TryExcept body Assign NameStore SubscriptLoad AttributeLoad NameLoad attr Index NameLoad handlers ExceptHandler type NameLoad body Assign NameStore Call AttributeLoad Str attr NameLoad ExceptHandler type NameLoad body Expr Call NameLoad Call NameLoad Str Assign SubscriptStore NameLoad Index NameLoad Call NameLoad SubscriptLoad NameLoad Index NameLoad NameLoad NameLoad If NameLoad body Return NameLoad If NameLoad body Return Call NameLoad Call NameLoad AttributeLoad NameLoad attr NameLoad Return Call NameLoad NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return TupleLoad NameLoad TupleLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr decorator_list decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body If CompareEq NameLoad Str body Raise NameLoad If CompareIn NameLoad TupleLoad Str Str body Return Call NameLoad AttributeLoad NameLoad attr NameLoad If CompareIn NameLoad Call AttributeLoad AttributeLoad NameLoad attr attr body Return Call NameLoad AttributeLoad AttributeLoad NameLoad attr attr NameLoad If CompareIn NameLoad AttributeLoad NameLoad attr body Return Call Call NameLoad NameLoad SubscriptLoad AttributeLoad NameLoad attr Index NameLoad AttributeLoad NameLoad attr TryExcept body Return Call NameLoad AttributeLoad NameLoad attr NameLoad handlers ExceptHandler type NameLoad body If AttributeLoad NameLoad attr body Return Call NameLoad Call Call NameLoad AttributeLoad NameLoad attr AttributeLoad NameLoad attr NameLoad Raise decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad AttributeLoad NameLoad attr attr decorator_list NameLoad FunctionDef arguments args NameParam defaults vararg kwarg body Return Call AttributeLoad AttributeLoad NameLoad attr attr NameLoad NameLoad NameLoad decorator_list decorator_list FunctionDef arguments args NameParam NameParam defaults body Assign NameStore AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad If AttributeLoad NameLoad attr body Assign AttributeStore NameLoad attr BinOpAdd SubscriptLoad AttributeLoad NameLoad attr Slice UnaryOpUSub Call NameLoad NameLoad NameLoad Return NameLoad decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam NameParam NameParam defaults body Assign NameStore Call AttributeLoad NameLoad attr Str ListLoad For NameStore NameLoad body Expr Call NameLoad NameLoad NameLoad NameLoad NameLoad For NameStore Call NameLoad Call AttributeLoad NameLoad attr body If BoolOpAnd Call NameLoad NameLoad NameLoad Call NameLoad NameLoad Str body Assign SubscriptStore NameLoad Index BinOpAdd Str AttributeLoad NameLoad attr Call NameLoad AttributeLoad NameLoad attr BinOpAdd Str AttributeLoad NameLoad attr Delete AttributeDel NameLoad attr Assign NameStore Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad NameLoad NameLoad NameLoad For NameStore Call AttributeLoad NameLoad attr body If Call NameLoad NameLoad NameLoad body Assign AttributeStore NameLoad attr NameLoad Return NameLoad decorator_list decorator_list ClassDef bases NameLoad body Expr Str Assign NameStore NameLoad FunctionDef arguments args NameParam NameParam defaults NameLoad body If CompareIs NameLoad NameLoad body Assign NameStore Call AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr ListLoad Assign AttributeStore NameLoad attr ListLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr NameLoad Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return Call NameLoad NameLoad Str decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam NameParam defaults body Assign AttributeStore NameLoad attr Call NameLoad NameLoad NameLoad decorator_list AttributeLoad NameLoad attr FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list NameLoad FunctionDef arguments args NameParam NameParam defaults body Assign AttributeStore NameLoad attr Call NameLoad NameLoad NameLoad decorator_list AttributeLoad NameLoad attr FunctionDef arguments args NameParam defaults body Expr Str If Call NameLoad NameLoad Str body Assign NameStore ListComp NameLoad comprehension NameStore AttributeLoad NameLoad attr CompareIs Call NameLoad NameLoad NameLoad NameLoad If NameLoad body Raise Call NameLoad Call AttributeLoad Str attr Call AttributeLoad Str attr NameLoad If UnaryOpNot AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr For NameStore AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr ListLoad Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Pass decorator_list FunctionDef arguments args NameParam defaults body Expr Str If Call NameLoad NameLoad Str body Assign NameStore ListComp NameLoad comprehension NameStore AttributeLoad NameLoad attr CompareIs Call NameLoad NameLoad NameLoad NameLoad If NameLoad body Raise Call NameLoad Call AttributeLoad Str attr Call AttributeLoad Str attr NameLoad If UnaryOpNot AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr If UnaryOpNot AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr For NameStore AttributeLoad NameLoad attr body Expr Call AttributeLoad NameLoad attr Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str Pass decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad For NameStore AttributeLoad NameLoad attr body TryExcept body Expr Call AttributeLoad NameLoad attr handlers ExceptHandler type NameLoad body Assign AttributeStore NameLoad attr NameLoad Raise decorator_list FunctionDef arguments args NameParam defaults body Expr Str Pass decorator_list FunctionDef arguments args NameParam defaults body Expr Str Expr Call AttributeLoad NameLoad attr Assign AttributeStore NameLoad attr NameLoad For NameStore AttributeLoad NameLoad attr body TryExcept body Expr Call AttributeLoad NameLoad attr handlers ExceptHandler type NameLoad body Assign AttributeStore NameLoad attr NameLoad Raise decorator_list FunctionDef arguments args NameParam defaults body Expr Str Pass decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Raise Call NameLoad Call AttributeLoad Str attr NameLoad decorator_list FunctionDef arguments args NameParam NameParam defaults body Expr Str Return ListComp Call AttributeLoad NameLoad attr NameLoad comprehension NameStore NameLoad decorator_list FunctionDef arguments args NameParam defaults body Expr Str If AttributeLoad NameLoad attr body Assign NameStore Call NameLoad AttributeLoad NameLoad attr keyword Call NameLoad Str Return BinOpAdd Call AttributeLoad NameLoad attr ListLoad NameLoad orelse Return ListLoad NameLoad decorator_list decorator_list Call NameLoad NameLoad FunctionDef arguments args NameParam NameParam defaults body Assign TupleStore NameStore NameStore NameStore NameStore Call AttributeLoad NameLoad attr NameLoad Return Call NameLoad GeneratorExp TupleLoad NameLoad NameLoad comprehension TupleStore NameStore NameStore Call NameLoad BinOpAdd NameLoad ListLoad NameLoad NameLoad decorator_list ClassDef bases NameLoad body FunctionDef arguments args NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad decorator_list FunctionDef arguments args NameParam defaults body Return AttributeLoad NameLoad attr decorator_list FunctionDef arguments args NameParam defaults body Return NameLoad decorator_list Assign NameStore NameLoad decorator_list Assign NameStore Call NameLoad Str Assign NameStore Call NameLoad Str FunctionDef arguments args NameParam NameParam defaults NameLoad NameLoad body Expr Str If UnaryOpNot NameLoad body Assign NameStore ListLoad If UnaryOpNot NameLoad body Assign NameStore ListLoad FunctionDef arguments args NameParam defaults body FunctionDef arguments args defaults vararg kwarg body Assign NameStore SubscriptLoad NameLoad Index Num Assign AttributeStore NameLoad attr BinOpAdd Call NameLoad NameLoad Str ListLoad NameLoad Assign AttributeStore NameLoad attr BinOpAdd Call NameLoad NameLoad Str ListLoad NameLoad Assign NameStore Call NameLoad Call NameLoad NameLoad NameLoad NameLoad For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad For NameStore NameLoad body Expr Call AttributeLoad NameLoad attr NameLoad NameLoad Return Call NameLoad NameLoad decorator_list Expr Call Call NameLoad NameLoad NameLoad Return NameLoad decorator_list Return NameLoad decorator_list ClassDef bases NameLoad body Expr Str FunctionDef arguments args NameParam NameParam defaults body Assign AttributeStore NameLoad attr NameLoad Assign AttributeStore NameLoad attr Dict Expr Call AttributeLoad Call NameLoad NameLoad NameLoad attr decorator_list FunctionDef arguments args NameParam NameParam NameParam NameParam defaults NameLoad NameLoad body If NameLoad body Assign AttributeStore NameLoad attr Call NameLoad AttributeLoad AttributeLoad AttributeLoad NameLoad attr attr attr AttributeLoad AttributeLoad NameLoad attr attr NameLoad Assign AttributeStore AttributeLoad NameLoad attr attr NameLoad Assign NameStore NameLoad Expr Call NameLoad NameLoad AttributeLoad AttributeLoad NameLoad attr attr Return Call AttributeLoad Call NameLoad NameLoad NameLoad attr NameLoad NameLoad NameLoad decorator_list decorator_list FunctionDef arguments args defaults vararg kwarg body Expr Str If UnaryOpNot BoolOpOr BoolOpAnd NameLoad UnaryOpNot NameLoad BoolOpAnd UnaryOpNot NameLoad NameLoad body Raise NameLoad If NameLoad body Assign TupleStore NameStore NameLoad Assign NameStore Call NameLoad NameLoad Return NameLoad orelse FunctionDef arguments args NameParam defaults body Assign NameStore Call NameLoad NameLoad For TupleStore NameStore NameStore Call AttributeLoad NameLoad attr body Expr Call NameLoad NameLoad NameLoad NameLoad Return NameLoad decorator_list Return NameLoad decorator_list FunctionDef arguments args NameParam NameParam NameParam defaults body Return Call AttributeLoad Str attr NameLoad NameLoad NameLoad decorator_list
N/A N/A inspect abc ABCMeta collections OrderedDict functools wraps operator attrgetter types MethodType N/A six six add_metaclass theano tensor theano.gof Variable blocks.graph add_annotation Annotation blocks.roles add_role PARAMETER INPUT OUTPUT blocks.utils dict_union pack repr_attrs reraise_as unpack blocks.utils.containers AnnotatingList create_unbound_method N/A N/A func cls N/A N/A N/A Create an unbounded method from a function and a class.

    Notes
    -----
    See https://bitbucket.org/gutworth/six/pull-request/64.

     N/A N/A six PY2 N/A N/A N/A MethodType func None cls N/A N/A six PY3 N/A N/A func N/A N/A property_ property Parameters N/A AnnotatingList N/A N/A Adds the PARAMETER role to parameters automatically. __init__ N/A N/A self brick N/A args kwargs N/A N/A N/A self brick brick N/A N/A N/A N/A super Parameters self __init__ args kwargs N/A _setitem N/A N/A self key value N/A N/A N/A N/A isinstance value Variable N/A N/A N/A add_role value PARAMETER N/A N/A add_annotation value N/A self brick N/A __getattr__ N/A N/A self name N/A N/A N/A N/A name _items N/A N/A AttributeError N/A l N/A self _items N/A N/A N/A N/A getattr l name None name N/A N/A l N/A AttributeError N/A N/A Children N/A AnnotatingList N/A N/A Adds the brick to the list of parents of its children. __init__ N/A N/A self brick N/A args kwargs N/A N/A N/A self brick brick N/A N/A N/A N/A super Children self __init__ args kwargs N/A _setitem N/A N/A self key value N/A N/A N/A N/A value None N/A N/A N/A N/A N/A value parents append N/A self brick N/A _delitem N/A N/A self key N/A N/A N/A child N/A N/A self _items N/A key N/A N/A child None N/A N/A N/A N/A N/A child parents remove N/A self brick N/A N/A Application N/A object N/A N/A An application method belonging to a particular type of brick.

    The application methods of each :class:`Brick` class are automatically
    replaced by an instance of :class:`Application`. This allows us to
    store metadata about particular application methods (such as their in-
    and outputs) easily.

    Attributes
    ----------
    application : callable
        The original (unbounded) application function defined on the
        :class:`Brick`.
    delegate_function : callable
        A function that takes a :class:`Brick` instance as an argument and
        returns a :class:`BoundApplication` object to which attribute
        requests should be routed.
    properties : :obj:`dict` (:obj:`str`, :obj:`callable`)
        A dictionary of property getters that should be called when an
        attribute with the given name is requested.
    instances : :obj:`dict` (:class:`Brick`, :class:`BoundApplication`)
        A record of bound application instances created by the descriptor
        protocol.
    call_stack : :obj:`list` of :class:`Brick`
        The call stack of brick application methods. Used to check whether
        the current call was made by a parent brick.
    brick : type
        The brick class to which this instance belongs.

    Raises
    ------
    ValueError
        If a brick's application method is applied by another brick which
        does not list the former as a child.
    ValueError
        If the application method's inputs and/or outputs don't match with
        the function signature or the values returned (respectively).

    Notes
    -----
    When a :class:`Brick` is instantiated and its application method (i.e.
    an instance of this class) requested, the descriptor protocol (through
    the :meth:`__get__` method) automatically instantiates a
    :class:`BoundApplication` class and returns this. This bound
    application class can be used to store application information
    particular to a brick instance. Any attributes unknown to the bounded
    application are automatically routed to the application that
    instantiated it.

     N/A call_stack N/A __init__ N/A N/A self application_function N/A N/A N/A N/A self __doc__ N/A application_function __doc__ N/A N/A self _application_function application_function N/A N/A self application_name N/A application_function __name__ N/A N/A self delegate_function None N/A N/A self properties N/A N/A application_function N/A N/A self N/A N/A N/A N/A hasattr self _application_function N/A N/A N/A self _application_function N/A N/A getattr N/A self brick N/A _ N/A self application_name N/A property property N/A N/A self name N/A N/A N/A Decorator to make application properties.

        Parameters
        ----------
        name : str
            The name the property should take.

        Examples
        --------
        >>> class Foo(Brick):
        ...     @application
        ...     def apply(self, x):
        ...         return x + 1
        ...
        ...     @apply.property('inputs')
        ...     def apply_inputs(self):
        ...         return ['foo', 'bar']
        >>> foo = Foo()
        >>> foo.apply.inputs
        ['foo', 'bar']

         N/A N/A N/A isinstance name N/A six string_types N/A N/A ValueError wrap_property N/A N/A application_property N/A N/A N/A N/A N/A self properties N/A name N/A application_property __name__ N/A application_property N/A N/A wrap_property N/A delegate N/A N/A self f N/A N/A N/A Decorator to assign a delegate application.

        An application method can assign a delegate application. Whenever
        an attribute is not available, it will be requested from the
        delegate instead.

        Examples
        --------
        >>> class Foo(Brick):
        ...     @application(outputs=['baz'])
        ...     def apply(self, x):
        ...         return x + 1
        ...
        ...     @apply.property('inputs')
        ...     def apply_inputs(self):
        ...         return ['foo', 'bar']
        >>> class Bar(Brick):
        ...     def __init__(self, foo):
        ...         self.foo = foo
        ...
        ...     @application(outputs=['foo'])
        ...     def apply(self, x):
        ...         return x + 1
        ...
        ...     @apply.delegate
        ...     def apply_delegate(self):
        ...         return self.foo.apply
        >>> foo = Foo()
        >>> bar = Bar(foo)
        >>> bar.apply.outputs
        ['foo']
        >>> bar.apply.inputs
        ['foo', 'bar']

         N/A N/A self delegate_function N/A f __name__ N/A f N/A __get__ N/A N/A self instance owner N/A N/A N/A Instantiate :class:`BoundApplication` for each :class:`Brick`. N/A N/A instance None N/A N/A self N/A N/A N/A hasattr instance _bound_applications N/A N/A N/A instance _bound_applications N/A N/A key N/A N/A {}.{} format N/A N/A self brick __name__ N/A self application_name N/A N/A N/A N/A instance _bound_applications setdefault key N/A BoundApplication self instance N/A __getattr__ N/A N/A self name N/A N/A N/A N/A N/A properties N/A self __dict__ N/A name N/A self properties N/A N/A N/A property N/A create_unbound_method N/A getattr self N/A N/A self properties N/A name N/A self brick N/A AttributeError N/A __setattr__ N/A N/A self name value N/A N/A N/A N/A N/A properties N/A self __dict__ N/A name N/A self properties N/A N/A N/A AttributeError can't set attribute N/A N/A N/A N/A super Application self __setattr__ name value N/A inputs N/A N/A self N/A N/A N/A N/A self _inputs N/A property_ inputs N/A N/A self inputs N/A N/A N/A N/A args_names varargs_name _ _ N/A N/A inspect getargspec N/A self application_function N/A N/A N/A all N/A N/A input_ N/A args_names N/A varargs_name N/A input_ inputs N/A N/A N/A ValueError Unexpected inputs N/A N/A self _inputs inputs N/A N/A inputs setter name N/A N/A self N/A N/A N/A N/A self application_name N/A property_ __call__ N/A N/A self brick N/A args kwargs N/A N/A N/A N/A N/A isinstance brick Brick N/A six PY2 N/A N/A TypeError N/A bound_application N/A N/A self __get__ brick N/A brick __class__ N/A N/A N/A self apply bound_application args kwargs N/A apply N/A N/A self bound_application N/A args kwargs N/A N/A as_dict N/A N/A kwargs pop as_dict False N/A as_list N/A N/A kwargs pop as_list False N/A N/A as_list as_dict N/A N/A ValueError N/A brick N/A bound_application brick N/A N/A args_names varargs_name _ _ N/A N/A inspect getargspec N/A self application_function N/A args_names N/A args_names N/A 1 N/A call N/A ApplicationCall bound_application N/A args N/A list args N/A N/A application args_names N/A N/A N/A N/A args insert N/A N/A args_names index application bound_application N/A N/A application_call args_names N/A N/A N/A N/A args insert N/A N/A args_names index application_call call N/A N/A N/A brick allocated N/A N/A N/A N/A brick allocate copy_and_tag N/A N/A variable role name N/A N/A N/A Helper method to copy a variable and annotate it. N/A copy N/A N/A variable copy N/A N/A copy name N/A _variable_name N/A brick name N/A self name name N/A N/A add_annotation copy brick N/A N/A add_annotation copy call N/A N/A N/A copy tag name name N/A N/A add_role copy role N/A copy N/A N/A N/A i input_ N/A enumerate args N/A N/A N/A isinstance input_ N/A tensor Variable N/A N/A N/A i N/A len args_names N/A N/A name N/A args_names N/A i N/A N/A name N/A N/A {}_{} format varargs_name N/A i N/A len args_names N/A N/A args N/A i N/A copy_and_tag input_ INPUT name N/A N/A name input_ N/A N/A kwargs items N/A N/A N/A isinstance input_ N/A tensor Variable N/A N/A N/A kwargs N/A name N/A copy_and_tag input_ INPUT name N/A last_brick N/A N/A self call_stack N/A N/A self call_stack N/A -1 None N/A N/A last_brick N/A brick last_brick N/A brick N/A last_brick children N/A N/A N/A ValueError N/A N/A N/A N/A Brick  N/A str N/A N/A self call_stack N/A -1  tries to call brick  N/A str N/A self brick  which is not in the list of its children. This could be caused because an @application decorator is missing. N/A N/A N/A N/A self call_stack append brick N/A N/A N/A outputs N/A N/A self application_function brick args kwargs N/A outputs N/A pack outputs N/A N/A N/A N/A N/A self call_stack pop N/A N/A i output N/A enumerate outputs N/A N/A N/A isinstance output N/A tensor Variable N/A N/A N/A N/A name N/A N/A bound_application outputs N/A i N/A N/A N/A AttributeError N/A N/A name N/A N/A output_{} format i N/A N/A IndexError N/A N/A N/A reraise_as N/A ValueError Unexpected outputs N/A N/A outputs N/A i N/A copy_and_tag N/A outputs N/A i OUTPUT name N/A as_list N/A N/A outputs N/A as_dict N/A N/A N/A OrderedDict N/A zip N/A bound_application outputs outputs N/A N/A unpack outputs N/A __reduce__ N/A N/A self N/A N/A N/A N/A getattr N/A N/A self brick N/A self application_name N/A N/A BoundApplication N/A object N/A N/A An application method bound to a :class:`Brick` instance. __init__ N/A N/A self application brick N/A N/A N/A N/A self application application N/A N/A self brick brick N/A __getattr__ N/A N/A self name N/A N/A N/A N/A name application N/A N/A AttributeError N/A N/A name N/A delegate_function properties N/A N/A N/A getattr N/A self application name N/A N/A name N/A N/A N/A self properties values N/A N/A N/A getattr N/A N/A self application brick name N/A N/A name N/A self properties N/A N/A N/A N/A getattr self N/A N/A self properties N/A name N/A self brick N/A N/A N/A N/A getattr N/A self application name N/A N/A N/A AttributeError N/A N/A N/A self delegate_function N/A N/A N/A getattr N/A N/A getattr N/A self brick N/A self delegate_function name N/A N/A name N/A N/A self N/A N/A N/A N/A N/A self application name N/A property __call__ N/A N/A self N/A args kwargs N/A N/A N/A N/A N/A self application apply self args kwargs N/A N/A rename_function N/A N/A function new_name N/A N/A N/A old_name N/A function __name__ N/A N/A function __name__ new_name N/A N/A six PY3 N/A N/A N/A function __qualname__ N/A N/A N/A function __qualname__ N/A N/A N/A len old_name new_name N/A function N/A _Brick N/A ABCMeta N/A N/A Metaclass which attaches brick instances to the applications.

    In addition picklability of :class:`Application` objects is ensured.
    This means that :class:`Application` objects can not be added to a
    brick class after it is created. To allow adding application methods
    programatically, the following hook is supported: the class namespace
    is searched for `decorators` attribute, which can contain a
    list of functions to be applied to the namespace of the class being
    created. These functions can arbitratily modify this namespace.

     __new__ N/A N/A mcs name bases namespace N/A N/A N/A decorators N/A N/A namespace get decorators N/A N/A decorator decorators N/A N/A N/A decorator mcs name bases namespace N/A attr N/A list N/A N/A namespace values N/A N/A N/A N/A isinstance attr Application N/A hasattr attr _application_function N/A N/A N/A namespace N/A N/A _ N/A attr application_name N/A rename_function N/A attr _application_function N/A _ N/A attr application_name N/A N/A attr _application_function N/A brick N/A N/A N/A super _Brick mcs __new__ mcs name bases namespace N/A attr N/A N/A namespace values N/A N/A N/A isinstance attr Application N/A N/A N/A attr brick brick N/A brick N/A N/A Brick N/A Annotation N/A N/A A brick encapsulates Theano operations with parameters.

    A brick goes through the following stages:

    1. Construction: The call to :meth:`__init__` constructs a
       :class:`Brick` instance with a name and creates any child bricks as
       well.
    2. Allocation of parameters:

       a) Allocation configuration of children: The
          :meth:`push_allocation_config` method configures any children of
          this block.
       b) Allocation: The :meth:`allocate` method allocates the shared
          Theano variables required for the parameters. Also allocates
          parameters for all children.

    3. The following can be done in either order:

       a) Application: By applying the brick to a set of Theano
          variables a part of the computational graph of the final model is
          constructed.
       b) The initialization of parameters:

          1. Initialization configuration of children: The
             :meth:`push_initialization_config` method configures any
             children of this block.
          2. Initialization: This sets the initial values of the
             parameters by a call to :meth:`initialize`, which is needed
             to call the final compiled Theano function.  Also initializes
             all children.

    Not all stages need to be called explicitly. Step 3(a) will
    automatically allocate the parameters if needed. Similarly, step
    3(b.2) and 2(b) will automatically perform steps 3(b.1) and 2(a) if
    needed. They only need to be called separately if greater control is
    required. The only two methods which always need to be called are an
    application method to construct the computational graph, and the
    :meth:`initialize` method in order to initialize the parameters.

    At each different stage, a brick might need a certain set of
    configuration settings. All of these settings can be passed to the
    :meth:`__init__` constructor. However, by default many bricks support
    *lazy initialization*. This means that the configuration settings can
    be set later.

    .. note::

       Some arguments to :meth:`__init__` are *always* required, even when
       lazy initialization is enabled. Other arguments must be given before
       calling :meth:`allocate`, while others yet only need to be given in
       order to call :meth:`initialize`. Always read the documentation of
       each brick carefully.

    Lazy initialization can be turned off by setting ``Brick.lazy =
    False``. In this case, there is no need to call :meth:`initialize`
    manually anymore, but all the configuration must be passed to the
    :meth:`__init__` method.

    Parameters
    ----------
    name : str, optional
        The name of this brick. This can be used to filter the application
        of certain modifications by brick names. By default, the brick
        receives the name of its class (lowercased).

    Attributes
    ----------
    name : str
        The name of this brick.
    print_shapes : bool
        ``False`` by default. If ``True`` it logs the shapes of all the
        input and output variables, which can be useful for debugging.
    parameters : list of :class:`~tensor.TensorSharedVariable` and ``None``
        After calling the :meth:`allocate` method this attribute will be
        populated with the shared variables storing this brick's
        parameters. Allows for ``None`` so that parameters can always be
        accessed at the same index, even if some parameters are only
        defined given a particular configuration.
    children : list of bricks
        The children of this brick.
    allocated : bool
        ``False`` if :meth:`allocate` has not been called yet. ``True``
        otherwise.
    initialized : bool
        ``False`` if :meth:`allocate` has not been called yet. ``True``
        otherwise.
    allocation_config_pushed : bool
        ``False`` if :meth:`allocate` or :meth:`push_allocation_config`
        hasn't been called yet. ``True`` otherwise.
    initialization_config_pushed : bool
        ``False`` if :meth:`initialize` or
        :meth:`push_initialization_config` hasn't been called yet. ``True``
        otherwise.

    Notes
    -----
    To provide support for lazy initialization, apply the :meth:`lazy`
    decorator to the :meth:`__init__` method.

    Brick implementations *must* call the :meth:`__init__` constructor of
    their parent using `super(BlockImplementation,
    self).__init__(**kwargs)` at the *beginning* of the overriding
    `__init__`.

    The methods :meth:`_allocate` and :meth:`_initialize` need to be
    overridden if the brick needs to allocate shared variables and
    initialize their values in order to function.

    A brick can have any number of methods which apply the brick on Theano
    variables. These methods should be decorated with the
    :func:`application` decorator.

    If a brick has children, they must be listed in the :attr:`children`
    attribute. Moreover, if the brick wants to control the configuration of
    its children, the :meth:`_push_allocation_config` and
    :meth:`_push_initialization_config` methods need to be overridden.

    Examples
    --------
    Most bricks have lazy initialization enabled.

    >>> import theano
    >>> from blocks.initialization import IsotropicGaussian, Constant
    >>> from blocks.bricks import Linear
    >>> linear = Linear(input_dim=5, output_dim=3,
    ...                 weights_init=IsotropicGaussian(),
    ...                 biases_init=Constant(0))
    >>> x = theano.tensor.vector()
    >>> linear.apply(x)  # Calls linear.allocate() automatically
    linear_apply_output
    >>> linear.initialize()  # Initializes the weight matrix

     N/A print_shapes False __init__ N/A N/A self name N/A None N/A N/A N/A name None N/A N/A name N/A N/A N/A N/A self __class__ __name__ lower N/A N/A self name name N/A N/A self children N/A N/A N/A self parents N/A N/A N/A self allocated False N/A N/A self allocation_config_pushed False N/A N/A self initialized False N/A N/A self initialization_config_pushed False N/A N/A N/A N/A super Brick self __init__ N/A __repr__ N/A N/A self N/A N/A N/A N/A repr_attrs self name N/A parameters N/A N/A self N/A N/A N/A N/A self _parameters N/A property parameters N/A N/A self value N/A N/A N/A N/A self _parameters N/A Parameters self value N/A N/A parameters setter children N/A N/A self N/A N/A N/A N/A self _children N/A property children N/A N/A self value N/A N/A N/A N/A self _children N/A Children self value N/A N/A children setter allocate N/A N/A self N/A N/A N/A Allocate shared variables for parameters.

        Based on the current configuration of this :class:`Brick` create
        Theano shared variables to store the parameters.  After allocation,
        parameters are accessible through the :attr:`parameters` attribute.

        This method calls the :meth:`allocate` method of all children
        first, allowing the :meth:`_allocate` method to override the
        parameters of the children if needed.

        Raises
        ------
        ValueError
            If the configuration of this brick is insufficient to determine
            the number of parameters or their dimensionality to be
            initialized.

        Notes
        -----
        This method sets the :attr:`parameters` attribute to an empty list.
        This is in order to ensure that calls to this method completely
        reset the parameters.

         N/A N/A hasattr self allocation_args N/A N/A missing_config N/A arg N/A arg N/A self allocation_args N/A N/A getattr self arg NoneAllocation N/A missing_config N/A N/A N/A ValueError N/A N/A allocation config not set: {} format N/A N/A ,  join missing_config N/A N/A N/A self allocation_config_pushed N/A N/A N/A N/A self push_allocation_config N/A child N/A self children N/A N/A N/A N/A child allocate N/A N/A self parameters N/A N/A N/A N/A self _allocate N/A N/A self allocated True N/A _allocate N/A N/A self N/A N/A N/A Brick implementation of parameter initialization.

        Implement this if your brick needs to allocate its parameters.

        .. warning::

           This method should never be called directly. Call
           :meth:`initialize` instead.

         N/A N/A initialize N/A N/A self N/A N/A N/A Initialize parameters.

        Intialize parameters, such as weight matrices and biases.

        Notes
        -----
        If the brick has not allocated its parameters yet, this method will
        call the :meth:`allocate` method in order to do so.

         N/A N/A hasattr self initialization_args N/A N/A missing_config N/A arg N/A arg N/A self initialization_args N/A N/A getattr self arg NoneInitialization N/A missing_config N/A N/A N/A ValueError N/A N/A initialization config not set: {} format N/A N/A ,  join missing_config N/A N/A N/A self allocated N/A N/A N/A N/A self allocate N/A N/A N/A self initialization_config_pushed N/A N/A N/A N/A self push_initialization_config N/A child N/A self children N/A N/A N/A N/A child initialize N/A N/A N/A self _initialize N/A N/A self initialized True N/A _initialize N/A N/A self N/A N/A N/A Brick implementation of parameter initialization.

        Implement this if your brick needs to initialize its parameters.

        .. warning::

           This method should never be called directly. Call
           :meth:`initialize` instead.

         N/A N/A push_allocation_config N/A N/A self N/A N/A N/A Push the configuration for allocation to child bricks.

        Bricks can configure their children, based on their own current
        configuration. This will be automatically done by a call to
        :meth:`allocate`, but if you want to override the configuration of
        child bricks manually, then you can call this function manually.

         N/A N/A N/A self _push_allocation_config N/A N/A self allocation_config_pushed True N/A child N/A self children N/A N/A N/A N/A N/A N/A child push_allocation_config N/A N/A N/A Exception N/A N/A N/A self allocation_config_pushed False N/A N/A _push_allocation_config N/A N/A self N/A N/A N/A Brick implementation of configuring child before allocation.

        Implement this if your brick needs to set the configuration of its
        children before allocation.

        .. warning::

           This method should never be called directly. Call
           :meth:`push_allocation_config` instead.

         N/A N/A push_initialization_config N/A N/A self N/A N/A N/A Push the configuration for initialization to child bricks.

        Bricks can configure their children, based on their own current
        configuration. This will be automatically done by a call to
        :meth:`initialize`, but if you want to override the configuration
        of child bricks manually, then you can call this function manually.

         N/A N/A N/A self _push_initialization_config N/A N/A self initialization_config_pushed True N/A child N/A self children N/A N/A N/A N/A N/A N/A child push_initialization_config N/A N/A N/A Exception N/A N/A N/A self initialization_config_pushed False N/A N/A _push_initialization_config N/A N/A self N/A N/A N/A Brick implementation of configuring child before initialization.

        Implement this if your brick needs to set the configuration of its
        children before initialization.

        .. warning::

           This method should never be called directly. Call
           :meth:`push_initialization_config` instead.

         N/A N/A get_dim N/A N/A self name N/A N/A N/A Get dimension of an input/output variable of a brick.

        Parameters
        ----------
        name : str
            The name of the variable.

         N/A N/A ValueError N/A N/A No dimension information for {} available format name N/A get_dims N/A N/A self names N/A N/A N/A Get list of dimensions for a set of input/output variables.

        Parameters
        ----------
        names : list
            The variable names.

        Returns
        -------
        dims : list
            The dimensions of the sources.

         N/A N/A N/A N/A self get_dim name N/A name names N/A get_unique_path N/A N/A self N/A N/A N/A Returns unique path to this brick in the application graph. N/A N/A self parents N/A N/A parent N/A min N/A self parents key N/A attrgetter name N/A N/A N/A N/A parent get_unique_path N/A self N/A N/A N/A self N/A N/A N/A add_metaclass _Brick args_to_kwargs N/A N/A args f N/A N/A N/A N/A arg_names vararg_names _ _ N/A N/A inspect getargspec f N/A N/A dict N/A N/A arg_name arg N/A N/A arg_name arg N/A zip N/A arg_names N/A vararg_names args N/A LazyNone N/A object N/A __init__ N/A N/A self name N/A N/A N/A N/A self name name N/A __repr__ N/A N/A self N/A N/A N/A N/A self name N/A __bool__ N/A N/A self N/A N/A N/A False N/A N/A __nonzero__ __bool__ N/A N/A NoneAllocation N/A LazyNone NoneAllocation N/A NoneInitialization N/A LazyNone NoneInitialization lazy N/A N/A allocation initialization N/A None None N/A N/A Makes the initialization lazy.

    This decorator allows the user to define positional arguments which
    will not be needed until the allocation or initialization stage of the
    brick. If these arguments are not passed, it will automatically replace
    them with a custom ``None`` object. It is assumed that the missing
    arguments can be set after initialization by setting attributes with
    the same name.

    Parameters
    ----------
    allocation : list
        A list of argument names that are needed for allocation.
    initialization : list
        A list of argument names that are needed for initialization.

    Examples
    --------
    >>> class SomeBrick(Brick):
    ...     @lazy(allocation=['a'], initialization=['b'])
    ...     def __init__(self, a, b, c='c', d=None):
    ...         print(a, b, c, d)
    >>> brick = SomeBrick('a')
    a NoneInitialization c None
    >>> brick = SomeBrick(d='d', b='b')
    NoneAllocation b c d

     N/A N/A allocation N/A N/A allocation N/A N/A N/A initialization N/A N/A initialization N/A lazy_wrapper N/A N/A init N/A N/A lazy_init N/A N/A N/A args kwargs N/A N/A self N/A args N/A 0 N/A N/A self allocation_args N/A N/A getattr self allocation_args N/A allocation N/A N/A self initialization_args N/A N/A getattr self initialization_args N/A initialization N/A kwargs N/A dict_union N/A args_to_kwargs args init kwargs N/A allocation_arg allocation N/A N/A N/A N/A kwargs setdefault allocation_arg NoneAllocation N/A initialization_arg initialization N/A N/A N/A N/A kwargs setdefault initialization_arg NoneInitialization N/A N/A init kwargs N/A N/A N/A N/A wraps init lazy_init N/A lazy_init N/A N/A lazy_wrapper N/A ApplicationCall N/A Annotation N/A N/A A link between the variable tags and bricks.

    The application call can be used to attach to an apply call auxiliary
    variables (e.g. monitors or regularizers) that do not form part of the
    main computation graph.

    The application call object is created before the call to the
    application method and can be accessed by specifying an
    application_call argument.

    Also see :class:`.Annotation`.

    Parameters
    ----------
    application : :class:`BoundApplication` instance
        The bound application (i.e. belong to a brick instance) object
        being called

    Examples
    --------
    >>> class Foo(Brick):
    ...     @application
    ...     def apply(self, x, application_call):
    ...         application_call.add_auxiliary_variable(x.mean())
    ...         return x + 1
    >>> x = tensor.vector()
    >>> y = Foo().apply(x)
    >>> from blocks.filter import get_application_call
    >>> get_application_call(y) # doctest: +ELLIPSIS
    <blocks.bricks.base.ApplicationCall object at ...>

     __init__ N/A N/A self application N/A N/A N/A N/A self application application N/A N/A self metadata N/A N/A N/A N/A N/A super ApplicationCall self __init__ N/A add_auxiliary_variable N/A N/A self variable roles name N/A None None N/A N/A name N/A N/A N/A variable name N/A _variable_name N/A N/A N/A self application brick name N/A N/A self application name name N/A N/A N/A variable tag name name N/A name None N/A N/A add_annotation variable N/A N/A self application brick N/A N/A N/A N/A super ApplicationCall self add_auxiliary_variable variable roles name N/A N/A application N/A N/A N/A args kwargs N/A N/A Decorator for methods that apply a brick to inputs.

    Parameters
    ----------
    \*args, optional
        The application method to wrap.
    \*\*kwargs, optional
        Attributes to attach to this application.

    Notes
    -----
    This decorator replaces application methods with :class:`Application`
    instances. It also sets the attributes given as keyword arguments to
    the decorator.

    Note that this decorator purposely does not wrap the original method
    using e.g. :func:`~functools.wraps` or
    :func:`~functools.update_wrapper`, since that would make the class
    impossible to pickle (see notes at :class:`Application`).

    Examples
    --------
    >>> class Foo(Brick):
    ...     @application(inputs=['x'], outputs=['y'])
    ...     def apply(self, x):
    ...         return x + 1
    ...     @application
    ...     def other_apply(self, x):
    ...         return x - 1
    >>> foo = Foo()
    >>> Foo.apply.inputs
    ['x']
    >>> foo.apply.outputs
    ['y']
    >>> Foo.other_apply # doctest: +ELLIPSIS
    <blocks.bricks.base.Application object at ...>

     N/A N/A N/A N/A args N/A kwargs N/A N/A args kwargs N/A N/A ValueError N/A args N/A N/A N/A application_function args N/A application N/A Application application_function N/A application N/A wrap_application N/A N/A application_function N/A N/A N/A application N/A Application application_function N/A N/A key value N/A N/A kwargs items N/A N/A N/A setattr application key value N/A application N/A N/A wrap_application N/A _variable_name N/A N/A brick_name application_name name N/A N/A N/A N/A N/A {}_{}_{} format brick_name application_name name N/A