Package oracle.pgx.api
Class MatrixFactorizationModel<ID>
- java.lang.Object
-
- oracle.pgx.api.internal.ApiObject
-
- oracle.pgx.api.MatrixFactorizationModel<ID>
-
- Type Parameters:
ID
- The vertex ID type
public class MatrixFactorizationModel<ID> extends oracle.pgx.api.internal.ApiObject
Object that holds the state for repeatedly returning estimated ratings.- Author:
- Tim Boudreau
-
-
Method Summary
All Methods Instance Methods Concrete Methods Modifier and Type Method Description VertexProperty<ID,java.lang.Double>
getEstimatedRatings(PgxVertex<ID> estimateRatingsFor)
Blocking version ofgetEstimatedRatingsAsync(PgxVertex)
PgxFuture<VertexProperty<ID,java.lang.Double>>
getEstimatedRatingsAsync(PgxVertex<ID> estimateRatingsFor)
Computes estimated ratings for a specific vertex.VertexProperty<ID,PgxVect<java.lang.Double>>
getFeatures()
Gets the features of this model.double
getRootMeanSquareError()
Gets the computed root mean square error value.java.lang.String
toString()
-
-
-
Method Detail
-
getFeatures
public VertexProperty<ID,PgxVect<java.lang.Double>> getFeatures()
Gets the features of this model.- Returns:
- the feature vertex property
-
getRootMeanSquareError
public double getRootMeanSquareError()
Gets the computed root mean square error value.- Returns:
- the computed root mean square error value
-
getEstimatedRatingsAsync
public PgxFuture<VertexProperty<ID,java.lang.Double>> getEstimatedRatingsAsync(PgxVertex<ID> estimateRatingsFor)
Computes estimated ratings for a specific vertex.- Parameters:
estimateRatingsFor
- The vertex to get estimated ratings for- Returns:
- A future
-
getEstimatedRatings
public VertexProperty<ID,java.lang.Double> getEstimatedRatings(PgxVertex<ID> estimateRatingsFor) throws java.lang.InterruptedException, java.util.concurrent.ExecutionException
Blocking version ofgetEstimatedRatingsAsync(PgxVertex)
- Parameters:
estimateRatingsFor
- The vertex to get estimated ratings for- Returns:
- the VertexProperty containing the estimated ratings
- Throws:
java.lang.InterruptedException
java.util.concurrent.ExecutionException
-
toString
public java.lang.String toString()
- Overrides:
toString
in classjava.lang.Object
-
-