net.imglib2.util.Util.min()方法的使用及代码示例

x33g5p2x  于2022-02-01 转载在 其他  
字(4.1k)|赞(0)|评价(0)|浏览(166)

本文整理了Java中net.imglib2.util.Util.min()方法的一些代码示例,展示了Util.min()的具体用法。这些代码示例主要来源于Github/Stackoverflow/Maven等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Util.min()方法的具体详情如下:
包路径:net.imglib2.util.Util
类名称:Util
方法名:min

Util.min介绍

[英]Writes min(a,b) into a
[中]将min(a,b)写入a

代码示例

代码示例来源:origin: fiji/TrackMate

@Override
public boolean checkInput()
{
  if ( cm.nRows > cm.nCols )
  {
    errorMessage = BASE_ERROR_MESSAGE + "This solver converges only if the cost matrix has more rows than column. Found " + cm.nRows + " rows and " + cm.nCols + " columns.";
    return false;
  }
  final double minCost = Util.min( cm.cc );
  if ( minCost < 0 )
  {
    errorMessage = BASE_ERROR_MESSAGE + "This solver only accept positive costs. Found " + minCost + ".";
    return false;
  }
  return true;
}

代码示例来源:origin: sc.fiji/TrackMate_

@Override
public boolean checkInput()
{
  if ( cm.nRows > cm.nCols )
  {
    errorMessage = BASE_ERROR_MESSAGE + "This solver converges only if the cost matrix has more rows than column. Found " + cm.nRows + " rows and " + cm.nCols + " columns.";
    return false;
  }
  final double minCost = Util.min( cm.cc );
  if ( minCost < 0 )
  {
    errorMessage = BASE_ERROR_MESSAGE + "This solver only accept positive costs. Found " + minCost + ".";
    return false;
  }
  return true;
}

代码示例来源:origin: net.imglib2/imglib2-algorithm

if ( Util.min( min, value ) == value )
  min.set( value );

代码示例来源:origin: net.imglib2/imglib2-algorithms

if ( Util.min( min, value ) == value )
  min.set( value );

代码示例来源:origin: net.imagej/imagej-common

if (Util.min(min, value) == value) min.set(value);

代码示例来源:origin: sc.fiji/TrackMate_

final double minCost = Math.min( Util.min( ccbl ), Util.min( cctr ) );
final SparseCostMatrix br = tl.transpose();
br.fillWith( minCost );

代码示例来源:origin: net.preibisch/multiview-reconstruction

Util.min( rMin, g );
Util.max( rMax, g );

代码示例来源:origin: net.imglib2/imglib2-realtransform

Util.min( rMin, g );
Util.max( rMax, g );
f[ 2 ] = min[ 2 ];
apply( f, g );
Util.min( rMin, g );
Util.max( rMax, g );
f[ 2 ] = min[ 2 ];
apply( f, g );
Util.min( rMin, g );
Util.max( rMax, g );
f[ 2 ] = min[ 2 ];
apply( f, g );
Util.min( rMin, g );
Util.max( rMax, g );
f[ 2 ] = max[ 2 ];
apply( f, g );
Util.min( rMin, g );
Util.max( rMax, g );
f[ 2 ] = max[ 2 ];
apply( f, g );
Util.min( rMin, g );
Util.max( rMax, g );
f[ 2 ] = max[ 2 ];

代码示例来源:origin: fiji/TrackMate

final double minCost = Math.min( Util.min( ccbl ), Util.min( cctr ) );
final SparseCostMatrix br = tl.transpose();
br.fillWith( minCost );

代码示例来源:origin: net.imglib2/imglib2-algorithm

final int maxD = sigma.length;
final double minSigma = Util.min(  sigma );
final double minSigmaSq = minSigma * minSigma;
final double[] sigmaSquared = new double[ sigma.length * ( sigma.length + 1 ) / 2 ];

代码示例来源:origin: net.preibisch/multiview-reconstruction

Util.min( max, maxI );

代码示例来源:origin: net.imglib2/imglib2-algorithm

protected void compute( final long startPos, final long loopSize, final T min, final T max )
{
  final Cursor< T > cursor = image.cursor();
  // init min and max
  cursor.fwd();
  min.set( cursor.get() );
  max.set( cursor.get() );
  cursor.reset();
  // move to the starting position of the current thread
  cursor.jumpFwd( startPos );
  // do as many pixels as wanted by this thread
  for ( long j = 0; j < loopSize; ++j )
  {
    cursor.fwd();
    final T value = cursor.get();
    if ( Util.min( min, value ) == value )
      min.set( value );
    if ( Util.max( max, value ) == value )
      max.set( value );
  }
}

代码示例来源:origin: net.imglib2/imglib2-algorithms

protected void compute( final long startPos, final long loopSize, final T min, final T max )
{
  final Cursor<T> cursor = image.cursor();
  
  // init min and max
  cursor.fwd();
  
  min.set( cursor.get() );
  max.set( cursor.get() );
  
  cursor.reset();
  // move to the starting position of the current thread
  cursor.jumpFwd( startPos );        
  // do as many pixels as wanted by this thread
  for ( long j = 0; j < loopSize; ++j )
  {
    cursor.fwd();
    
    final T value = cursor.get();
    
    if ( Util.min( min, value ) == value )
      min.set( value );
    
    if ( Util.max( max, value ) == value )
      max.set( value );
  }
}

代码示例来源:origin: net.imagej/imagej-common

protected void compute(final int threadNumber, final long startPos, final long loopSize, final T min,
  final T max)
{
  final Cursor<T> cursor = image.cursor();
  // init min and max
  cursor.fwd();
  min.set(cursor.get());
  max.set(cursor.get());
  cursor.reset();
  // move to the starting position of the current thread
  cursor.jumpFwd(startPos);
  // do as many pixels as wanted by this thread
  for (long j = 0; j < loopSize; ++j) {
    cursor.fwd();
    final T value = cursor.get();
    if (Util.min(min, value) == value) min.set(value);
    if (Util.max(max, value) == value) max.set(value);
    report(threadNumber);
  }
}

相关文章