LoginSignup
1
1

More than 3 years have passed since last update.

AWS SageMakerで既存のendpointを呼び出す

Last updated at Posted at 2020-09-29

概要

SageMakerでendpointを立ち上げ、他のnotebookなどで使用したい場合の指定方法を示す。

コード

引数にendpoint_nameを指定する。
endpoint_nameはAWSコンソール->SageMaker->推論->エンドポイントで確認できる。

MxNet


import sagemaker
predictor = sagemaker.mxnet.model.MXNetPredictor(endpoint_name="mxnet-training-*")

PyTorch


import sagemaker
predictor = sagemaker.pytorch.model.PyTorchPredictor(endpoint_name="pytorch-training-*")

おわりに

notebookが落ちてしまった場合や新しいnotebookで使うことができるようになります。

1
1
0

Register as a new user and use Qiita more conveniently

  1. You get articles that match your needs
  2. You can efficiently read back useful information
  3. You can use dark theme
What you can do with signing up
1
1