public HashedVector(Vector vector, Matrix projection, int index, long mask) { super(vector, 1, index); this.hash = mask & computeHash64(vector, projection); }
public static HashedVector hash(WeightedVector v, Matrix projection, long mask) { return new HashedVector(v, projection, mask); }
private PriorityQueue<WeightedThing<Vector>> searchInternal(Vector query) { long queryHash = HashedVector.computeHash64(query, projection); int bitDot = vector.hammingDistance(queryHash); if (bitDot <= hashLimit) { distanceEvaluations++;
@Override public Vector apply(org.apache.mahout.math.neighborhood.HashedVector input) { Preconditions.checkNotNull(input); //noinspection ConstantConditions return input.getVector(); } });
public static HashedVector hash(WeightedVector v, Matrix projection) { return hash(v, projection, 0); }
private PriorityQueue<WeightedThing<Vector>> searchInternal(Vector query) { long queryHash = HashedVector.computeHash64(query, projection); int bitDot = vector.hammingDistance(queryHash); if (bitDot <= hashLimit) { distanceEvaluations++;
@Override public Vector apply(org.apache.mahout.math.neighborhood.HashedVector input) { Preconditions.checkNotNull(input); //noinspection ConstantConditions return input.getVector(); } });
public static HashedVector hash(WeightedVector v, Matrix projection) { return hash(v, projection, 0); }
private PriorityQueue<WeightedThing<Vector>> searchInternal(Vector query) { long queryHash = HashedVector.computeHash64(query, projection); int bitDot = vector.hammingDistance(queryHash); if (bitDot <= hashLimit) { distanceEvaluations++;
public HashedVector(Vector vector, Matrix projection, int index, long mask) { super(vector, 1, index); this.hash = mask & computeHash64(vector, projection); }
public static HashedVector hash(WeightedVector v, Matrix projection, long mask) { return new HashedVector(v, projection, mask); }
@Override public Vector apply(org.apache.mahout.math.neighborhood.HashedVector input) { Preconditions.checkNotNull(input); //noinspection ConstantConditions return input.getVector(); } });
public static HashedVector hash(WeightedVector v, Matrix projection) { return hash(v, projection, 0); }
public HashedVector(Vector vector, Matrix projection, int index, long mask) { super(vector, 1, index); this.hash = mask & computeHash64(vector, projection); }