ucar.multiarray
Class DecimateMap
java.lang.Object
ucar.multiarray.ConcreteIndexMap
ucar.multiarray.DecimateMap
- All Implemented Interfaces:
- IndexMap
public class DecimateMap
- extends ConcreteIndexMap
Use with MultiArrayProxy to reduce the length along a particular
dimension by sampling the domain according to a (repeated) pattern.
- Version:
- $Revision: 1.2 $ $Date: 2002/05/29 20:32:38 $
- Author:
- $Author: steve $
- See Also:
IndexMap
,
MultiArrayProxy
Constructor Summary |
DecimateMap(ConcreteIndexMap prev,
int position,
boolean[] pattern)
Create an ConcreteIndexMap which decimates along
a specific dimension. |
DecimateMap(int position,
boolean[] pattern)
Create an ConcreteIndexMap which decimates along
a specific dimension. |
Methods inherited from class ucar.multiarray.ConcreteIndexMap |
getLengths, getOutputLength, getRank, getTransformed, init, init, link, link, setInput, setLengths, toString, transform |
DecimateMap
public DecimateMap(int position,
boolean[] pattern)
- Create an ConcreteIndexMap which decimates along
a specific dimension.
Using this in an MultiArrayProxy will result in the
the length of dimension
position
appearing
smaller. The values which will show through are selected
by the pattern argument.
- Parameters:
position
- the dimension number to clip alongpattern
- index values along the dimension will
show through where pattern is set to true
.
If pattern.length is less than the source dimension length,
the pattern is repeated.
DecimateMap
public DecimateMap(ConcreteIndexMap prev,
int position,
boolean[] pattern)
- Create an ConcreteIndexMap which decimates along
a specific dimension.
Using this in an MultiArrayProxy will result in the
the length of dimension
position
appearing
smaller. The values which will show through are selected
by the pattern argument.
- Parameters:
prev
- ConcreteIndexMap to be composed with this.position
- the dimension number to clip alongpattern
- index values along the dimension will
show through where pattern is set to true
.
If pattern.length is less than the source dimension length,
the pattern is repeated.
main
public static void main(String[] args)