Skip to content

Commit

Permalink
simplify
Browse files Browse the repository at this point in the history
  • Loading branch information
tpietzsch committed Sep 24, 2024
1 parent 1a5d951 commit 649fb88
Showing 1 changed file with 1 addition and 1 deletion.
Original file line number Diff line number Diff line change
Expand Up @@ -1261,7 +1261,7 @@ private static <T extends NumericType<T>> RandomAccessibleInterval<T> downsample
final RandomAccessibleInterval<T> img, final long[] downsampleFactors) {

// ensure downsampleFactors contains only 1's and 2's
assert Arrays.stream(downsampleFactors).filter(x -> (x == 1) || (x == 2)).count() == downsampleFactors.length;
assert Arrays.stream(downsampleFactors).allMatch(x -> (x == 1) || (x == 2));

final int nd = downsampleFactors.length;
final double[] scale = new double[nd];
Expand Down

0 comments on commit 649fb88

Please sign in to comment.