public class VisualRecognition
extends com.ibm.watson.developer_cloud.service.WatsonService
| Modifier and Type | Field and Description |
|---|---|
static java.lang.String |
VERSION_DATE_2016_05_20
Version date.
|
| Constructor and Description |
|---|
VisualRecognition(java.lang.String versionDate)
Instantiates a new Visual Recognition V3 service.
|
VisualRecognition(java.lang.String versionDate,
java.lang.String apiKey)
Instantiates a new Visual Recognition V3 service with a given API key.
|
| Modifier and Type | Method and Description |
|---|---|
com.ibm.watson.developer_cloud.http.ServiceCall<java.lang.Void> |
addImageToCollection(AddImageToCollectionOptions options)
Adds the image to collection.
|
com.ibm.watson.developer_cloud.http.ServiceCall<VisualClassification> |
classify(ClassifyImagesOptions options)
Classify.
|
com.ibm.watson.developer_cloud.http.ServiceCall<VisualClassifier> |
createClassifier(ClassifierOptions options)
Train a new classifier on the uploaded image data.
|
com.ibm.watson.developer_cloud.http.ServiceCall<Collection> |
createCollection(java.lang.String name)
Creates a collection.
|
com.ibm.watson.developer_cloud.http.ServiceCall<java.lang.Void> |
deleteClassifier(java.lang.String classifierId)
Deletes a classifier.
|
com.ibm.watson.developer_cloud.http.ServiceCall<java.lang.Void> |
deleteCollection(java.lang.String collectionId)
Deletes a collection.
|
com.ibm.watson.developer_cloud.http.ServiceCall<java.lang.Void> |
deleteCollectionImage(java.lang.String collectionId,
java.lang.String imageId)
Deletes a collection.
|
com.ibm.watson.developer_cloud.http.ServiceCall<DetectedFaces> |
detectFaces(VisualRecognitionOptions options)
Detect faces.
|
com.ibm.watson.developer_cloud.http.ServiceCall<java.util.List<CollectionImage>> |
findSimilarImages(FindSimilarImagesOptions options)
Find similar images.
|
com.ibm.watson.developer_cloud.http.ServiceCall<VisualClassifier> |
getClassifier(java.lang.String classifierId)
Retrieve information about a specific classifier.
|
com.ibm.watson.developer_cloud.http.ServiceCall<java.util.List<VisualClassifier>> |
getClassifiers()
Retrieve the user-trained classifiers.
|
com.ibm.watson.developer_cloud.http.ServiceCall<Collection> |
getCollection(java.lang.String collectionId)
Gets the collection information.
|
com.ibm.watson.developer_cloud.http.ServiceCall<CollectionImage> |
getCollectionImage(java.lang.String collectionId,
java.lang.String imageId)
Gets the collection image.
|
com.ibm.watson.developer_cloud.http.ServiceCall<java.util.List<CollectionImage>> |
getCollectionImages(java.lang.String collectionId)
Gets the collection images.
|
com.ibm.watson.developer_cloud.http.ServiceCall<java.util.List<Collection>> |
getCollections()
Gets the collections.
|
com.ibm.watson.developer_cloud.http.ServiceCall<RecognizedText> |
recognizeText(VisualRecognitionOptions options)
Recognize text.
|
protected void |
setAuthentication(okhttp3.Request.Builder builder) |
void |
setUsernameAndPassword(java.lang.String username,
java.lang.String password)
Deprecated.
|
com.ibm.watson.developer_cloud.http.ServiceCall<VisualClassifier> |
updateClassifier(java.lang.String classifierId,
ClassifierOptions options)
Update an existing classifier by adding new classes, or by adding new images to existing classes.
|
public static final java.lang.String VERSION_DATE_2016_05_20
public VisualRecognition(java.lang.String versionDate)
versionDate - The version date (yyyy-MM-dd) of the REST API to use. Specifying this value will keep your API
calls from failing when the service introduces breaking changes.public VisualRecognition(java.lang.String versionDate,
java.lang.String apiKey)
versionDate - The version date (yyyy-MM-dd) of the REST API to use. Specifying this value will keep your API
calls from failing when the service introduces breaking changes.apiKey - the api keyprotected void setAuthentication(okhttp3.Request.Builder builder)
setAuthentication in class com.ibm.watson.developer_cloud.service.WatsonServicepublic com.ibm.watson.developer_cloud.http.ServiceCall<VisualClassification> classify(ClassifyImagesOptions options)
options - the classify optionsVisualClassificationpublic com.ibm.watson.developer_cloud.http.ServiceCall<VisualClassifier> createClassifier(ClassifierOptions options)
options - The parameters to create a classifierVisualClassifierClassifierOptions,
VisualClassifierpublic com.ibm.watson.developer_cloud.http.ServiceCall<VisualClassifier> updateClassifier(java.lang.String classifierId, ClassifierOptions options)
classifierId - the classifier idoptions - The parameters to create a classifierVisualClassifierClassifierOptions,
VisualClassifierpublic com.ibm.watson.developer_cloud.http.ServiceCall<java.lang.Void> deleteClassifier(java.lang.String classifierId)
classifierId - the classifier ID to deleteVisualClassifierpublic com.ibm.watson.developer_cloud.http.ServiceCall<DetectedFaces> detectFaces(VisualRecognitionOptions options)
options - the recognize text optionsVisualClassificationpublic com.ibm.watson.developer_cloud.http.ServiceCall<VisualClassifier> getClassifier(java.lang.String classifierId)
classifierId - the classifier IDVisualClassifierpublic com.ibm.watson.developer_cloud.http.ServiceCall<java.util.List<VisualClassifier>> getClassifiers()
VisualClassifierpublic com.ibm.watson.developer_cloud.http.ServiceCall<RecognizedText> recognizeText(VisualRecognitionOptions options)
options - the recognize text optionsRecognizedText@Deprecated
public void setUsernameAndPassword(java.lang.String username,
java.lang.String password)
api_key instead of username and password. WatsonService.setApiKey(String)setUsernameAndPassword in class com.ibm.watson.developer_cloud.service.WatsonServiceusername - the usernamepassword - the passwordpublic com.ibm.watson.developer_cloud.http.ServiceCall<java.util.List<Collection>> getCollections()
public com.ibm.watson.developer_cloud.http.ServiceCall<Collection> getCollection(java.lang.String collectionId)
collectionId - the collection idpublic com.ibm.watson.developer_cloud.http.ServiceCall<java.lang.Void> deleteCollection(java.lang.String collectionId)
collectionId - the collection idpublic com.ibm.watson.developer_cloud.http.ServiceCall<java.lang.Void> deleteCollectionImage(java.lang.String collectionId,
java.lang.String imageId)
collectionId - the collection idimageId - the image idpublic com.ibm.watson.developer_cloud.http.ServiceCall<java.lang.Void> addImageToCollection(AddImageToCollectionOptions options)
options - the optionspublic com.ibm.watson.developer_cloud.http.ServiceCall<java.util.List<CollectionImage>> getCollectionImages(java.lang.String collectionId)
collectionId - the collection idpublic com.ibm.watson.developer_cloud.http.ServiceCall<CollectionImage> getCollectionImage(java.lang.String collectionId, java.lang.String imageId)
collectionId - the collection idimageId - the imageIdpublic com.ibm.watson.developer_cloud.http.ServiceCall<java.util.List<CollectionImage>> findSimilarImages(FindSimilarImagesOptions options)
options - the optionspublic com.ibm.watson.developer_cloud.http.ServiceCall<Collection> createCollection(java.lang.String name)
name - the collection name