本文整理了Java中org.apache.mahout.math.Vector.getIteratorAdvanceCost()
方法的一些代码示例,展示了Vector.getIteratorAdvanceCost()
的具体用法。这些代码示例主要来源于Github
/Stackoverflow
/Maven
等平台,是从一些精选项目中提取出来的代码,具有较强的参考意义,能在一定程度帮忙到你。Vector.getIteratorAdvanceCost()
方法的具体详情如下:
包路径:org.apache.mahout.math.Vector
类名称:Vector
方法名:getIteratorAdvanceCost
[英]Gets an estimate of the cost (in number of operations) it takes to advance an iterator through the nonzero elements of this vector.
[中]获取通过此向量的非零元素推进迭代器所需的成本(以操作数为单位)的估计值。
代码示例来源:origin: apache/mahout
@Override
public double getIteratorAdvanceCost() {
// TODO: remove the 2x after fixing the Element iterator
return 2 * vector.getIteratorAdvanceCost();
}
代码示例来源:origin: apache/mahout
@Override
public double getIteratorAdvanceCost() {
return delegate.getIteratorAdvanceCost();
}
代码示例来源:origin: apache/mahout
@Override
public double getIteratorAdvanceCost() {
return delegate.getIteratorAdvanceCost();
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction f) {
return Math.min(x.getNumNondefaultElements() * x.getIteratorAdvanceCost(),
y.getNumNondefaultElements() * y.getIteratorAdvanceCost());
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction f) {
return Math.max(x.getNumNondefaultElements() * x.getIteratorAdvanceCost(),
y.getNumNondefaultElements() * y.getIteratorAdvanceCost());
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction fa, DoubleDoubleFunction fc) {
return Math.min(x.getNumNondefaultElements() * x.getIteratorAdvanceCost(),
y.getNumNondefaultElements() * y.getIteratorAdvanceCost());
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction f) {
return Math.max(x.getNumNondefaultElements() * x.getIteratorAdvanceCost(),
y.getNumNondefaultElements() * y.getIteratorAdvanceCost());
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction fa, DoubleDoubleFunction fc) {
return Math.max(x.getNumNondefaultElements() * x.getIteratorAdvanceCost(),
y.getNumNondefaultElements() * y.getIteratorAdvanceCost());
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction fa, DoubleDoubleFunction fc) {
return Math.max(x.size() * x.getIteratorAdvanceCost(), y.size() * y.getIteratorAdvanceCost());
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction f) {
return Math.max(x.size() * x.getIteratorAdvanceCost(), y.size() * y.getIteratorAdvanceCost());
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction fa, DoubleDoubleFunction fc) {
return Math.max(x.getNumNondefaultElements() * x.getIteratorAdvanceCost() * y.getLookupCost(),
y.getNumNondefaultElements() * y.getIteratorAdvanceCost() * x.getLookupCost());
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction f) {
return Math.max(x.getNumNondefaultElements() * x.getIteratorAdvanceCost() * y.getLookupCost(),
y.getNumNondefaultElements() * y.getIteratorAdvanceCost() * x.getLookupCost());
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction f) {
return Math.max(x.getNumNondefaultElements() * x.getIteratorAdvanceCost() * y.getLookupCost(),
y.getNumNondefaultElements() * y.getIteratorAdvanceCost() * x.getLookupCost());
}
@Override
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction f) {
return x.size() * x.getIteratorAdvanceCost() * y.getLookupCost();
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction fa, DoubleDoubleFunction fc) {
return x.getNumNondefaultElements() * x.getIteratorAdvanceCost() * y.getLookupCost();
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction fa, DoubleDoubleFunction fc) {
return x.size() * x.getIteratorAdvanceCost() * y.getLookupCost();
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction f) {
return x.getNumNondefaultElements() * x.getIteratorAdvanceCost() * y.getLookupCost();
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction f) {
return y.size() * y.getIteratorAdvanceCost() * x.getLookupCost();
}
代码示例来源:origin: apache/mahout
@Override
public double getIteratorAdvanceCost() {
return (rowToColumn ? matrix.viewColumn(0) : matrix.viewRow(0)).getIteratorAdvanceCost();
}
代码示例来源:origin: apache/mahout
@Override
public double estimateCost(Vector x, Vector y, DoubleDoubleFunction fa, DoubleDoubleFunction fc) {
return y.size() * y.getIteratorAdvanceCost() * x.getLookupCost();
}
内容来源于网络,如有侵权,请联系作者删除!