Codota Logo
AGNES.getDistanceFunction
Code IndexAdd Codota to your IDE (free)

How to use
getDistanceFunction
method
in
de.lmu.ifi.dbs.elki.algorithm.clustering.hierarchical.AGNES

Best Java code snippets using de.lmu.ifi.dbs.elki.algorithm.clustering.hierarchical.AGNES.getDistanceFunction (Showing top 8 results out of 315)

  • Add the Codota plugin to your IDE and get smart completions
private void myMethod () {
FileOutputStream f =
  • Codota IconFile file;new FileOutputStream(file)
  • Codota IconString name;new FileOutputStream(name)
  • Codota IconFile file;new FileOutputStream(file, true)
  • Smart code suggestions by Codota
}
origin: de.lmu.ifi.dbs.elki/elki-clustering

@Override
public TypeInformation[] getInputTypeRestriction() {
 // The input relation must match our distance function:
 return TypeUtil.array(getDistanceFunction().getInputTypeRestriction());
}
origin: elki-project/elki

@Override
public TypeInformation[] getInputTypeRestriction() {
 // The input relation must match our distance function:
 return TypeUtil.array(getDistanceFunction().getInputTypeRestriction());
}
origin: de.lmu.ifi.dbs.elki/elki

@Override
public TypeInformation[] getInputTypeRestriction() {
 // The input relation must match our distance function:
 return TypeUtil.array(getDistanceFunction().getInputTypeRestriction());
}
origin: de.lmu.ifi.dbs.elki/elki

DistanceQuery<O> dq = db.getDistanceQuery(relation, getDistanceFunction());
ArrayDBIDs ids = DBIDUtil.ensureArray(relation.getDBIDs());
final int size = ids.size();
boolean square = WardLinkageMethod.class.isInstance(linkage) && !(SquaredEuclideanDistanceFunction.class.isInstance(getDistanceFunction()));
initializeDistanceMatrix(scratch, dq, ix, iy, square);
origin: de.lmu.ifi.dbs.elki/elki-clustering

DistanceQuery<O> dq = db.getDistanceQuery(relation, getDistanceFunction());
origin: elki-project/elki

DistanceQuery<O> dq = db.getDistanceQuery(relation, getDistanceFunction());
origin: de.lmu.ifi.dbs.elki/elki-clustering

/**
 * Execute the cluster merge.
 *
 * @param end Active set size
 * @param mat Matrix paradigm
 * @param builder Hierarchy builder
 * @param mindist Distance that was used for merging
 * @param x First matrix position
 * @param y Second matrix position
 */
protected void merge(int end, MatrixParadigm mat, PointerHierarchyRepresentationBuilder builder, double mindist, int x, int y) {
 // Avoid allocating memory, by reusing existing iterators:
 final DBIDArrayIter ix = mat.ix.seek(x), iy = mat.iy.seek(y);
 if(LOG.isDebuggingFine()) {
  LOG.debugFine("Merging: " + DBIDUtil.toString(ix) + " -> " + DBIDUtil.toString(iy) + " " + mindist);
 }
 // Perform merge in data structure: x -> y
 assert (y < x);
 // Since y < x, prefer keeping y, dropping x.
 builder.add(ix, linkage.restore(mindist, getDistanceFunction().isSquared()), iy);
 // Update cluster size for y:
 final int sizex = builder.getSize(ix), sizey = builder.getSize(iy);
 builder.setSize(iy, sizex + sizey);
 updateMatrix(end, mat, builder, mindist, x, y, sizex, sizey);
}
origin: elki-project/elki

/**
 * Execute the cluster merge.
 *
 * @param end Active set size
 * @param mat Matrix paradigm
 * @param builder Hierarchy builder
 * @param mindist Distance that was used for merging
 * @param x First matrix position
 * @param y Second matrix position
 */
protected void merge(int end, MatrixParadigm mat, PointerHierarchyRepresentationBuilder builder, double mindist, int x, int y) {
 // Avoid allocating memory, by reusing existing iterators:
 final DBIDArrayIter ix = mat.ix.seek(x), iy = mat.iy.seek(y);
 if(LOG.isDebuggingFine()) {
  LOG.debugFine("Merging: " + DBIDUtil.toString(ix) + " -> " + DBIDUtil.toString(iy) + " " + mindist);
 }
 // Perform merge in data structure: x -> y
 assert (y < x);
 // Since y < x, prefer keeping y, dropping x.
 builder.add(ix, linkage.restore(mindist, getDistanceFunction().isSquared()), iy);
 // Update cluster size for y:
 final int sizex = builder.getSize(ix), sizey = builder.getSize(iy);
 builder.setSize(iy, sizex + sizey);
 updateMatrix(end, mat, builder, mindist, x, y, sizex, sizey);
}
de.lmu.ifi.dbs.elki.algorithm.clustering.hierarchicalAGNESgetDistanceFunction

Popular methods of AGNES

  • <init>
    Constructor.
  • findMerge
    Perform the next merge step in AGNES.
  • initializeDistanceMatrix
    Initialize a distance matrix.
  • merge
    Execute the cluster merge.
  • updateMatrix
    Update the scratch distance matrix.
  • shrinkActiveSet
    Shrink the active set: if the last x objects are all merged, we can reduce the working size accordin
  • triangleSize
    Compute the size of a complete x by x triangle (minus diagonal)

Popular in Java

  • Running tasks concurrently on multiple threads
  • addToBackStack (FragmentTransaction)
  • onRequestPermissionsResult (Fragment)
  • getSharedPreferences (Context)
  • BigDecimal (java.math)
    An immutable arbitrary-precision signed decimal.A value is represented by an arbitrary-precision "un
  • Comparator (java.util)
    A Comparator is used to compare two objects to determine their ordering with respect to each other.
  • HashMap (java.util)
    HashMap is an implementation of Map. All optional operations are supported.All elements are permitte
  • Queue (java.util)
    A collection designed for holding elements prior to processing. Besides basic java.util.Collection o
  • Handler (java.util.logging)
    A Handler object accepts a logging request and exports the desired messages to a target, for example
  • JCheckBox (javax.swing)
Codota Logo
  • Products

    Search for Java codeSearch for JavaScript codeEnterprise
  • IDE Plugins

    IntelliJ IDEAWebStormAndroid StudioEclipseVisual Studio CodePyCharmSublime TextPhpStormVimAtomGoLandRubyMineEmacsJupyter
  • Company

    About UsContact UsCareers
  • Resources

    FAQBlogCodota Academy Plugin user guide Terms of usePrivacy policyJava Code IndexJavascript Code Index
Get Codota for your IDE now