Predictions Interface

public interface Predictions

An instance of this class provides access to all the operations defined in Predictions.

Method Summary

Modifier and Type Method and Description
PredictionsClassifyImageDefinitionStages.WithProjectId classifyImage()

Classify an image and saves the result.

ImagePrediction classifyImage(UUID projectId, String publishedName, byte[] imageData, ClassifyImageOptionalParameter classifyImageOptionalParameter)

Classify an image and saves the result.

Observable<ImagePrediction> classifyImageAsync(UUID projectId, String publishedName, byte[] imageData, ClassifyImageOptionalParameter classifyImageOptionalParameter)

Classify an image and saves the result.

PredictionsClassifyImageUrlDefinitionStages.WithProjectId classifyImageUrl()

Classify an image url and saves the result.

ImagePrediction classifyImageUrl(UUID projectId, String publishedName, String url, ClassifyImageUrlOptionalParameter classifyImageUrlOptionalParameter)

Classify an image url and saves the result.

Observable<ImagePrediction> classifyImageUrlAsync(UUID projectId, String publishedName, String url, ClassifyImageUrlOptionalParameter classifyImageUrlOptionalParameter)

Classify an image url and saves the result.

PredictionsClassifyImageUrlWithNoStoreDefinitionStages.WithProjectId classifyImageUrlWithNoStore()

Classify an image url without saving the result.

ImagePrediction classifyImageUrlWithNoStore(UUID projectId, String publishedName, String url, ClassifyImageUrlWithNoStoreOptionalParameter classifyImageUrlWithNoStoreOptionalParameter)

Classify an image url without saving the result.

Observable<ImagePrediction> classifyImageUrlWithNoStoreAsync(UUID projectId, String publishedName, String url, ClassifyImageUrlWithNoStoreOptionalParameter classifyImageUrlWithNoStoreOptionalParameter)

Classify an image url without saving the result.

PredictionsClassifyImageWithNoStoreDefinitionStages.WithProjectId classifyImageWithNoStore()

Classify an image without saving the result.

ImagePrediction classifyImageWithNoStore(UUID projectId, String publishedName, byte[] imageData, ClassifyImageWithNoStoreOptionalParameter classifyImageWithNoStoreOptionalParameter)

Classify an image without saving the result.

Observable<ImagePrediction> classifyImageWithNoStoreAsync(UUID projectId, String publishedName, byte[] imageData, ClassifyImageWithNoStoreOptionalParameter classifyImageWithNoStoreOptionalParameter)

Classify an image without saving the result.

PredictionsDetectImageDefinitionStages.WithProjectId detectImage()

Detect objects in an image and saves the result.

ImagePrediction detectImage(UUID projectId, String publishedName, byte[] imageData, DetectImageOptionalParameter detectImageOptionalParameter)

Detect objects in an image and saves the result.

Observable<ImagePrediction> detectImageAsync(UUID projectId, String publishedName, byte[] imageData, DetectImageOptionalParameter detectImageOptionalParameter)

Detect objects in an image and saves the result.

PredictionsDetectImageUrlDefinitionStages.WithProjectId detectImageUrl()

Detect objects in an image url and saves the result.

ImagePrediction detectImageUrl(UUID projectId, String publishedName, String url, DetectImageUrlOptionalParameter detectImageUrlOptionalParameter)

Detect objects in an image url and saves the result.

Observable<ImagePrediction> detectImageUrlAsync(UUID projectId, String publishedName, String url, DetectImageUrlOptionalParameter detectImageUrlOptionalParameter)

Detect objects in an image url and saves the result.

PredictionsDetectImageUrlWithNoStoreDefinitionStages.WithProjectId detectImageUrlWithNoStore()

Detect objects in an image url without saving the result.

ImagePrediction detectImageUrlWithNoStore(UUID projectId, String publishedName, String url, DetectImageUrlWithNoStoreOptionalParameter detectImageUrlWithNoStoreOptionalParameter)

Detect objects in an image url without saving the result.

Observable<ImagePrediction> detectImageUrlWithNoStoreAsync(UUID projectId, String publishedName, String url, DetectImageUrlWithNoStoreOptionalParameter detectImageUrlWithNoStoreOptionalParameter)

Detect objects in an image url without saving the result.

PredictionsDetectImageWithNoStoreDefinitionStages.WithProjectId detectImageWithNoStore()

Detect objects in an image without saving the result.

