Skip to content

Commit

Permalink
Let DefaultFeatureRangeCalculator return expected values in cases fea…
Browse files Browse the repository at this point in the history
…tures contain NaN values
  • Loading branch information
stefanhahmann authored and tinevez committed Mar 22, 2024
1 parent f786209 commit 421f17d
Showing 1 changed file with 1 addition and 0 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -67,6 +67,7 @@ public double[] computeMinMax( final FeatureProjectionId id )

final DoubleSummaryStatistics stats = objs.stream()
.filter( projection::isSet )
.filter( object -> !Double.isNaN( projection.value( object ) ) )
.mapToDouble( projection::value )
.summaryStatistics();
return new double[] { stats.getMin(), stats.getMax() };
Expand Down

0 comments on commit 421f17d

Please sign in to comment.