'Retrieves the output shape tuple(s) of a layer.
Only applicable if the layer has one inbound node,
or if all inbound nodes have the same output shape.
# Returns
Output shape tuple
(or list of input shape tuples, one tuple per output tensor).
# Raises
AttributeError: if the layer is connected to
more than one incoming layers.'

@property
def output_shape(self):

    if (not self.inbound_nodes):
        raise AttributeError('The    layer    has    never    been    called    and    thus    has    no    defined    output    shape.')
    all_output_shapes = set([str(node.output_shapes) for node in self.inbound_nodes])
    if (len(all_output_shapes) == 1):
        output_shapes = self.inbound_nodes[0].output_shapes
        if (len(output_shapes) == 1):
            return output_shapes[0]
        else:
            return output_shapes
    else:
        raise AttributeError((('The    layer    "' + str(self.name)) + '    has    multiple    inbound    nodes,    with    different    output    shapes.    Hence    the    notion    of    "output    shape"    is    ill-defined    for    the    layer.    Use    `get_output_shape_at(node_index)`    instead.'))