ImagePrediction detectImageWithNoStore(UUID projectId, String publishedName, byte[] imageData, DetectImageWithNoStoreOptionalParameter detectImageWithNoStoreOptionalParameter)

Detect objects in an image without saving the result.

Observable<ImagePrediction> detectImageWithNoStoreAsync(UUID projectId, String publishedName, byte[] imageData, DetectImageWithNoStoreOptionalParameter detectImageWithNoStoreOptionalParameter)

Detect objects in an image without saving the result.

Method Details

classifyImage

public PredictionsClassifyImageDefinitionStages.WithProjectId classifyImage()

Classify an image and saves the result.

Returns:

the first stage of the classifyImage call

classifyImage

public ImagePrediction classifyImage(UUID projectId, String publishedName, byte[] imageData, ClassifyImageOptionalParameter classifyImageOptionalParameter)

Classify an image and saves the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
imageData - Binary image data. Supported formats are JPEG, GIF, PNG, and BMP. Supports images up to 4MB.
classifyImageOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the ImagePrediction object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
CustomVisionErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

classifyImageAsync

public Observable classifyImageAsync(UUID projectId, String publishedName, byte[] imageData, ClassifyImageOptionalParameter classifyImageOptionalParameter)

Classify an image and saves the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
imageData - Binary image data. Supported formats are JPEG, GIF, PNG, and BMP. Supports images up to 4MB.
classifyImageOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the observable to the ImagePrediction object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

classifyImageUrl

public PredictionsClassifyImageUrlDefinitionStages.WithProjectId classifyImageUrl()

Classify an image url and saves the result.

Returns:

the first stage of the classifyImageUrl call

classifyImageUrl

public ImagePrediction classifyImageUrl(UUID projectId, String publishedName, String url, ClassifyImageUrlOptionalParameter classifyImageUrlOptionalParameter)

Classify an image url and saves the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
url - Url of the image.
classifyImageUrlOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the ImagePrediction object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
CustomVisionErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

classifyImageUrlAsync

public Observable classifyImageUrlAsync(UUID projectId, String publishedName, String url, ClassifyImageUrlOptionalParameter classifyImageUrlOptionalParameter)

Classify an image url and saves the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
url - Url of the image.
classifyImageUrlOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the observable to the ImagePrediction object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

classifyImageUrlWithNoStore

public PredictionsClassifyImageUrlWithNoStoreDefinitionStages.WithProjectId classifyImageUrlWithNoStore()

Classify an image url without saving the result.

Returns:

the first stage of the classifyImageUrlWithNoStore call

classifyImageUrlWithNoStore

public ImagePrediction classifyImageUrlWithNoStore(UUID projectId, String publishedName, String url, ClassifyImageUrlWithNoStoreOptionalParameter classifyImageUrlWithNoStoreOptionalParameter)

Classify an image url without saving the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
url - Url of the image.
classifyImageUrlWithNoStoreOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the ImagePrediction object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
CustomVisionErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

classifyImageUrlWithNoStoreAsync

public Observable classifyImageUrlWithNoStoreAsync(UUID projectId, String publishedName, String url, ClassifyImageUrlWithNoStoreOptionalParameter classifyImageUrlWithNoStoreOptionalParameter)

Classify an image url without saving the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
url - Url of the image.
classifyImageUrlWithNoStoreOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the observable to the ImagePrediction object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

classifyImageWithNoStore

public PredictionsClassifyImageWithNoStoreDefinitionStages.WithProjectId classifyImageWithNoStore()

Classify an image without saving the result.

Returns:

the first stage of the classifyImageWithNoStore call

classifyImageWithNoStore

public ImagePrediction classifyImageWithNoStore(UUID projectId, String publishedName, byte[] imageData, ClassifyImageWithNoStoreOptionalParameter classifyImageWithNoStoreOptionalParameter)

Classify an image without saving the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
imageData - Binary image data. Supported formats are JPEG, GIF, PNG, and BMP. Supports images up to 0MB.
classifyImageWithNoStoreOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the ImagePrediction object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
CustomVisionErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

classifyImageWithNoStoreAsync

public Observable classifyImageWithNoStoreAsync(UUID projectId, String publishedName, byte[] imageData, ClassifyImageWithNoStoreOptionalParameter classifyImageWithNoStoreOptionalParameter)

Classify an image without saving the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
imageData - Binary image data. Supported formats are JPEG, GIF, PNG, and BMP. Supports images up to 0MB.
classifyImageWithNoStoreOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the observable to the ImagePrediction object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

