Class Slicing<C,​E>

  • Type Parameters:
    C - the type of coordinate (aka 'the dimension') do be reduced
    E - the type of the tensor elements
    All Implemented Interfaces:
    ReductionStrategy<C,​E,​E>
    Direct Known Subclasses:
    InterpolatedSlicing

    public class Slicing<C,​E>
    extends java.lang.Object
    implements ReductionStrategy<C,​E,​E>
    A reduction strategy, which returns all values of which are at one exact value of the dimension to be reduced.
    • Field Summary

      Fields 
      Modifier and Type Field Description
      protected C slicePosition  
    • Constructor Summary

      Constructors 
      Constructor Description
      Slicing​(C slicePosition)  
    • Method Summary

      All Methods Instance Methods Concrete Methods 
      Modifier and Type Method Description
      Position context​(Position originalContext)  
      E reduce​(java.util.Map<? extends C,​E> inputValues, Position position)  
      • Methods inherited from class java.lang.Object

        clone, equals, finalize, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Field Detail

      • slicePosition

        protected final C slicePosition
    • Constructor Detail

      • Slicing

        public Slicing​(C slicePosition)
    • Method Detail

      • reduce

        public E reduce​(java.util.Map<? extends C,​E> inputValues,
                        Position position)
        Specified by:
        reduce in interface ReductionStrategy<C,​E,​E>
        Parameters:
        inputValues - the sub values of the tensor from which the reduction is performed
        position - a remaining position in the tensor for which reduction is performed
        Returns:
        the value of reduction