All Downloads are FREE. Search and download functionalities are using the official Maven repository.

org.deeplearning4j.graph.models.GraphVectors Maven / Gradle / Ivy

There is a newer version: 1.0.0-M2.1
Show newest version
package org.deeplearning4j.graph.models;

import org.deeplearning4j.graph.api.IGraph;
import org.deeplearning4j.graph.api.Vertex;
import org.nd4j.linalg.api.ndarray.INDArray;

import java.io.Serializable;
import java.util.Collection;

/**Vectors for nodes in a graph.
 * Provides lookup table and convenience methods for graph vectors
 */
public interface GraphVectors extends Serializable {

    public IGraph getGraph();

    public int numVertices();

    public int getVectorSize();

    public INDArray getVertexVector(Vertex vertex);

    public INDArray getVertexVector(int vertexIdx);

    public int[] verticesNearest(int vertexIdx, int top);

    double similarity(Vertex vertex1, Vertex vertex2);

    double similarity(int vertexIdx1, int vertexIdx2);

}




© 2015 - 2025 Weber Informatics LLC | Privacy Policy