Package de.lmu.ifi.dbs.elki.distance.distancevalue

Examples of de.lmu.ifi.dbs.elki.distance.distancevalue.DoubleDistance


        double c2 = (mbr2.getMin(d) + mbr2.getMax(d)) / 2;

        double manhattanI = c1 - c2;
        sqrDist += manhattanI * manhattanI;
      }
      return new DoubleDistance(Math.sqrt(sqrDist));
    }
View Full Code Here


      distance = cache.getRecordBuffer(id1.getIntegerID(), id2.getIntegerID()).getDouble();
    }
    catch(IOException e) {
      throw new RuntimeException("Read error when loading distance " + id1 + "," + id2 + " from cache file.", e);
    }
    return new DoubleDistance(distance);
  }
View Full Code Here

    this.dimensions = dimensions;
  }

  @Override
  public DoubleDistance distance(V o1, V o2) {
    return new DoubleDistance(doubleDistance(o1, o2));
  }
View Full Code Here

    return Math.abs(manhattan);
  }

  @Override
  public DoubleDistance distance(NumberVector<?, ?> o1, NumberVector<?, ?> o2) {
    return new DoubleDistance(doubleDistance(o1, o2));
  }
View Full Code Here

    return new DoubleDistance(doubleDistance(o1, o2));
  }

  @Override
  public DoubleDistance minDist(SpatialComparable mbr1, SpatialComparable mbr2) {
    return new DoubleDistance(doubleMinDist(mbr1, mbr2));
  }
View Full Code Here

    return Math.pow(sqrDist, 1. / p);
  }

  @Override
  public DoubleDistance minDist(SpatialComparable mbr1, SpatialComparable mbr2) {
    return new DoubleDistance(doubleMinDist(mbr1, mbr2));
  }
View Full Code Here

    return new DoubleDistance(doubleMinDist(mbr1, mbr2));
  }

  @Override
  public DoubleDistance norm(NumberVector<?, ?> obj) {
    return new DoubleDistance(doubleNorm(obj));
  }
View Full Code Here

    super();
  }

  @Override
  public DoubleDistance minDist(SpatialComparable mbr1, SpatialComparable mbr2) {
    return new DoubleDistance(doubleMinDist(mbr1, mbr2));
  }
View Full Code Here

      distance = cache.getRecordBuffer(id1.getIntegerID(), id2.getIntegerID()).getDouble();
    }
    catch(IOException e) {
      throw new RuntimeException("Read error when loading distance " + id1 + "," + id2 + " from cache file.", e);
    }
    return new DoubleDistance(distance);
  }
View Full Code Here

    public abstract double transform(double similarity);

    @Override
    public DoubleDistance distance(DBID id1, DBID id2) {
      final NumberDistance<?, ?> sim = similarityQuery.similarity(id1, id2);
      return new DoubleDistance(transform(sim.doubleValue()));
    }
View Full Code Here

TOP

Related Classes of de.lmu.ifi.dbs.elki.distance.distancevalue.DoubleDistance

Copyright © 2018 www.massapicom. All rights reserved.
All source code are property of their respective owners. Java is a trademark of Sun Microsystems, Inc and owned by ORACLE Inc. Contact coftware#gmail.com.