Firebase Machine Learning は、Google の機械学習の機能を Android アプリや Apple アプリとして提供するモバイル SDK です。その強力で使いやすいパッケージは、機械学習の経験の有無を問わず、わずか数行のコードで実装できます。ニューラル ネットワークやモデルの最適化に関する詳しい知識は必要ありません。経験豊富な ML のデベロッパーの方は、Firebase ML の便利な API を利用することで、モバイルアプリにおいてカスタム TensorFlow Lite モデルを簡単に採用できます。
主な機能
カスタムモデルをホストしてデプロイする
デバイス上での推論には、独自の TensorFlow Lite モデルを使用します。モデルを Firebase にデプロイするだけで、Google によってモデルがホスティングされ、アプリにサービスが提供されるようになります。Firebase では最新バージョンのモデルがユーザーに動的に配信されるので、アプリの新しいバージョンをユーザーに push することなく、定期的に更新できます。
Firebase ML には、一般的なモバイル ユースケース(テキストの認識、画像のラベル付け、ランドマークの識別)ですぐに使える API セットが備わっています。Firebase ML ライブラリにデータを渡すだけで、必要な情報を得ることができます。これらの API は、Google Cloud の機械学習テクノロジーを利用して、最高レベルの精度を実現します。
クラウドとデバイスの比較
Firebase ML には、クラウドまたはデバイス上で動作する API があります。ML API をクラウド用 API またはデバイス用 API として記述する場合、推論を実行するマシン、つまり、ML モデルを使用して、提供するデータに関する分析情報の取得を行うマシンを記述します。Firebase ML では、これは Google Cloud またはユーザーのモバイル デバイスで行われます。
テキスト認識、画像のラベル付け、ランドマークの認識の API では、クラウドで推論を行います。こうしたモデルには、同等のデバイスモデルよりも計算能力とメモリの使用量が多く、結果として、デバイス上のモデルよりも高い確度と精度で推論を行えます。一方、こうした API へのすべてのリクエストにはネットワーク ラウンド トリップが必要であり、動画処理などのリアルタイムで低レイテンシのアプリケーションには適していません。
カスタムモデル API は、デバイス上で実行する ML モデルを処理します。これらの機能で使用され、生成されるモデルは TensorFlow Lite モデルであり、モバイル デバイスで実行するように最適化されています。このモデルの大きな利点は、ネットワーク接続を必要とせず、動画のフレームをリアルタイムで処理できるほどに非常に高速で実行できることです。
Firebase ML では、カスタムモデルをサーバーにアップロードして、ユーザーのデバイスにデプロイできます。Firebase 対応アプリでは、オンデマンドでモデルがデバイスにダウンロードされます。これにより、アプリの初期インストール サイズを小さくして、アプリを再公開することなく ML モデルを入れ替えることが可能です。
[[["わかりやすい","easyToUnderstand","thumb-up"],["問題の解決に役立った","solvedMyProblem","thumb-up"],["その他","otherUp","thumb-up"]],[["必要な情報がない","missingTheInformationINeed","thumb-down"],["複雑すぎる / 手順が多すぎる","tooComplicatedTooManySteps","thumb-down"],["最新ではない","outOfDate","thumb-down"],["翻訳に関する問題","translationIssue","thumb-down"],["サンプル / コードに問題がある","samplesCodeIssue","thumb-down"],["その他","otherDown","thumb-down"]],["最終更新日 2025-08-04 UTC。"],[],[],null,["Firebase Machine Learning \nplat_ios plat_android plat_flutter \nUse machine learning in your apps to solve real-world problems. \n\nFirebase Machine Learning is a mobile SDK that brings Google's machine\nlearning expertise to Android and Apple apps in a powerful yet easy-to-use\npackage. Whether you're new or experienced in machine learning, you can\nimplement the functionality you need in just a few lines of code. There's no\nneed to have deep knowledge of neural networks or model optimization to get\nstarted. On the other hand, if you are an experienced ML developer,\nFirebase ML provides convenient APIs that help you use your custom\nTensorFlow Lite models in your mobile apps.\n| This is a beta release of Firebase ML. This API might be changed in backward-incompatible ways and is not subject to any SLA or deprecation policy.\n\nKey capabilities\n\n|---------------------------------------|--------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------------|\n| Host and deploy custom models | Use your own TensorFlow Lite models for on-device inference. Just deploy your model to Firebase, and we'll take care of hosting and serving it to your app. Firebase will dynamically serve the latest version of the model to your users, allowing you to regularly update them without having to push a new version of your app to users. When you use Firebase ML with [Remote Config](/docs/remote-config), you can serve different models to different user segments, and with [A/B Testing](/docs/ab-testing), you can run experiments to find the best performing model (see the [Apple](/docs/ml/ios/ab-test-models) and [Android](/docs/ml/android/ab-test-models) guides). |\n| Production-ready for common use cases | Firebase ML comes with a set of ready-to-use APIs for common mobile use cases: recognizing text, labeling images, and identifying landmarks. Simply pass in data to the Firebase ML library and it gives you the information you need. These APIs leverage the power of Google Cloud's machine learning technology to give you the highest level of accuracy. |\n\nCloud vs. on-device\n\nFirebase ML has APIs that work either in the cloud or on the device.\nWhen we describe an ML API as being a cloud API or on-device API, we are\ndescribing *which machine performs inference* : that is, which machine uses the\nML model to discover insights about the data you provide it. In Firebase ML,\nthis happens either on Google Cloud, or on your users' mobile devices.\n\nThe text recognition, image labeling, and landmark recognition APIs perform\ninference in the cloud. These models have more computational power and memory\navailable to them than a comparable on-device model, and as a result, can\nperform inference with greater accuracy and precision than an on-device model.\nOn the other hand, every request to these APIs requires a network round-trip,\nwhich makes them unsuitable for real-time and low-latency applications such as\nvideo processing.\n\nThe custom model APIs deal with ML models that run on the\ndevice. The models used and produced by these features are\n[TensorFlow Lite](https://tensorflow.org/lite) models, which are\noptimized to run on mobile devices. The biggest advantage to these models is\nthat they don't require a network connection and can run very quickly---fast\nenough, for example, to process frames of video in real time.\n\nFirebase ML provides\nthe ability to deploy custom models to your users' devices by\nuploading them to our servers. Your Firebase-enabled app will download the\nmodel to the device on demand. This allows you to keep your app's initial\ninstall size small, and you can swap the ML model without having to republish\nyour app.\n\nML Kit: Ready-to-use on-device models On June 3, 2020, we started offering ML Kit's on-device APIs through a\n| [new\n| standalone SDK](https://developers.google.com/ml-kit).\n| Google Cloud APIs and custom model deployment will\n| continue to be available through Firebase Machine Learning.\n\nIf you're looking for pre-trained models that run on the device, check out\n[ML Kit](https://developers.google.com/ml-kit). ML Kit is available\nfor iOS and Android, and has APIs for many use cases:\n\n- Text recognition\n- Image labeling\n- Object detection and tracking\n- Face detection and contour tracing\n- Barcode scanning\n- Language identification\n- Translation\n- Smart Reply\n\nNext steps\n\n- Explore the ready-to-use APIs: [text recognition](/docs/ml/recognize-text), [image labeling](/docs/ml/label-images), and [landmark recognition](/docs/ml/recognize-landmarks).\n- Learn about using mobile-optimized [custom models](/docs/ml/use-custom-models) in your app."]]