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

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

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

  • Common ways to obtain HDBSCANLinearMemory
private void myMethod () {
HDBSCANLinearMemory h =
  • Codota IconDistanceFunction distanceFunction;new HDBSCANLinearMemory<>(distanceFunction, minPts)
  • Smart code suggestions by Codota
}
origin: elki-project/elki

@Override
public TypeInformation[] getInputTypeRestriction() {
 return TypeUtil.array(getDistanceFunction().getInputTypeRestriction());
}
origin: de.lmu.ifi.dbs.elki/elki-clustering

@Override
public TypeInformation[] getInputTypeRestriction() {
 return TypeUtil.array(getDistanceFunction().getInputTypeRestriction());
}
origin: de.lmu.ifi.dbs.elki/elki

@Override
public TypeInformation[] getInputTypeRestriction() {
 return TypeUtil.array(getDistanceFunction().getInputTypeRestriction());
}
origin: de.lmu.ifi.dbs.elki/elki

/**
 * Run the algorithm
 *
 * @param db Database
 * @param relation Relation
 * @return Clustering hierarchy
 */
public PointerDensityHierarchyRepresentationResult run(Database db, Relation<O> relation) {
 final DistanceQuery<O> distQ = db.getDistanceQuery(relation, getDistanceFunction());
 final KNNQuery<O> knnQ = db.getKNNQuery(distQ, minPts);
 // We need array addressing later.
 final ArrayDBIDs ids = DBIDUtil.ensureArray(relation.getDBIDs());
 // 1. Compute the core distances
 // minPts + 1: ignore query point.
 final WritableDoubleDataStore coredists = computeCoreDists(ids, knnQ, minPts);
 final int numedges = ids.size() - 1;
 DoubleLongHeap heap = new DoubleLongMinHeap(numedges);
 // 2. Build spanning tree.
 FiniteProgress mprog = LOG.isVerbose() ? new FiniteProgress("Computing minimum spanning tree (n-1 edges)", numedges, LOG) : null;
 PrimsMinimumSpanningTree.processDense(ids,//
   new HDBSCANAdapter(ids, coredists, distQ), //
   new HeapMSTCollector(heap, mprog, LOG));
 LOG.ensureCompleted(mprog);
 // Storage for pointer representation:
 WritableDBIDDataStore pi = DataStoreUtil.makeDBIDStorage(ids, DataStoreFactory.HINT_HOT | DataStoreFactory.HINT_STATIC);
 WritableDoubleDataStore lambda = DataStoreUtil.makeDoubleStorage(ids, DataStoreFactory.HINT_HOT | DataStoreFactory.HINT_STATIC, Double.POSITIVE_INFINITY);
 convertToPointerRepresentation(ids, heap, pi, lambda);
 return new PointerDensityHierarchyRepresentationResult(ids, pi, lambda, coredists);
}
origin: elki-project/elki

/**
 * Run the algorithm
 *
 * @param db Database
 * @param relation Relation
 * @return Clustering hierarchy
 */
public PointerDensityHierarchyRepresentationResult run(Database db, Relation<O> relation) {
 final DistanceQuery<O> distQ = db.getDistanceQuery(relation, getDistanceFunction());
 final KNNQuery<O> knnQ = db.getKNNQuery(distQ, minPts);
 // We need array addressing later.
 final ArrayDBIDs ids = DBIDUtil.ensureArray(relation.getDBIDs());
 // 1. Compute the core distances
 // minPts + 1: ignore query point.
 final WritableDoubleDataStore coredists = computeCoreDists(ids, knnQ, minPts);
 final int numedges = ids.size() - 1;
 DoubleLongHeap heap = new DoubleLongMinHeap(numedges);
 // 2. Build spanning tree.
 FiniteProgress mprog = LOG.isVerbose() ? new FiniteProgress("Computing minimum spanning tree (n-1 edges)", numedges, LOG) : null;
 PrimsMinimumSpanningTree.processDense(ids, //
   new HDBSCANAdapter(ids, coredists, distQ), //
   new HeapMSTCollector(heap, mprog, LOG));
 LOG.ensureCompleted(mprog);
 // Storage for pointer representation:
 WritableDBIDDataStore pi = DataStoreUtil.makeDBIDStorage(ids, DataStoreFactory.HINT_HOT | DataStoreFactory.HINT_STATIC);
 WritableDoubleDataStore lambda = DataStoreUtil.makeDoubleStorage(ids, DataStoreFactory.HINT_HOT | DataStoreFactory.HINT_STATIC, Double.POSITIVE_INFINITY);
 convertToPointerRepresentation(ids, heap, pi, lambda);
 return new PointerDensityHierarchyRepresentationResult(ids, pi, lambda, distQ.getDistanceFunction().isSquared(), coredists);
}
origin: de.lmu.ifi.dbs.elki/elki-clustering

