Package de.lmu.ifi.dbs.elki.data

Examples of de.lmu.ifi.dbs.elki.data.ModifiableHyperBoundingBox


    E firstEntry = getEntry(0);
    if(firstEntry == null) {
      return null;
    }
    // Note: we deliberately get a cloned copy here, since we will modify it.
    ModifiableHyperBoundingBox mbr = new ModifiableHyperBoundingBox(firstEntry);
    for(int i = 1; i < numEntries; i++) {
      mbr.extend(getEntry(i));
    }
    return mbr;
  }
View Full Code Here


   *
   * @param entry the entry representing this node
   */
  public boolean adjustEntry(E entry) {
    final SpatialDirectoryEntry se = (SpatialDirectoryEntry) entry;
    final ModifiableHyperBoundingBox mbr = computeMBR();
    boolean changed = false;
    if(se.hasMBR()) {
      final int dim = se.getDimensionality();
      // Test for changes
      for(int i = 1; i <= dim; i++) {
        if(Math.abs(se.getMin(i) - mbr.getMin(i)) > Float.MIN_NORMAL) {
          changed = true;
          break;
        }
        if(Math.abs(se.getMax(i) - mbr.getMax(i)) > Float.MIN_NORMAL) {
          changed = true;
          break;
        }
      }
    }
View Full Code Here

   *         cannot be found.
   */
  @Override
  public void readExternal(ObjectInput in) throws IOException, ClassNotFoundException {
    super.readExternal(in);
    this.mbr = new ModifiableHyperBoundingBox();
    this.mbr.readExternal(in);
  }
View Full Code Here

TOP

Related Classes of de.lmu.ifi.dbs.elki.data.ModifiableHyperBoundingBox

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.