parameters: (self, x, sample=True, batch=True, event=True, name='get_shape')
docstring: Returns subset of tensor's shape (size of dimensions).
  
      Args:
        x: `Tensor`.
        sample: `Boolean`. Include sample shape or not.
        batch: `Boolean`. Include batch shape or not.
        event: `Boolean`. Include event shape or not.
        name: `String`. The name to give this op.
  
      Raises:
        ValueError: if `x.get_shape().ndims` is `None`
  
      Returns:
        List describing event shape if known statically, `Tensor` otherwise.
docstring_summary: Returns subset of tensor's shape (size of dimensions).
docstring_tokens: Returns subset of tensor s shape ( size of dimensions ) .
function: def get_shape(self, x, sample=True, batch=True, event=True, name='get_shape'):
      """Returns subset of tensor's shape (size of dimensions).
  
      Args:
        x: `Tensor`.
        sample: `Boolean`. Include sample shape or not.
        batch: `Boolean`. Include batch shape or not.
        event: `Boolean`. Include event shape or not.
        name: `String`. The name to give this op.
  
      Raises:
        ValueError: if `x.get_shape().ndims` is `None`
  
      Returns:
        List describing event shape if known statically, `Tensor` otherwise.
      """
      if not sample and not batch and not event:
        return []
      with ops.name_scope(self._name):
        with ops.op_scope([x], name):
          x = ops.convert_to_tensor(x)
          shape = (x.get_shape().as_list()
                   if x.get_shape().is_fully_defined()
                   else array_ops.shape(x))
  
          if sample and batch and event:
            return shape
  
          sample_start = 0
          batch_start = self.get_sample_ndims(x)
          event_start = batch_start + self.batch_ndims
  
          sample_shape = shape[sample_start:batch_start] if sample else []
          batch_shape = shape[batch_start:event_start] if batch else []
          event_shape = shape[event_start:] if event else []
  
          if not batch and not event:
            return sample_shape
          if not sample and not event:
            return batch_shape
          if not sample and not batch:
            return event_shape
  
          if x.get_shape().is_fully_defined():
            return sample_shape + batch_shape + event_shape
          else:
            return array_ops.concat(0, [sample_shape, batch_shape, event_shape])
function_tokens: def get_shape ( self , x , sample = True , batch = True , event = True , name = 'get_shape' ) : if not sample and not batch and not event : return [ ] with ops . name_scope ( self . _name ) : with ops . op_scope ( [ x ] , name ) : x = ops . convert_to_tensor ( x ) shape = ( x . get_shape ( ) . as_list ( ) if x . get_shape ( ) . is_fully_defined ( ) else array_ops . shape ( x ) ) if sample and batch and event : return shape sample_start = 0 batch_start = self . get_sample_ndims ( x ) event_start = batch_start + self . batch_ndims sample_shape = shape [ sample_start : batch_start ] if sample else [ ] batch_shape = shape [ batch_start : event_start ] if batch else [ ] event_shape = shape [ event_start : ] if event else [ ] if not batch and not event : return sample_shape if not sample and not event : return batch_shape if not sample and not batch : return event_shape if x . get_shape ( ) . is_fully_defined ( ) : return sample_shape + batch_shape + event_shape else : return array_ops . concat ( 0 , [ sample_shape , batch_shape , event_shape ] )