Entry class for Firebase machine learning vision services.
To use this class, get an instance via getInstance()
or
getInstance(FirebaseApp), and then get an instance of a detector. The code below
is an example of getting an instance of a face detector:
FirebaseVisionFaceDetector faceDetector = FirebaseVision.getInstance().getVisionFaceDetector();
See individual detector classes for details.
Gets a
FirebaseVisionDocumentTextRecognizer that can detect document text in a
supplied image.
| options | the options for the cloud text detector. |
|---|
FirebaseVisionDocumentTextRecognizer. Note that text detector instance
will be the same instance if the supplied options are the same and under the same
FirebaseVision.Gets a
FirebaseVisionDocumentTextRecognizer that can detect document text in a
supplied image with default options.
FirebaseVisionDocumentTextRecognizer. Note that multiple calls of this API
would always return the same cloud document text instance and under the same
FirebaseVision.Gets a cloud version of
FirebaseVisionImageLabeler that can detect labels in a supplied image.
| options | the options for the cloud image labeler. |
|---|
FirebaseVisionImageLabeler. Note that image labeler instance will be the
same instance if the supplied options are the same and under the same FirebaseVision.Gets a cloud version of
FirebaseVisionImageLabeler that can detect labels in a supplied image with
default options.
FirebaseVisionImageLabeler. Note that multiple calls of this API would
always return the same cloud label instance and under the same FirebaseVision.Gets a
FirebaseVisionTextRecognizer to perform optical character recognition with
cloud model and default options.
FirebaseVisionTextRecognizer. Note there is only one instance of cloud
FirebaseVisionTextRecognizer and under the same FirebaseVision.Gets a
FirebaseVisionTextRecognizer to perform optical character recognition with
cloud model and provided options.
FirebaseVisionTextRecognizer. Note that the returned instance will be the
same if the supplied options are the same and under the same FirebaseVision.Gets an instance of FirebaseVision
associated with the default FirebaseApp.
Gets an instance of FirebaseVision
associated with the supplied FirebaseApp.
| app | the FirebaseApp
to associate this FirebaseVision
with. |
|---|
Gets an on device version of
FirebaseVisionImageLabeler that labels a supplied image, using a model
trained from Firebase AutoML.
| options | the options for the on device automl image labeler. |
|---|
FirebaseVisionImageLabeler. Note that multiple calls of this API would
always return the same image labeler instance and under the same FirebaseVision.| FirebaseMLException | if failed to instantiate a
FirebaseVisionImageLabeler. |
|---|
Gets an on device version of
FirebaseVisionImageLabeler that labels a supplied image with a default
FirebaseVisionOnDeviceImageLabelerOptions.
FirebaseVisionImageLabeler. Note that multiple calls of this API would
always return the same image label detector instance and under the same
FirebaseVision.Gets an on device version of
FirebaseVisionImageLabeler that labels a supplied image.
| options | the options for the on device image labeler. |
|---|
FirebaseVisionImageLabeler. Note that image labeler instance will be the
same instance if the supplied options are the same and under the same FirebaseVision.Gets a
FirebaseVisionObjectDetector that can detect objects in a supplied image
with default options.
FirebaseVisionObjectDetector. Note that multiple calls of this API would
always return the same object detector instance and under the same FirebaseVision.Gets a
FirebaseVisionObjectDetector that can detect objects in a supplied image
with given options.
FirebaseVisionObjectDetector. Note that multiple calls of this API would
always return the same object detector instance if the supplied options are the same
and under the same FirebaseVision.Gets a
FirebaseVisionTextRecognizer to perform optical character recognition with
on-device model.
FirebaseVisionTextRecognizer. Note there is only one instance of on-device
FirebaseVisionTextRecognizer and under the same FirebaseVision.Gets a
FirebaseVisionBarcodeDetector that can detect barcodes in a supplied
image.
| options | the options for the barcode detector. |
|---|
FirebaseVisionBarcodeDetector. Note that barcode detector instance will be
the same instance if the supplied options are the same and under the same
FirebaseVision.Gets a
FirebaseVisionBarcodeDetector that can detect barcodes in a supplied image
with a default
FirebaseVisionBarcodeDetectorOptions.
FirebaseVisionBarcodeDetector. Note that multiple calls of this API would
always return the same barcode detector instance and under the same FirebaseVision.Gets a
FirebaseVisionCloudLandmarkDetector that can detect landmark in a supplied
image with default options.
FirebaseVisionCloudLandmarkDetector. Note that multiple calls of this API
would always return the same cloud landmark instance and under the same
FirebaseVision.Gets a
FirebaseVisionCloudLandmarkDetector that can detect landmark in a supplied
image.
| options | the options for the cloud landmark detector. |
|---|
FirebaseVisionCloudLandmarkDetector. Note that landmark detector instance
will be the same instance if the supplied options are the same and under the same
FirebaseVision.Gets a
FirebaseVisionFaceDetector that detects faces in a supplied image with a
default
FirebaseVisionFaceDetectorOptions.
FirebaseVisionFaceDetector. Note that multiple calls of this API would
always return the same cloud face instance and under the same FirebaseVision.Gets a
FirebaseVisionFaceDetector that detects faces in a supplied image.
| options | the options for the face detector. |
|---|
FirebaseVisionFaceDetector. Note that face detector instance will be the
same instance if the supplied options are the same and under the same FirebaseVision.Determines whether stats collection in FirebaseVision
is enabled or disabled
Enables stats collection in ML Kit vision. The stats include API calls counts, errors, API call durations, options, etc. No personally identifiable information is logged.
The setting is per FirebaseApp,
and it is persistent together with app's private data. It means if the user uninstalls
the app or clears all app data, the setting will be erased. The best practice is to set
the flag in each initialization.
By default the logging is enabled. You have to specifically set it to false to disable logging.