predict

Batch of objects, matrix of numerical features, matrix of hashes of categorical features, new object with model predictions

public CatBoostPredictions predict(float[][] numericFeatures,
                                   int[][] catFeatureHashes)
Modifier and type

CatBoostPredictions

Purpose

Apply the model to a batch of objects. Uses a matrix of numerical features and a matrix of hashes of categorical features.

Parameters
Parameter Description
numericFeatures

A matrix of input numerical features.

catFeatureHashes

A matrix of hashes of input categorical features. These hashes must be computed by the hashCategoricalFeature(String) function.

Returns

CatBoostPredictions with predictions for a batch of objects.

Throws

CatBoostError — In case of errors in the native library.

Batch of objects, matrix of numerical features, matrix of hashes of categorical features, specified object with model predictions

public void predict(float[][] numericFeatures,
                    int[][] catFeatureHashes,
                    CatBoostPredictions prediction)
Modifier and type
void
Purpose

Apply the model to a batch of objects. Uses a matrix of numerical features and a matrix of hashes of categorical features.

Parameters
Parameter Description
numericFeatures

A matrix of input numerical features.

catFeatureHashes

A matrix of hashes of input categorical features. These hashes must be computed by the hashCategoricalFeature(String) function.

prediction

The model's predictions.

Returns

CatBoostPredictions with predictions for a batch of objects.

Throws

CatBoostError — In case of errors in the native library.

Batch of objects, matrix of numerical features, matrix of categorical features, new object with model predictions

public CatBoostPredictions predict(float[][] numericFeatures,
                                   String[][] catFeatures)
Modifier and type

CatBoostPredictions

Purpose

Apply the model to a batch of objects. Uses a matrix of numerical features and a matrix of categorical features.

Parameters
Parameter Description
numericFeatures

An array of input numerical features.

catFeatures A matrix of input categorical features.
Returns

CatBoostPredictions with predictions for a batch of objects.

Throws

CatBoostError — In case of errors in the native library.

Batch of objects, matrix of numerical features, matrix of categorical features, specified object with model predictions

public void predict(float[][] numericFeatures,
                    String[][] catFeatures,
                    CatBoostPredictions prediction)
Modifier and type
void
Purpose

Apply the model to a batch of objects. Uses a matrix of numerical features.

Parameters
Parameter Description
numericFeatures

A matrix of input numerical features.

catFeatures A matrix of input categorical features.
prediction

The model's predictions.

Returns

CatBoostPredictions with predictions for a batch of objects.

Throws

CatBoostError — In case of errors in the native library.

Object, array of numerical features, array of hashes of categorical features, new object with model predictions

public CatBoostPredictions predict(float[] numericFeatures,
                                   int[] catFeatureHashes)
Modifier and type

CatBoostPredictions

Purpose

Apply the model to an object defined by features. Uses an array of numerical features and an array of hashes of categorical features.

Parameters
Parameter Description
numericFeatures

An array of input numerical features.

catFeatureHashes

An array of hashes of input categorical features. These hashes must be computed by the hashCategoricalFeature(String) function.

Returns

CatBoostPredictions with the prediction for the specified object.

Throws

CatBoostError — In case of errors in the native library.

Object, array of numerical features, array of hashes of categorical features, specified object with model predictions

public void predict(float[] numericFeatures,
                    int[] catFeatureHashes,
                    CatBoostPredictions prediction)
Modifier and type
void
Purpose

Apply the model to an object defined by features. Uses an array of hashes of categorical features computed by the hashCategoricalFeature(String) function.

Parameters
numericFeatures

An array of input numerical features.

catFeatureHashes

An array of hashes of input categorical features. These hashes must be computed by the hashCategoricalFeature(String) function.

prediction

The model's predictions.

Returns

CatBoostPredictions with the prediction for the specified object.

Throws

CatBoostError — In case of errors in the native library.

Object, array of numerical features, array of categorical features, new object with model predictions

predict(float[] numericFeatures, 
        String[] catFeatures)
Modifier and type

CatBoostPredictions

Purpose

Apply the model to an object defined by features.

Parameters
Parameter Description
numericFeatures

An array of input numerical features.

catFeatures An array of input categorical features.
Returns

CatBoostPredictions with the prediction for the specified object.

Throws

CatBoostError — In case of errors in the native library.

Object, array of numerical features, array of categorical features, specified object with model predictions

predict(float[] numericFeatures, 
        String[] catFeatures, 
        CatBoostPredictions prediction)
Modifier and type
void
Purpose

Apply the model to an object defined by features.

Parameters
Parameter Description
numericFeatures

An array of input numerical features.

catFeatures An array of input categorical features.
prediction

The model's predictions.

Returns

CatBoostPredictions with the prediction for the specified object.

Throws

CatBoostError — In case of errors in the native library.