Skip to content

How to create model without deploying endpoint? #49

Closed

Description

@slevental

Is it possible to create a model in SageMaker without doing tensorflow_estimator.deploy(...)?

Activity

  1. slevental commented on Jan 17, 2018

    @slevental
    Author

    Never mind, I've found solution:

    import datetime
    import sagemaker
    from sagemaker import get_execution_role
    
    sagemaker_session = sagemaker.Session()
    
    role = get_execution_role()
    model = tf_estimator.create_model()
    
    container_def = model.prepare_container_def(
        instance_type='ml.m4.xlarge'
    )
    
    model_name = f"my-model-{datetime.datetime.now():%Y-%m-%d-%H-%M}"
    sagemaker_session.create_model(model_name, role, container_def)
    
  2. added a commit that references this issue on Nov 15, 2018
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Metadata

Metadata

Assignees

No one assigned

    Labels

    No labels
    No labels

    Type

    No type

    Projects

    No projects

      Milestone

      No milestone

      Relationships

      None yet

      Development

      No branches or pull requests

      Issue actions