Coder Social home page Coder Social logo

geo-runtime-sm's Introduction

Creating a custom Sagemaker image

This repo creates an docker image on AWS ECR then creates a sagemaker image

IMAGE_NAME=geo-runtime

See AWS repo for more examples.

Below is the skeleton

Coiled is used to create the conda-docker image hosted on ECR. This requires an account on Coiled (and setting AWS as the backend) i.e set software environments to be hosted on AWS ECR.

Coiled creates the ECR repository and the docker image for you.

  1. Use coiled to create an docker image with environment file
import coiled
coiled.create_software_environment(
	name = "<ENV_NAME>",
	conda = "environment.yml"
	)

Include awscli, boto3, ipykernel in env build to for Sagemaker

  1. Using aws cli, use the docker image in ECR to create a sagemaker image aws --region ${REGION} sagemaker create-image
    1. get sagemaker executioner role i.e. ROLE ARN from AWS console (in Sagemaker)
    2. provide the docker image in ECR as the base image

Sagemaker domains are defined per region (/per user) hence we need to specify region above

  1. Create AppImageConfig
  2. Update domain (add to image dictionary to json file)

Notes

Coiled’s Docker file command

RUN conda env update -n coiled -f environment.yml && rm environment.yml && conda clean --all -y && echo "conda activate coiled" >> ~/.bashrc

geo-runtime-sm's People

Contributors

apurba-biswas avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.