public final class Vectors extends Object
Modifier and Type | Method and Description |
---|---|
static Vector |
maybeSample(Vector original,
int sampleSize) |
static Vector |
merge(Iterable<VectorWritable> partialVectors) |
static Vector |
read(org.apache.hadoop.fs.Path path,
org.apache.hadoop.conf.Configuration conf) |
static OpenIntIntHashMap |
readAsIntMap(org.apache.hadoop.fs.Path path,
org.apache.hadoop.conf.Configuration conf) |
static Vector |
sum(Iterator<VectorWritable> vectors) |
static Vector.Element[] |
toArray(VectorWritable vectorWritable) |
static Vector |
topKElements(int k,
Vector original) |
static void |
write(Vector vector,
org.apache.hadoop.fs.Path path,
org.apache.hadoop.conf.Configuration conf) |
static void |
write(Vector vector,
org.apache.hadoop.fs.Path path,
org.apache.hadoop.conf.Configuration conf,
boolean laxPrecision) |
public static Vector merge(Iterable<VectorWritable> partialVectors)
public static Vector sum(Iterator<VectorWritable> vectors)
public static Vector.Element[] toArray(VectorWritable vectorWritable)
public static void write(Vector vector, org.apache.hadoop.fs.Path path, org.apache.hadoop.conf.Configuration conf) throws IOException
IOException
public static void write(Vector vector, org.apache.hadoop.fs.Path path, org.apache.hadoop.conf.Configuration conf, boolean laxPrecision) throws IOException
IOException
public static OpenIntIntHashMap readAsIntMap(org.apache.hadoop.fs.Path path, org.apache.hadoop.conf.Configuration conf) throws IOException
IOException
public static Vector read(org.apache.hadoop.fs.Path path, org.apache.hadoop.conf.Configuration conf) throws IOException
IOException
Copyright © 2008–2017 The Apache Software Foundation. All rights reserved.