> For the complete documentation index, see [llms.txt](https://danielsogl.gitbook.io/awesome-cordova-plugins/llms.txt). Markdown versions of documentation pages are available by appending `.md` to page URLs; this page is available as [Markdown](https://danielsogl.gitbook.io/awesome-cordova-plugins/plugins/plugins/firebase-model.md).

# Firebase Model

This plugin downloads the TensorFlow model from firebase and classify the images.

```typescript
import { FirebaseModel } from '@awesome-cordova-plugins/firebase-model';


constructor(private firebaseModel: FirebaseModel) { }

...


this.firebaseModel.configure('Sample_Model')
  .subscribe((res: FirebaseModelConfigResult) => console.log(res.status + " - " + res.progress))
  .catch((error: any) => console.error(error));


try {
   var result:FirebaseModelClassifyResult = await this.firebaseModel.classify("/Documents/input_image.png")
   console.log(result.label + " - " + result.score)

}
catch (e) {
   console.log(e)
}


```

## Installation

```bash
ionic cordova plugin add cordova-plugin-firebase-model
npm install @awesome-cordova-plugins/firebase-model
```

## Supported Platforms

* iOS

## Further Information

* [Installation Guide](/awesome-cordova-plugins/installation.md)
* [FAQ](/awesome-cordova-plugins/faq.md)
