Closed Jeffwan closed 4 years ago
Put it here for backup
# Login Dockerhub
# !docker login -u <your_username> -p <your_password>
# You suppose to see logs like
# WARNING! Using --password via the CLI is insecure. Use --password-stdin.
# Login Succeeded
# Setting up DockerHub container repositories for storing output containers
DOCKERHUB_USERNAME = 'seedjeffwan'
DOCKER_REGISTRY = '{}'.format(DOCKERHUB_USERNAME)
fairing.config.set_builder('append', base_image='tensorflow/tensorflow:1.14.0-py3', registry=DOCKER_REGISTRY, push=True)
fairing.config.set_deployer('job')
if __name__ == '__main__':
remote_train = fairing.config.fn(train)
remote_train()
# Option 1: Install Fairing Python SDK from python repository
!pip install kubeflow-fairing
# Option 2: Install latest Fairing from github repository (If you'd like to try new features)
# !git clone https://github.com/kubeflow/fairing
# Since some of our patches have not been merged back to upstream. Let's install branch version with all the fixes
!git clone --single-branch --branch master https://github.com/kubeflow/fairing
## Deploy persist model to KF Serving
from kubeflow import fairing
if __name__ == '__main__':
fairing.config.set_deployer('kfserving', namespace='kubeflow', framework='tensorflow',
default_model_uri='s3://kfserving-samples/models/tensorflow/flowers', cleanup=True)
fairing.config.run()
Based on users' feedback, someone run into issues in some of the notebooks.
Let's remove them temporarily to reduce confusion.