class_docstr: This layer performs an elementwise merge of its input layers.
  It requires all input layers to have the same output shape.
  
  Parameters
  ----------
  incomings : a list of :class:`Layer` instances or tuples
      the layers feeding into this layer, or expected input shapes,
      with all incoming shapes being equal
  
  merge_function : callable
      the merge function to use. Should take two arguments and return the
      updated value. Some possible merge functions are ``theano.tensor``:
      ``mul``, ``add``, ``maximum`` and ``minimum``.
  
  cropping : None or [crop]
      Cropping for each input axis. Cropping is described in the docstring
      for :func:`autocrop`
  
  See Also
  --------
  ElemwiseSumLayer : Shortcut for sum layer.
class_docstr_tok: ["This","layer","performs","an","elementwise","merge","of","its","input","layers",".","It","requires","all","input","layers","to","have","the","same","output","shape",".","Parameters","--","--","--","--","--","incomings",":","a","list","of",":","class",":","`","Layer","`","instances","or","tuples","the","layers","feeding","into","this","layer",",","or","expected","input","shapes",",","with","all","incoming","shapes","being","equal","merge_function",":","callable","the","merge","function","to","use",".","Should","take","two","arguments","and","return","the","updated","value",".","Some","possible","merge","functions","are","``","theano.tensor","``",":","``","mul","``",",","``","add","``",",","``","maximum","``","and","``","minimum","``",".","cropping",":","None","or","[","crop","]","Cropping","for","each","input","axis",".","Cropping","is","described","in","the","docstring","for",":","func",":","`","autocrop","`","See","Also","--","--","--","--","ElemwiseSumLayer",":","Shortcut","for","sum","layer","."]
code: def get_output_shape_for(self, input_shapes):
      input_shapes = autocrop_array_shapes(input_shapes, self.cropping)
      # Infer the output shape by grabbing, for each axis, the first
      # input size that is not `None` (if there is any)
      output_shape = tuple(
          next((s for s in sizes if s is not None), None)
          for sizes in zip(*input_shapes)
      )
  
      def match(shape1, shape2):
          return len(shape1) == len(shape2) and all(
              s1 is None or s2 is None or s1 == s2
              for s1, s2 in zip(shape1, shape2)
          )
  
      # Check for compatibility with inferred output shape
      if not all(match(shape, output_shape) for shape in input_shapes):
          raise ValueError(
              "Mismatch: not all input shapes are the same"
          )
      return output_shape
  
file_path: Lasagne/lasagne/layers/merge.py
imports: import theano.tensor
  from .base import MergeLayer
label_desc: Use image node_id 2 for calling the ElemwiseMergeLayer obj's underlying member method code with example usage: obj.get_output_shape_for(input_shapes) and returns: output_shape, unknown