@Deprecated
public class VisualRecognition
extends com.ibm.cloud.sdk.core.service.BaseService
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
DEFAULT_SERVICE_NAME
Deprecated.
|
static java.lang.String |
DEFAULT_SERVICE_URL
Deprecated.
|
| Constructor and Description |
|---|
VisualRecognition(java.lang.String version)
Deprecated.
Constructs an instance of the `VisualRecognition` client.
|
VisualRecognition(java.lang.String version,
com.ibm.cloud.sdk.core.security.Authenticator authenticator)
Deprecated.
Constructs an instance of the `VisualRecognition` client.
|
VisualRecognition(java.lang.String version,
java.lang.String serviceName)
Deprecated.
Constructs an instance of the `VisualRecognition` client.
|
VisualRecognition(java.lang.String version,
java.lang.String serviceName,
com.ibm.cloud.sdk.core.security.Authenticator authenticator)
Deprecated.
Constructs an instance of the `VisualRecognition` client.
|
| Modifier and Type | Method and Description |
|---|---|
com.ibm.cloud.sdk.core.http.ServiceCall<ImageDetailsList> |
addImages(AddImagesOptions addImagesOptions)
Deprecated.
Add images.
|
com.ibm.cloud.sdk.core.http.ServiceCall<TrainingDataObjects> |
addImageTrainingData(AddImageTrainingDataOptions addImageTrainingDataOptions)
Deprecated.
Add training data to an image.
|
com.ibm.cloud.sdk.core.http.ServiceCall<AnalyzeResponse> |
analyze(AnalyzeOptions analyzeOptions)
Deprecated.
Analyze images.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Collection> |
createCollection()
Deprecated.
Create a collection.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Collection> |
createCollection(CreateCollectionOptions createCollectionOptions)
Deprecated.
Create a collection.
|
com.ibm.cloud.sdk.core.http.ServiceCall<java.lang.Void> |
deleteCollection(DeleteCollectionOptions deleteCollectionOptions)
Deprecated.
Delete a collection.
|
com.ibm.cloud.sdk.core.http.ServiceCall<java.lang.Void> |
deleteImage(DeleteImageOptions deleteImageOptions)
Deprecated.
Delete an image.
|
com.ibm.cloud.sdk.core.http.ServiceCall<java.lang.Void> |
deleteObject(DeleteObjectOptions deleteObjectOptions)
Deprecated.
Delete an object.
|
com.ibm.cloud.sdk.core.http.ServiceCall<java.lang.Void> |
deleteUserData(DeleteUserDataOptions deleteUserDataOptions)
Deprecated.
Delete labeled data.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Collection> |
getCollection(GetCollectionOptions getCollectionOptions)
Deprecated.
Get collection details.
|
com.ibm.cloud.sdk.core.http.ServiceCall<ImageDetails> |
getImageDetails(GetImageDetailsOptions getImageDetailsOptions)
Deprecated.
Get image details.
|
com.ibm.cloud.sdk.core.http.ServiceCall<java.io.InputStream> |
getJpegImage(GetJpegImageOptions getJpegImageOptions)
Deprecated.
Get a JPEG file of an image.
|
com.ibm.cloud.sdk.core.http.ServiceCall<java.io.InputStream> |
getModelFile(GetModelFileOptions getModelFileOptions)
Deprecated.
Get a model.
|
com.ibm.cloud.sdk.core.http.ServiceCall<ObjectMetadata> |
getObjectMetadata(GetObjectMetadataOptions getObjectMetadataOptions)
Deprecated.
Get object metadata.
|
com.ibm.cloud.sdk.core.http.ServiceCall<TrainingEvents> |
getTrainingUsage()
Deprecated.
Get training usage.
|
com.ibm.cloud.sdk.core.http.ServiceCall<TrainingEvents> |
getTrainingUsage(GetTrainingUsageOptions getTrainingUsageOptions)
Deprecated.
Get training usage.
|
java.lang.String |
getVersion()
Deprecated.
Gets the version.
|
com.ibm.cloud.sdk.core.http.ServiceCall<CollectionsList> |
listCollections()
Deprecated.
List collections.
|
com.ibm.cloud.sdk.core.http.ServiceCall<CollectionsList> |
listCollections(ListCollectionsOptions listCollectionsOptions)
Deprecated.
List collections.
|
com.ibm.cloud.sdk.core.http.ServiceCall<ImageSummaryList> |
listImages(ListImagesOptions listImagesOptions)
Deprecated.
List images.
|
com.ibm.cloud.sdk.core.http.ServiceCall<ObjectMetadataList> |
listObjectMetadata(ListObjectMetadataOptions listObjectMetadataOptions)
Deprecated.
List object metadata.
|
void |
setVersion(java.lang.String version)
Deprecated.
Sets the version.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Collection> |
train(TrainOptions trainOptions)
Deprecated.
Train a collection.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Collection> |
updateCollection(UpdateCollectionOptions updateCollectionOptions)
Deprecated.
Update a collection.
|
com.ibm.cloud.sdk.core.http.ServiceCall<UpdateObjectMetadata> |
updateObjectMetadata(UpdateObjectMetadataOptions updateObjectMetadataOptions)
Deprecated.
Update an object name.
|
configureClient, configureHttpClient, configureService, createServiceCall, enableGzipCompression, getAuthenticator, getClient, getEndPoint, getName, getServiceUrl, isJsonMimeType, isJsonPatchMimeType, processServiceCall, setAuthentication, setClient, setDefaultHeaders, setDefaultHeaders, setEndPoint, setServiceUrl, toStringpublic static final java.lang.String DEFAULT_SERVICE_NAME
public static final java.lang.String DEFAULT_SERVICE_URL
public VisualRecognition(java.lang.String version)
version - Release date of the API version you want to use. Specify dates in YYYY-MM-DD
format. The current version is `2019-02-11`.public VisualRecognition(java.lang.String version,
com.ibm.cloud.sdk.core.security.Authenticator authenticator)
version - Release date of the API version you want to use. Specify dates in YYYY-MM-DD
format. The current version is `2019-02-11`.authenticator - the Authenticator instance to be configured for this clientpublic VisualRecognition(java.lang.String version,
java.lang.String serviceName)
version - Release date of the API version you want to use. Specify dates in YYYY-MM-DD
format. The current version is `2019-02-11`.serviceName - the service name to be used when configuring the client instancepublic VisualRecognition(java.lang.String version,
java.lang.String serviceName,
com.ibm.cloud.sdk.core.security.Authenticator authenticator)
version - Release date of the API version you want to use. Specify dates in YYYY-MM-DD
format. The current version is `2019-02-11`.serviceName - the service name to be used when configuring the client instanceauthenticator - the Authenticator instance to be configured for this clientpublic java.lang.String getVersion()
Release date of the API version you want to use. Specify dates in YYYY-MM-DD format. The current version is `2019-02-11`.
public void setVersion(java.lang.String version)
version - the new versionpublic com.ibm.cloud.sdk.core.http.ServiceCall<AnalyzeResponse> analyze(AnalyzeOptions analyzeOptions)
Analyze images by URL, by file, or both against your own collection. Make sure that **training_status.objects.ready** is `true` for the feature before you use a collection to analyze images.
Encode the image and .zip file names in UTF-8 if they contain non-ASCII characters. The service assumes UTF-8 encoding if it encounters non-ASCII characters.
analyzeOptions - the AnalyzeOptions containing the options for the callServiceCall with a result of type AnalyzeResponsepublic com.ibm.cloud.sdk.core.http.ServiceCall<Collection> createCollection(CreateCollectionOptions createCollectionOptions)
Create a collection that can be used to store images.
To create a collection without specifying a name and description, include an empty JSON object in the request body.
Encode the name and description in UTF-8 if they contain non-ASCII characters. The service assumes UTF-8 encoding if it encounters non-ASCII characters.
createCollectionOptions - the CreateCollectionOptions containing the options for
the callServiceCall with a result of type Collectionpublic com.ibm.cloud.sdk.core.http.ServiceCall<Collection> createCollection()
Create a collection that can be used to store images.
To create a collection without specifying a name and description, include an empty JSON object in the request body.
Encode the name and description in UTF-8 if they contain non-ASCII characters. The service assumes UTF-8 encoding if it encounters non-ASCII characters.
ServiceCall with a result of type Collectionpublic com.ibm.cloud.sdk.core.http.ServiceCall<CollectionsList> listCollections(ListCollectionsOptions listCollectionsOptions)
Retrieves a list of collections for the service instance.
listCollectionsOptions - the ListCollectionsOptions containing the options for the
callServiceCall with a result of type CollectionsListpublic com.ibm.cloud.sdk.core.http.ServiceCall<CollectionsList> listCollections()
Retrieves a list of collections for the service instance.
ServiceCall with a result of type CollectionsListpublic com.ibm.cloud.sdk.core.http.ServiceCall<Collection> getCollection(GetCollectionOptions getCollectionOptions)
Get details of one collection.
getCollectionOptions - the GetCollectionOptions containing the options for the
callServiceCall with a result of type Collectionpublic com.ibm.cloud.sdk.core.http.ServiceCall<Collection> updateCollection(UpdateCollectionOptions updateCollectionOptions)
Update the name or description of a collection.
Encode the name and description in UTF-8 if they contain non-ASCII characters. The service assumes UTF-8 encoding if it encounters non-ASCII characters.
updateCollectionOptions - the UpdateCollectionOptions containing the options for
the callServiceCall with a result of type Collectionpublic com.ibm.cloud.sdk.core.http.ServiceCall<java.lang.Void> deleteCollection(DeleteCollectionOptions deleteCollectionOptions)
Delete a collection from the service instance.
deleteCollectionOptions - the DeleteCollectionOptions containing the options for
the callServiceCall with a void resultpublic com.ibm.cloud.sdk.core.http.ServiceCall<java.io.InputStream> getModelFile(GetModelFileOptions getModelFileOptions)
Download a model that you can deploy to detect objects in images. The collection must include a generated model, which is indicated in the response for the collection details as `"rscnn_ready": true`. If the value is `false`, train or retrain the collection to generate the model.
Currently, the model format is specific to Android apps. For more information about how to deploy the model to your app, see the [Watson Visual Recognition on Android](https://github.com/matt-ny/rscnn) project in GitHub.
getModelFileOptions - the GetModelFileOptions containing the options for the callServiceCall with a result of type InputStreampublic com.ibm.cloud.sdk.core.http.ServiceCall<ImageDetailsList> addImages(AddImagesOptions addImagesOptions)
Add images to a collection by URL, by file, or both.
Encode the image and .zip file names in UTF-8 if they contain non-ASCII characters. The service assumes UTF-8 encoding if it encounters non-ASCII characters.
addImagesOptions - the AddImagesOptions containing the options for the callServiceCall with a result of type ImageDetailsListpublic com.ibm.cloud.sdk.core.http.ServiceCall<ImageSummaryList> listImages(ListImagesOptions listImagesOptions)
Retrieves a list of images in a collection.
listImagesOptions - the ListImagesOptions containing the options for the callServiceCall with a result of type ImageSummaryListpublic com.ibm.cloud.sdk.core.http.ServiceCall<ImageDetails> getImageDetails(GetImageDetailsOptions getImageDetailsOptions)
Get the details of an image in a collection.
getImageDetailsOptions - the GetImageDetailsOptions containing the options for the
callServiceCall with a result of type ImageDetailspublic com.ibm.cloud.sdk.core.http.ServiceCall<java.lang.Void> deleteImage(DeleteImageOptions deleteImageOptions)
Delete one image from a collection.
deleteImageOptions - the DeleteImageOptions containing the options for the callServiceCall with a void resultpublic com.ibm.cloud.sdk.core.http.ServiceCall<java.io.InputStream> getJpegImage(GetJpegImageOptions getJpegImageOptions)
Download a JPEG representation of an image.
getJpegImageOptions - the GetJpegImageOptions containing the options for the callServiceCall with a result of type InputStreampublic com.ibm.cloud.sdk.core.http.ServiceCall<ObjectMetadataList> listObjectMetadata(ListObjectMetadataOptions listObjectMetadataOptions)
Retrieves a list of object names in a collection.
listObjectMetadataOptions - the ListObjectMetadataOptions containing the options
for the callServiceCall with a result of type ObjectMetadataListpublic com.ibm.cloud.sdk.core.http.ServiceCall<UpdateObjectMetadata> updateObjectMetadata(UpdateObjectMetadataOptions updateObjectMetadataOptions)
Update the name of an object. A successful request updates the training data for all images that use the object.
updateObjectMetadataOptions - the UpdateObjectMetadataOptions containing the
options for the callServiceCall with a result of type UpdateObjectMetadatapublic com.ibm.cloud.sdk.core.http.ServiceCall<ObjectMetadata> getObjectMetadata(GetObjectMetadataOptions getObjectMetadataOptions)
Get the number of bounding boxes for a single object in a collection.
getObjectMetadataOptions - the GetObjectMetadataOptions containing the options for
the callServiceCall with a result of type ObjectMetadatapublic com.ibm.cloud.sdk.core.http.ServiceCall<java.lang.Void> deleteObject(DeleteObjectOptions deleteObjectOptions)
Delete one object from a collection. A successful request deletes the training data from all images that use the object.
deleteObjectOptions - the DeleteObjectOptions containing the options for the callServiceCall with a void resultpublic com.ibm.cloud.sdk.core.http.ServiceCall<Collection> train(TrainOptions trainOptions)
Start training on images in a collection. The collection must have enough training data and untrained data (the **training_status.objects.data_changed** is `true`). If training is in progress, the request queues the next training job.
trainOptions - the TrainOptions containing the options for the callServiceCall with a result of type Collectionpublic com.ibm.cloud.sdk.core.http.ServiceCall<TrainingDataObjects> addImageTrainingData(AddImageTrainingDataOptions addImageTrainingDataOptions)
Add, update, or delete training data for an image. Encode the object name in UTF-8 if it contains non-ASCII characters. The service assumes UTF-8 encoding if it encounters non-ASCII characters.
Elements in the request replace the existing elements.
- To update the training data, provide both the unchanged and the new or changed values.
- To delete the training data, provide an empty value for the training data.
addImageTrainingDataOptions - the AddImageTrainingDataOptions containing the
options for the callServiceCall with a result of type TrainingDataObjectspublic com.ibm.cloud.sdk.core.http.ServiceCall<TrainingEvents> getTrainingUsage(GetTrainingUsageOptions getTrainingUsageOptions)
Information about the completed training events. You can use this information to determine how close you are to the training limits for the month.
getTrainingUsageOptions - the GetTrainingUsageOptions containing the options for
the callServiceCall with a result of type TrainingEventspublic com.ibm.cloud.sdk.core.http.ServiceCall<TrainingEvents> getTrainingUsage()
Information about the completed training events. You can use this information to determine how close you are to the training limits for the month.
ServiceCall with a result of type TrainingEventspublic com.ibm.cloud.sdk.core.http.ServiceCall<java.lang.Void> deleteUserData(DeleteUserDataOptions deleteUserDataOptions)
Deletes all data associated with a specified customer ID. The method has no effect if no data is associated with the customer ID.
You associate a customer ID with data by passing the `X-Watson-Metadata` header with a request that passes data. For more information about personal data and customer IDs, see [Information security](https://cloud.ibm.com/docs/visual-recognition?topic=visual-recognition-information-security).
deleteUserDataOptions - the DeleteUserDataOptions containing the options for the
callServiceCall with a void result