detectImage

public PredictionsDetectImageDefinitionStages.WithProjectId detectImage()

Detect objects in an image and saves the result.

Returns:

the first stage of the detectImage call

detectImage

public ImagePrediction detectImage(UUID projectId, String publishedName, byte[] imageData, DetectImageOptionalParameter detectImageOptionalParameter)

Detect objects in an image and saves the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
imageData - Binary image data. Supported formats are JPEG, GIF, PNG, and BMP. Supports images up to 4MB.
detectImageOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the ImagePrediction object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
CustomVisionErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

detectImageAsync

public Observable detectImageAsync(UUID projectId, String publishedName, byte[] imageData, DetectImageOptionalParameter detectImageOptionalParameter)

Detect objects in an image and saves the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
imageData - Binary image data. Supported formats are JPEG, GIF, PNG, and BMP. Supports images up to 4MB.
detectImageOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the observable to the ImagePrediction object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

detectImageUrl

public PredictionsDetectImageUrlDefinitionStages.WithProjectId detectImageUrl()

Detect objects in an image url and saves the result.

Returns:

the first stage of the detectImageUrl call

detectImageUrl

public ImagePrediction detectImageUrl(UUID projectId, String publishedName, String url, DetectImageUrlOptionalParameter detectImageUrlOptionalParameter)

Detect objects in an image url and saves the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
url - Url of the image.
detectImageUrlOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the ImagePrediction object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
CustomVisionErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

detectImageUrlAsync

public Observable detectImageUrlAsync(UUID projectId, String publishedName, String url, DetectImageUrlOptionalParameter detectImageUrlOptionalParameter)

Detect objects in an image url and saves the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
url - Url of the image.
detectImageUrlOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the observable to the ImagePrediction object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

detectImageUrlWithNoStore

public PredictionsDetectImageUrlWithNoStoreDefinitionStages.WithProjectId detectImageUrlWithNoStore()

Detect objects in an image url without saving the result.

Returns:

the first stage of the detectImageUrlWithNoStore call

detectImageUrlWithNoStore

public ImagePrediction detectImageUrlWithNoStore(UUID projectId, String publishedName, String url, DetectImageUrlWithNoStoreOptionalParameter detectImageUrlWithNoStoreOptionalParameter)

Detect objects in an image url without saving the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
url - Url of the image.
detectImageUrlWithNoStoreOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the ImagePrediction object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
CustomVisionErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

detectImageUrlWithNoStoreAsync

public Observable detectImageUrlWithNoStoreAsync(UUID projectId, String publishedName, String url, DetectImageUrlWithNoStoreOptionalParameter detectImageUrlWithNoStoreOptionalParameter)

Detect objects in an image url without saving the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
url - Url of the image.
detectImageUrlWithNoStoreOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the observable to the ImagePrediction object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

detectImageWithNoStore

public PredictionsDetectImageWithNoStoreDefinitionStages.WithProjectId detectImageWithNoStore()

Detect objects in an image without saving the result.

Returns:

the first stage of the detectImageWithNoStore call

detectImageWithNoStore

public ImagePrediction detectImageWithNoStore(UUID projectId, String publishedName, byte[] imageData, DetectImageWithNoStoreOptionalParameter detectImageWithNoStoreOptionalParameter)

Detect objects in an image without saving the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
imageData - Binary image data. Supported formats are JPEG, GIF, PNG, and BMP. Supports images up to 0MB.
detectImageWithNoStoreOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the ImagePrediction object if successful.

Throws:

IllegalArgumentException - thrown if parameters fail the validation
CustomVisionErrorException - thrown if the request is rejected by server
RuntimeException - all other wrapped checked exceptions if the request fails to be sent

detectImageWithNoStoreAsync

public Observable detectImageWithNoStoreAsync(UUID projectId, String publishedName, byte[] imageData, DetectImageWithNoStoreOptionalParameter detectImageWithNoStoreOptionalParameter)

Detect objects in an image without saving the result.

Parameters:

projectId - The project id.
publishedName - Specifies the name of the model to evaluate against.
imageData - Binary image data. Supported formats are JPEG, GIF, PNG, and BMP. Supports images up to 0MB.
detectImageWithNoStoreOptionalParameter - the object representing the optional parameters to be set before calling this API

Returns:

the observable to the ImagePrediction object

Throws:

IllegalArgumentException - thrown if parameters fail the validation

Applies to