@Deprecated public class VisualRecognition extends com.ibm.cloud.sdk.core.service.BaseService
Modifier and Type | Field and Description |
---|---|
static String |
DEFAULT_SERVICE_NAME
Deprecated.
|
static String |
DEFAULT_SERVICE_URL
Deprecated.
|
Constructor and Description |
---|
VisualRecognition(String version)
Deprecated.
Constructs an instance of the `VisualRecognition` client.
|
VisualRecognition(String version,
com.ibm.cloud.sdk.core.security.Authenticator authenticator)
Deprecated.
Constructs an instance of the `VisualRecognition` client.
|
VisualRecognition(String version,
String serviceName)
Deprecated.
Constructs an instance of the `VisualRecognition` client.
|
VisualRecognition(String version,
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<ClassifiedImages> |
classify()
Deprecated.
Classify images.
|
com.ibm.cloud.sdk.core.http.ServiceCall<ClassifiedImages> |
classify(ClassifyOptions classifyOptions)
Deprecated.
Classify images.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Classifier> |
createClassifier(CreateClassifierOptions createClassifierOptions)
Deprecated.
Create a classifier.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Void> |
deleteClassifier(DeleteClassifierOptions deleteClassifierOptions)
Deprecated.
Delete a classifier.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Void> |
deleteUserData(DeleteUserDataOptions deleteUserDataOptions)
Deprecated.
Delete labeled data.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Classifier> |
getClassifier(GetClassifierOptions getClassifierOptions)
Deprecated.
Retrieve classifier details.
|
com.ibm.cloud.sdk.core.http.ServiceCall<InputStream> |
getCoreMlModel(GetCoreMlModelOptions getCoreMlModelOptions)
Deprecated.
Retrieve a Core ML model of a classifier.
|
String |
getVersion()
Deprecated.
Gets the version.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Classifiers> |
listClassifiers()
Deprecated.
Retrieve a list of classifiers.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Classifiers> |
listClassifiers(ListClassifiersOptions listClassifiersOptions)
Deprecated.
Retrieve a list of classifiers.
|
void |
setVersion(String version)
Deprecated.
Sets the version.
|
com.ibm.cloud.sdk.core.http.ServiceCall<Classifier> |
updateClassifier(UpdateClassifierOptions updateClassifierOptions)
Deprecated.
Update a classifier.
|
public static final String DEFAULT_SERVICE_NAME
public static final String DEFAULT_SERVICE_URL
public VisualRecognition(String version)
version
- Release date of the API version you want to use. Specify dates in YYYY-MM-DD
format. The current version is `2018-03-19`.public VisualRecognition(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 `2018-03-19`.authenticator
- the Authenticator
instance to be configured for this clientpublic VisualRecognition(String version, String serviceName)
version
- Release date of the API version you want to use. Specify dates in YYYY-MM-DD
format. The current version is `2018-03-19`.serviceName
- the service name to be used when configuring the client instancepublic VisualRecognition(String version, 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 `2018-03-19`.serviceName
- the service name to be used when configuring the client instanceauthenticator
- the Authenticator
instance to be configured for this clientpublic String getVersion()
Release date of the API version you want to use. Specify dates in YYYY-MM-DD format. The current version is `2018-03-19`.
public void setVersion(String version)
version
- the new versionpublic com.ibm.cloud.sdk.core.http.ServiceCall<ClassifiedImages> classify(ClassifyOptions classifyOptions)
Classify images with built-in or custom classifiers.
classifyOptions
- the ClassifyOptions
containing the options for the callServiceCall
with a result of type ClassifiedImages
public com.ibm.cloud.sdk.core.http.ServiceCall<ClassifiedImages> classify()
Classify images with built-in or custom classifiers.
ServiceCall
with a result of type ClassifiedImages
public com.ibm.cloud.sdk.core.http.ServiceCall<Classifier> createClassifier(CreateClassifierOptions createClassifierOptions)
Train a new multi-faceted classifier on the uploaded image data. Create your custom classifier with positive or negative example training images. Include at least two sets of examples, either two positive example files or one positive and one negative file. You can upload a maximum of 256 MB per call.
**Tips when creating:**
- If you set the **X-Watson-Learning-Opt-Out** header parameter to `true` when you create a classifier, the example training images are not stored. Save your training images locally. For more information, see [Data collection](#data-collection).
- Encode all names in UTF-8 if they contain non-ASCII characters (.zip and image file names, and classifier and class names). The service assumes UTF-8 encoding if it encounters non-ASCII characters.
createClassifierOptions
- the CreateClassifierOptions
containing the options for
the callServiceCall
with a result of type Classifier
public com.ibm.cloud.sdk.core.http.ServiceCall<Classifiers> listClassifiers(ListClassifiersOptions listClassifiersOptions)
listClassifiersOptions
- the ListClassifiersOptions
containing the options for the
callServiceCall
with a result of type Classifiers
public com.ibm.cloud.sdk.core.http.ServiceCall<Classifiers> listClassifiers()
ServiceCall
with a result of type Classifiers
public com.ibm.cloud.sdk.core.http.ServiceCall<Classifier> getClassifier(GetClassifierOptions getClassifierOptions)
Retrieve information about a custom classifier.
getClassifierOptions
- the GetClassifierOptions
containing the options for the
callServiceCall
with a result of type Classifier
public com.ibm.cloud.sdk.core.http.ServiceCall<Classifier> updateClassifier(UpdateClassifierOptions updateClassifierOptions)
Update a custom classifier by adding new positive or negative classes or by adding new images to existing classes. You must supply at least one set of positive or negative examples. For details, see [Updating custom classifiers](https://cloud.ibm.com/docs/visual-recognition?topic=visual-recognition-customizing#updating-custom-classifiers).
Encode all names in UTF-8 if they contain non-ASCII characters (.zip and image file names, and classifier and class names). The service assumes UTF-8 encoding if it encounters non-ASCII characters.
**Tips about retraining:**
- You can't update the classifier if the **X-Watson-Learning-Opt-Out** header parameter was set to `true` when the classifier was created. Training images are not stored in that case. Instead, create another classifier. For more information, see [Data collection](#data-collection).
- Don't make retraining calls on a classifier until the status is ready. When you submit retraining requests in parallel, the last request overwrites the previous requests. The `retrained` property shows the last time the classifier retraining finished.
updateClassifierOptions
- the UpdateClassifierOptions
containing the options for
the callServiceCall
with a result of type Classifier
public com.ibm.cloud.sdk.core.http.ServiceCall<Void> deleteClassifier(DeleteClassifierOptions deleteClassifierOptions)
deleteClassifierOptions
- the DeleteClassifierOptions
containing the options for
the callServiceCall
with a void resultpublic com.ibm.cloud.sdk.core.http.ServiceCall<InputStream> getCoreMlModel(GetCoreMlModelOptions getCoreMlModelOptions)
Download a Core ML model file (.mlmodel) of a custom classifier that returns <tt>"core_ml_enabled": true</tt> in the classifier details.
getCoreMlModelOptions
- the GetCoreMlModelOptions
containing the options for the
callServiceCall
with a result of type InputStream
public com.ibm.cloud.sdk.core.http.ServiceCall<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 resultCopyright © 2021 IBM Cloud. All rights reserved.