Documentation of 'jsat.linear.vectorcollection.VectorCollectionUtils' Java class
VectorCollectionUtils
jsat.linear.vectorcollection

Class VectorCollectionUtils



  • public class VectorCollectionUtils
    extends java.lang.Object
    A collection of common utility methods to perform on a VectorCollection
    • Method Summary

      All Methods Static Methods Concrete Methods Deprecated Methods 
      Modifier and Type Method and Description
      static <V0 extends Vec,V1 extends Vec>
      java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>>
      allEpsNeighbors(VectorCollection<V0> collection, java.util.List<V1> search, double radius, boolean parallel)
      Searches the given collection for all the neighbors within a distance of radius for every data point in the given search list.
      static <V0 extends Vec,V1 extends Vec>
      java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>>
      allEpsNeighbors(VectorCollection<V0> collection, java.util.List<V1> search, double radius, java.util.concurrent.ExecutorService threadpool)
      Searches the given collection for all the neighbors within a distance of radius for every data point in the given search list.
      static <V0 extends Vec,V1 extends Vec>
      java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>>
      allNearestNeighbors(VectorCollection<V0> collection, java.util.List<V1> search, int k)
      Searches the given collection for the k nearest neighbors for every data point in the given search list.
      static <V0 extends Vec,V1 extends Vec>
      java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>>
      allNearestNeighbors(VectorCollection<V0> collection, java.util.List<V1> search, int k, boolean parallel)
      Searches the given collection for the k nearest neighbors for every data point in the given search list.
      static <V0 extends Vec,V1 extends Vec>
      java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>>
      allNearestNeighbors(VectorCollection<V0> collection, java.util.List<V1> search, int k, java.util.concurrent.ExecutorService threadpool)
      Deprecated. 
      This will be deleted soon
      static <V0 extends Vec,V1 extends Vec>
      java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>>
      allNearestNeighbors(VectorCollection<V0> collection, V1[] search, int k)
      Searches the given collection for the k nearest neighbors for every data point in the given search list.
      static <V0 extends Vec,V1 extends Vec>
      java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>>
      allNearestNeighbors(VectorCollection<V0> collection, V1[] search, int k, java.util.concurrent.ExecutorService threadpool)
      Searches the given collection for the k nearest neighbors for every data point in the given search list.
      static <V0 extends Vec,V1 extends Vec>
      OnLineStatistics
      getKthNeighborStats(VectorCollection<V0> collection, java.util.List<V1> search, int k)
      Computes statistics about the distance of the k'th nearest neighbor for each data point in the search list.
      static <V0 extends Vec,V1 extends Vec>
      OnLineStatistics
      getKthNeighborStats(VectorCollection<V0> collection, java.util.List<V1> search, int k, java.util.concurrent.ExecutorService threadpool)
      Computes statistics about the distance of the k'th nearest neighbor for each data point in the search list.
      static <V0 extends Vec,V1 extends Vec>
      OnLineStatistics
      getKthNeighborStats(VectorCollection<V0> collection, V1[] search, int k)
      Computes statistics about the distance of the k'th nearest neighbor for each data point in the search list.
      static <V0 extends Vec,V1 extends Vec>
      OnLineStatistics
      getKthNeighborStats(VectorCollection<V0> collection, V1[] search, int k, java.util.concurrent.ExecutorService threadpool)
      Computes statistics about the distance of the k'th nearest neighbor for each data point in the search list.
      • Methods inherited from class java.lang.Object

        equals, getClass, hashCode, notify, notifyAll, toString, wait, wait, wait
    • Constructor Detail

      • VectorCollectionUtils

        public VectorCollectionUtils()
    • Method Detail

      • allNearestNeighbors

        public static <V0 extends Vec,V1 extends Vec> java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>> allNearestNeighbors(VectorCollection<V0> collection,
                                                                                                                                                   java.util.List<V1> search,
                                                                                                                                                   int k)
        Searches the given collection for the k nearest neighbors for every data point in the given search list.
        Type Parameters:
        V0 - the vector type in the collection
        V1 - the type of vector in the search collection
        Parameters:
        collection - the collection to search from
        search - the vectors to search for
        k - the number of nearest neighbors
        Returns:
        The list of lists for all nearest neighbors
      • allNearestNeighbors

        public static <V0 extends Vec,V1 extends Vec> java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>> allNearestNeighbors(VectorCollection<V0> collection,
                                                                                                                                                   V1[] search,
                                                                                                                                                   int k)
        Searches the given collection for the k nearest neighbors for every data point in the given search list.
        Type Parameters:
        V0 - the vector type in the collection
        V1 - the type of vector in the search array
        Parameters:
        collection - the collection to search from
        search - the vectors to search for
        k - the number of nearest neighbors
        Returns:
        The list of lists for all nearest neighbors
      • allNearestNeighbors

        public static <V0 extends Vec,V1 extends Vec> java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>> allNearestNeighbors(VectorCollection<V0> collection,
                                                                                                                                                   java.util.List<V1> search,
                                                                                                                                                   int k,
                                                                                                                                                   java.util.concurrent.ExecutorService threadpool)
        Deprecated. This will be deleted soon
        Searches the given collection for the k nearest neighbors for every data point in the given search list.
        Type Parameters:
        V0 - the vector type in the collection
        V1 - the type of vector in the search collection
        Parameters:
        collection - the collection to search from
        search - the vectors to search for
        k - the number of nearest neighbors
        threadpool - the source of threads to perform the computation in parallel
        Returns:
        The list of lists for all nearest neighbors
      • allNearestNeighbors

        public static <V0 extends Vec,V1 extends Vec> java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>> allNearestNeighbors(VectorCollection<V0> collection,
                                                                                                                                                   java.util.List<V1> search,
                                                                                                                                                   int k,
                                                                                                                                                   boolean parallel)
        Searches the given collection for the k nearest neighbors for every data point in the given search list.
        Type Parameters:
        V0 - the vector type in the collection
        V1 - the type of vector in the search collection
        Parameters:
        collection - the collection to search from
        search - the vectors to search for
        k - the number of nearest neighbors
        parallel - true if multiple threads should be used to perform clustering. false if it should be done in a single threaded manner.
        Returns:
        The list of lists for all nearest neighbors
      • allEpsNeighbors

        public static <V0 extends Vec,V1 extends Vec> java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>> allEpsNeighbors(VectorCollection<V0> collection,
                                                                                                                                               java.util.List<V1> search,
                                                                                                                                               double radius,
                                                                                                                                               java.util.concurrent.ExecutorService threadpool)
        Searches the given collection for all the neighbors within a distance of radius for every data point in the given search list.
        Type Parameters:
        V0 - the vector type in the collection
        V1 - the type of vector in the search collection
        Parameters:
        collection - the collection to search from
        search - the vectors to search for
        radius - the distance to search for neighbors
        threadpool - the source of threads to perform the computation in parallel
        Returns:
        The list of lists for all nearest neighbors
      • allEpsNeighbors

        public static <V0 extends Vec,V1 extends Vec> java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>> allEpsNeighbors(VectorCollection<V0> collection,
                                                                                                                                               java.util.List<V1> search,
                                                                                                                                               double radius,
                                                                                                                                               boolean parallel)
        Searches the given collection for all the neighbors within a distance of radius for every data point in the given search list.
        Type Parameters:
        V0 - the vector type in the collection
        V1 - the type of vector in the search collection
        Parameters:
        collection - the collection to search from
        search - the vectors to search for
        radius - the distance to search for neighbors
        parallel - true if multiple threads should be used to perform clustering. false if it should be done in a single threaded manner.
        Returns:
        The list of lists for all nearest neighbors
      • allNearestNeighbors

        public static <V0 extends Vec,V1 extends Vec> java.util.List<java.util.List<? extends VecPaired<V0,java.lang.Double>>> allNearestNeighbors(VectorCollection<V0> collection,
                                                                                                                                                   V1[] search,
                                                                                                                                                   int k,
                                                                                                                                                   java.util.concurrent.ExecutorService threadpool)
        Searches the given collection for the k nearest neighbors for every data point in the given search list.
        Type Parameters:
        V0 - the vector type in the collection
        V1 - the type of vector in the search collection
        Parameters:
        collection - the collection to search from
        search - the vectors to search for
        k - the number of nearest neighbors
        threadpool - the source of threads to perform the computation in parallel
        Returns:
        The list of lists for all nearest neighbors
      • getKthNeighborStats

        public static <V0 extends Vec,V1 extends VecOnLineStatistics getKthNeighborStats(VectorCollection<V0> collection,
                                                                                           java.util.List<V1> search,
                                                                                           int k)
        Computes statistics about the distance of the k'th nearest neighbor for each data point in the search list.
        Type Parameters:
        V0 - the type of vector in the collection
        V1 - the type of vector in the search collection
        Parameters:
        collection - the collection of vectors to query from
        search - the list of vectors to search for
        k - the nearest neighbor to use
        Returns:
        the statistics for the distance of the k'th nearest neighbor from the query point
      • getKthNeighborStats

        public static <V0 extends Vec,V1 extends VecOnLineStatistics getKthNeighborStats(VectorCollection<V0> collection,
                                                                                           V1[] search,
                                                                                           int k)
        Computes statistics about the distance of the k'th nearest neighbor for each data point in the search list.
        Type Parameters:
        V0 - the type of vector in the collection
        V1 - the type of vector in the search array
        Parameters:
        collection - the collection of vectors to query from
        search - the array of vectors to search for
        k - the nearest neighbor to use
        Returns:
        the statistics for the distance of the k'th nearest neighbor from the query point
      • getKthNeighborStats

        public static <V0 extends Vec,V1 extends VecOnLineStatistics getKthNeighborStats(VectorCollection<V0> collection,
                                                                                           java.util.List<V1> search,
                                                                                           int k,
                                                                                           java.util.concurrent.ExecutorService threadpool)
        Computes statistics about the distance of the k'th nearest neighbor for each data point in the search list.
        Type Parameters:
        V0 - the type of vector in the collection
        V1 - the type of vector in the search collection
        Parameters:
        collection - the collection of vectors to query from
        search - the list of vectors to search for
        k - the nearest neighbor to use
        threadpool - the source of threads to perform the computation in parallel
        Returns:
        the statistics for the distance of the k'th nearest neighbor from the query point
      • getKthNeighborStats

        public static <V0 extends Vec,V1 extends VecOnLineStatistics getKthNeighborStats(VectorCollection<V0> collection,
                                                                                           V1[] search,
                                                                                           int k,
                                                                                           java.util.concurrent.ExecutorService threadpool)
        Computes statistics about the distance of the k'th nearest neighbor for each data point in the search list.
        Type Parameters:
        V0 - the type of vector in the collection
        V1 - the type of vector in the search array
        Parameters:
        collection - the collection of vectors to query from
        search - the array of vectors to search for
        k - the nearest neighbor to use
        threadpool - the source of threads to perform the computation in parallel
        Returns:
        the statistics for the distance of the k'th nearest neighbor from the query point

DataMelt 3.0 © DataMelt by jWork.ORG

You see the box below because you did not login.