当前位置: 首页>>代码示例>>Java>>正文


Java AVLTreeDigest.fromBytes方法代码示例

本文整理汇总了Java中com.tdunning.math.stats.AVLTreeDigest.fromBytes方法的典型用法代码示例。如果您正苦于以下问题:Java AVLTreeDigest.fromBytes方法的具体用法?Java AVLTreeDigest.fromBytes怎么用?Java AVLTreeDigest.fromBytes使用的例子?那么恭喜您, 这里精选的方法代码示例或许可以为您提供帮助。您也可以进一步了解该方法所在com.tdunning.math.stats.AVLTreeDigest的用法示例。


在下文中一共展示了AVLTreeDigest.fromBytes方法的4个代码示例,这些例子默认根据受欢迎程度排序。您可以为喜欢或者感觉有用的代码点赞,您的评价将有助于系统推荐出更棒的Java代码示例。

示例1: read

import com.tdunning.math.stats.AVLTreeDigest; //导入方法依赖的package包/类
@Override
public void read(Kryo kryo, Input input) {
  int digestSize = input.readInt();
  byte[] digestBytes = input.readBytes(digestSize);
  ByteBuffer digestBuff = ByteBuffer.wrap(digestBytes);
  digest = AVLTreeDigest.fromBytes(digestBuff);
  n = input.readLong();
  sum = input.readDouble();
  sumOfSquares = input.readDouble();
  sumOfLogs = input.readDouble();
  min = input.readDouble();
  max = input.readDouble();
  M1 = input.readDouble();
  M2 = input.readDouble();
  M3 = input.readDouble();
  M4 = input.readDouble();
}
 
开发者ID:apache,项目名称:metron,代码行数:18,代码来源:OnlineStatisticsProvider.java

示例2: addIntermediary

import com.tdunning.math.stats.AVLTreeDigest; //导入方法依赖的package包/类
@Override
public void addIntermediary(IntermediaryResultValueIterator intermediary) {
  Long otherComplete = (Long) intermediary.next();
  if (otherComplete == 1L) {
    // only add state if we received some state where the other instance was "complete", i.e. this is the final result
    // of a single other instance of this function. We will not have to remove this state again (we wouldn't be able
    // to anyway).
    SerializedAVLTreeDigest serialized = (SerializedAVLTreeDigest) intermediary.next();
    AVLTreeDigest other = AVLTreeDigest.fromBytes(ByteBuffer.wrap(serialized.getSerialized()));
    tdigest.add(other);
  }
}
 
开发者ID:diqube,项目名称:diqube,代码行数:13,代码来源:QuantileLongFunction.java

示例3: peekLength

import com.tdunning.math.stats.AVLTreeDigest; //导入方法依赖的package包/类
public int peekLength(ByteBuffer in) {
    int mark = in.position();
    AVLTreeDigest.fromBytes(in);
    int total = in.position() - mark;
    in.position(mark);
    return total;
}
 
开发者ID:apache,项目名称:kylin,代码行数:8,代码来源:PercentileCounter.java

示例4: readRegisters

import com.tdunning.math.stats.AVLTreeDigest; //导入方法依赖的package包/类
public void readRegisters(ByteBuffer in) {
    registers = AVLTreeDigest.fromBytes(in);
    compression = registers.compression();
}
 
开发者ID:apache,项目名称:kylin,代码行数:5,代码来源:PercentileCounter.java


注:本文中的com.tdunning.math.stats.AVLTreeDigest.fromBytes方法示例由纯净天空整理自Github/MSDocs等开源代码及文档管理平台,相关代码片段筛选自各路编程大神贡献的开源项目,源码版权归原作者所有,传播和使用请参考对应项目的License;未经允许,请勿转载。