Class IntervalChunks
java.lang.Object
net.imglib2.loops.IntervalChunks
-
Constructor Summary
Constructors -
Method Summary
Modifier and TypeMethodDescriptionchunkInterval(Interval interval, int numberOfChunks) Returns a list of disjoint intervals, that covers the given interval.(package private) static longdivideAndRoundUp(long a, long b) Returns a divided by b, and round up.generateGrid(Interval interval, long[] cellDimensions) Returns a list of disjoint intervals, that covers the given interval.(package private) static long[]suggestChunkSize(long[] dimensions, long numberOfChunks) Suggest a chunk size that can be used, to divide an interval of the given dimensions, into the given number of chunks.
-
Constructor Details
-
IntervalChunks
public IntervalChunks()
-
-
Method Details
-
chunkInterval
Returns a list of disjoint intervals, that covers the given interval.Due to the divisibility of whole numbers, it not always easy to return the correct number of intervals, in that case this method returns a larger number of intervals.
-
suggestChunkSize
static long[] suggestChunkSize(long[] dimensions, long numberOfChunks) Suggest a chunk size that can be used, to divide an interval of the given dimensions, into the given number of chunks. -
generateGrid
Returns a list of disjoint intervals, that covers the given interval. The dimension of returned intervals are equal to the given cellDimensions. With the exception of the intervals that are at the border of the given interval. These can be smaller. -
divideAndRoundUp
static long divideAndRoundUp(long a, long b) Returns a divided by b, and round up.
-