/**
 * Run the algorithm
 *
 * @param db Database
 * @param relation Relation
 * @return Clustering hierarchy
 */
public PointerDensityHierarchyRepresentationResult run(Database db, Relation<O> relation) {
 final DistanceQuery<O> distQ = db.getDistanceQuery(relation, getDistanceFunction());
 final KNNQuery<O> knnQ = db.getKNNQuery(distQ, minPts);
 // We need array addressing later.
 final ArrayDBIDs ids = DBIDUtil.ensureArray(relation.getDBIDs());
 // 1. Compute the core distances
 // minPts + 1: ignore query point.
 final WritableDoubleDataStore coredists = computeCoreDists(ids, knnQ, minPts);
 final int numedges = ids.size() - 1;
 DoubleLongHeap heap = new DoubleLongMinHeap(numedges);
 // 2. Build spanning tree.
 FiniteProgress mprog = LOG.isVerbose() ? new FiniteProgress("Computing minimum spanning tree (n-1 edges)", numedges, LOG) : null;
 PrimsMinimumSpanningTree.processDense(ids, //
   new HDBSCANAdapter(ids, coredists, distQ), //
   new HeapMSTCollector(heap, mprog, LOG));
 LOG.ensureCompleted(mprog);
 // Storage for pointer representation:
 WritableDBIDDataStore pi = DataStoreUtil.makeDBIDStorage(ids, DataStoreFactory.HINT_HOT | DataStoreFactory.HINT_STATIC);
 WritableDoubleDataStore lambda = DataStoreUtil.makeDoubleStorage(ids, DataStoreFactory.HINT_HOT | DataStoreFactory.HINT_STATIC, Double.POSITIVE_INFINITY);
 convertToPointerRepresentation(ids, heap, pi, lambda);
 return new PointerDensityHierarchyRepresentationResult(ids, pi, lambda, distQ.getDistanceFunction().isSquared(), coredists);
}
de.lmu.ifi.dbs.elki.algorithm.clustering.hierarchicalHDBSCANLinearMemorygetDistanceFunction

Popular methods of HDBSCANLinearMemory

  • <init>
    Constructor.
  • computeCoreDists
  • convertToPointerRepresentation

Popular in Java

  • Updating database using SQL prepared statement
  • setScale (BigDecimal)
  • getSupportFragmentManager (FragmentActivity)
    Return the FragmentManager for interacting with fragments associated with this activity.
  • getContentResolver (Context)
  • VirtualMachine (com.sun.tools.attach)
    A Java virtual machine. A VirtualMachine represents a Java virtual machine to which this Java vir
  • BufferedImage (java.awt.image)
    The BufferedImage subclass describes an java.awt.Image with an accessible buffer of image data. All
  • InetAddress (java.net)
    This class represents an Internet Protocol (IP) address. An IP address is either a 32-bit or 128-bit
  • BoxLayout (javax.swing)
  • Location (org.springframework.beans.factory.parsing)
    Class that models an arbitrary location in a Resource.Typically used to track the location of proble
  • Option (scala)
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