Skip to content

Pydoc edits #480

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Merged
merged 2 commits into from
Aug 12, 2020
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
22 changes: 12 additions & 10 deletions firebase_admin/ml.py
Original file line number Diff line number Diff line change
Expand Up @@ -78,7 +78,7 @@ def _get_ml_service(app):


def create_model(model, app=None):
"""Creates a model in Firebase ML.
"""Creates a model in the current Firebase project.

Args:
model: An ml.Model to create.
Expand All @@ -92,7 +92,7 @@ def create_model(model, app=None):


def update_model(model, app=None):
"""Updates a model in Firebase ML.
"""Updates a model's metadata or model file.

Args:
model: The ml.Model to update.
Expand All @@ -106,7 +106,9 @@ def update_model(model, app=None):


def publish_model(model_id, app=None):
"""Publishes a model in Firebase ML.
"""Publishes a Firebase ML model.

A published model can be downloaded to client apps.

Args:
model_id: The id of the model to publish.
Expand All @@ -120,7 +122,7 @@ def publish_model(model_id, app=None):


def unpublish_model(model_id, app=None):
"""Unpublishes a model in Firebase ML.
"""Unpublishes a Firebase ML model.

Args:
model_id: The id of the model to unpublish.
Expand All @@ -134,7 +136,7 @@ def unpublish_model(model_id, app=None):


def get_model(model_id, app=None):
"""Gets a model from Firebase ML.
"""Gets the model specified by the given ID.

Args:
model_id: The id of the model to get.
Expand All @@ -148,7 +150,7 @@ def get_model(model_id, app=None):


def list_models(list_filter=None, page_size=None, page_token=None, app=None):
"""Lists models from Firebase ML.
"""Lists the current project's models.

Args:
list_filter: a list filter string such as ``tags:'tag_1'``. None will return all models.
Expand All @@ -167,7 +169,7 @@ def list_models(list_filter=None, page_size=None, page_token=None, app=None):


def delete_model(model_id, app=None):
"""Deletes a model from Firebase ML.
"""Deletes a model from the current project.

Args:
model_id: The id of the model you wish to delete.
Expand Down Expand Up @@ -602,7 +604,7 @@ def as_dict(self, for_upload=False):


class TFLiteAutoMlSource(TFLiteModelSource):
"""TFLite model source representing a tflite model created via AutoML."""
"""TFLite model source representing a tflite model created with AutoML."""

def __init__(self, auto_ml_model, app=None):
self._app = app
Expand All @@ -618,7 +620,7 @@ def __ne__(self, other):

@property
def auto_ml_model(self):
"""Resource name of the model created by the AutoML API."""
"""Resource name of the model, created by the AutoML API or Cloud console."""
return self._auto_ml_model

@auto_ml_model.setter
Expand All @@ -632,7 +634,7 @@ def as_dict(self, for_upload=False):


class ListModelsPage:
"""Represents a page of models in a firebase project.
"""Represents a page of models in a Firebase project.

Provides methods for traversing the models included in this page, as well as
retrieving subsequent pages of models. The iterator returned by
Expand Down