Product Selector

Fusion 5.11
    Fusion 5.11

    Creating the Upload Model Parameters to Cloud Job

    The Upload Model Parameters to Cloud job lets you store a trained model’s training to a blob in cloud storage.

    This document describes the steps to create the Upload Model Parameters to Cloud job and deploy a model with it.

    See Upload Model Parameters to Cloud to learn more about the Upload Model Parameters to Cloud job.

    Create the job

    1. In the Collections > Jobs menu, click Add + and select Upload Model Parameters to Cloud to create a new instance of that job.

    2. Set the job ID to upload-cloud(or something appropriate for your model) and find the name of the deployed model in the Model Name text box.

    3. Enter the Cloud Path to direct to the location you would like to store the parameters blob in.

      You will also need to provide the Kubernetes secret that provides the access details for the cloud storage path. ​

    4. Run the job, then check the cloud storage location to verify that the parameter file has been saved.

      The exported file will also have the version number (based on epoch time) of the model appended to it.

    Take note of the full cloud path; you will need it to deploy the job later.

    Creating the Job

    GCS

    1. Obtain the Google Cloud Storage credentials JSON file for accessing the storage bucket you intend to use for transferring models.

    2. Add the credentials JSON file as a secret with the following command: ​

    kubectl create secret generic model-cloud-secret --from-file=credentials.json -n [NAMESPACE]

    S3

    1. Create a JSON file with the following keys:

    ”region” is optional and will be set to us-east-1 if a value is not entered ​
    {
       "key": [KEY],
       "secret": [SECRET],
       "region": [REGION]
    }
    1. Upload the JSON file as a secret in the cluster: ​

    kubectl create secret generic model-cloud-secret --from-file=model.json -n [NAMESPACE]

    The secret can now be referenced as model-cloud-secret in the job configuration.

    Azure Blob Storage

    1. Create a JSON file with the layout below: ​

    {
       "key": [KEY],
       "secret": [SECRET]
    }
    1. Create the model-cloud-secret secret in the Kubernetes cluster:

    kubectl create secret generic model-cloud-secret --from-file=model.json -n [NAMESPACE]

    Deploy a new model with the Upload Model Parameters job

    The new model can run in either the same Fusion cluster or a different cluster.

    If you are planning on transferring a model to a different cluster, note that you will need to set up the Kubernetes secrets in that cluster as well, though the access for deploying can be limited to read-only.

    1. Create a new Create Seldon Core Model Deployment job and toggle Advanced.

    2. Enter the full cloud path, including the version number, in the Cloud Path box.

    3. Enter the Kubernetes secret that will be used to access the path in the Kubernetes Secret Name for Cloud Storage Access box. ​

    4. For this example, you will be using the job to deploy a trained Smart Answers model, so use the fusion-question-answering-seldon:5.4.0 model image from the lucidworks repository in the Image Name box.

    Deploying the model

    1. Run the job. Confirm that the model deploys into the cluster and is running.