SlideShare a Scribd company logo
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
AWS 기반 비용 효율적 고성능
기계학습(ML) 플랫폼 뛰어들기
윤석찬 / AWS 테크니컬 에반젤리스트
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
본 세션에서 다루는 점
 클라우드 기반 기계 학습 및 딥러닝 모델 훈련 방법을 알고
싶으세요?
 시간과 비용을 적게 들이고 빠르게 좋은 모델을 만들고
싶으세요?
 모델 훈련 및 서비스까지 자동화 하는 방법에 대한 고민이
많으세요?
 추론 작업을 좀 더 빠르게 하는 방법을 알고 싶으세요?
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
FRAM EW O RKS
ML 프레임워크
+ 인프라
ML 서비스
AI 서비스
I NTERFACES I NFRASTRUCTURE
Am azon
SageM ak er
Amazon
Lex
C H A T B OT S
Amazon
Rekognition
Image
Amazon
Rekognition
Video
V IS ION
Amazon
Transcribe
Amazon
Polly
S P E E C H
Amazon
Comprehend
Amazon
Translate
L A N GU A GE S
P3 P3dn C5 C5n Elastic inference Inferentia AWS Greengrass
N E WN E W
Ground Truth Notebooks Algorithms + Marketplace RL Training Optimization Deployment Hosting
N E W N E W N E W N E W
Amazon
Personalize
Amazon
Forecast
V E R T IC A L
N E W N E W
Amazon
Textract
N E W
모든 개발자를 위한 인공 지능 도구 제공
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
AWS Deep Learning AMIs
다양한 딥러닝 프레임워크를 미리 설치하고
최적 설정을 완료한 머신 이미지(Machine Image) 제공
https://aws.amazon.com/machine-learning/amis/
Conda AMI
별도 가상 환경에 사전 설치된 딥
러닝 프레임워크 및 PIP 패키지
제공
(우분투, 아마존리눅스, 윈도용)
Base AMI
개별 딥러닝 엔진 리포지토리
또는 맞춤형 빌드를 설치
가능
(우분투, 아마존리눅스용)
AMI with source code
공유 Python 개발 환경에서 DL
엔진 및 소스 코드를 함께 제공
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
심지어 Deep Learning AMI는 진짜 빠릅니다!
https://aws.amazon.com/ko/blogs/machine-learning/faster-training-with-optimized-
tensorflow-1-6-on-amazon-ec2-c5-and-p3-instances/
차세대 C5 인스턴스에서 Intel AVX 및 MKL-dnn에 최적화된 TensorFlow 1.6 포함
ImageNet 데이터세트로 일반 바이너리 버전 대비 7.4배 빠른 모델 훈련 속도 제공
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
AVX 512
72 vCPUs
“Skylake”
144 GiB memory
C5
12 Gbps to EBS
2X vCPUs
2X performance
3X throughput
2.4X memory
C4
36 vCPUs
“Haswell”
4 Gbps to EBS
60 GiB memory
Intel® AVX-512 고급 명령어
세트를 지원하므로 AI/기계 학습
또는 동영상 처리와 같은 단일 및
이중 부동 소수점 정밀도 기반
벡터 처리 작업을 효율적으로
수행
여기서 잠깐! C5 인스턴스 이란?
차세대 클라우드 가상화 환경인 Nitro를 기반한 컴퓨팅 전용 타입
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
EC2 P3 인스턴스 - 클라우드 기반 고성능 GPU 지원
P3 인스턴스 세부 정보
• NVIDIA Tesla V100 GPU 기반
• 40,960 CUDA cores 및 5120 Tensor Codes
• 128GB의 GPU 메모리
• 최대 8개의 GPU를 지원하는 다양한 인스턴스
타입 (p3.2xlarge, 8xlarge 및 16xlarge) 제공
1 PetaFLOPs의 컴퓨팅 성능 제공
300 GB/s GPU-to-GPU(NVLink) 네트워크 속도
만약… 인터넷에서 구매하시면?
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
EC2 P3 인스턴스로 GPU 클러스터를 만들어 본다면?
p3.2xlarge
= $5 per hour
(서울 리전 기준)
x 20
CPU 2,000 개 연산 능력
p3.2xlarge x 20
= $100 per hour
초당 1페타플롭스 (CPU 100개에 해당 하는 연산 능력)
남는 여유 자원을 70% 할인된 가격에
모델 훈련 시에만 사용한다면
= $30 per hour
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
손으로 하실 필요 없어요~ 인프라를 코드로 짜면 됩니다!
$aws ec2-run-instances ami-b232d0db
--instance-count 1
--instance-type p2.8xlarge
--region us-east-1
--user-data my_data_training.sh
$aws ec2-stop-instances i-10a64379
API와 데브옵스를 통해 손쉽게 딥러닝 클러스터 구성 가능
다양한 CI/CD 기반 데브옵스 환경으로 빠른 학습 가능
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
여러분… 인생은 짧습니다! 시간을 아끼세요~
http://www.fast.ai/2018/08/10/fastai-diu-imagenet/
https://aws.amazon.com/blogs/machine-learning/new-speed-record-set-for-training-deep-learning-models-on-aws/
• 16개의 P3.16xlarge 인스턴스를 사용해서
18분만에 ResNet-50 모델 학습 완료 (정확도 93%)
• 저렴한 스팟 인스턴스 구매 옵션을 활용하여 $40 비용에 처리 가능
• PyTorch 기반으로 기존 DAWNBench 기록 보다 40% 빠른 속도
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
1
4.75
8.5
12.25
16
1 4.75 8.5 12.25 16
Speedup(x)
# GPUs
Resnet 152
Inceptin V3
Alexnet
Ideal
여기서 잠깐… 시간을 더 아끼시려면?
P2.16xlarge (8 Nvidia Tesla K80 - 16 GPUs)
Synchronous SGD (Stochastic Gradient Descent)
91%
Efficiency
88%
Efficiency
16x P2.16xlarge by AWS CloudFormation
Mounted on Amazon EFS
Apache MXNet은 GPU 갯수가 증가하더라도 이상적인 수준의 성능을 보여주는
오픈 소소 딥러닝 프레임워크로서 멀티 GPU 환경에서 탁월한 성능 제공
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
MXNET 공부하세요…
아직은 블루오션입니다!
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Demo - 딥러닝 AMI와 스팟 인스턴스 구동하기
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
데이터 수집
및 저장 및
전처리
괜찮아 보이는
기계학습
알고리즘 선택
모델 훈련을
위한 서버
인프라 설정
모델 훈련
및 튜닝
(계속 반복)
최적화한
모델 배포
API 서비스
확장 및 운영
기계학습은 일반 개발자에게 여전히 복잡하고 어렵다?!
지겨운 데이터 전처리… 모델 튜닝… 될때까지 계속 반복&반복
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
그래서 준비했습니다… Amazon SageMaker
모델 생성
Jupyter
Notebook
기반 서비스
고성능
알고리즘
미리 제공
원클릭
데이터
훈련
모델 훈련
Hyper-
parameter
최적화
완전 관리
및 자동
스케일링
모델 배포
원클릭
모델
배포
모델 개발 및 생성, 훈련 및 서비스 배포를 위한 완전 관리 서비스
https://aws.amazon.com/ko/sagemaker
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
SageMaker를 통한 ML 서비스 아키텍처
SageMaker
Notebooks
Training
Algorithm
SageMaker
Training
Amazon ECR
Code Commit
Code Pipeline
SageMaker
Hosting
AWS
Lambda
API
Gateway
Build Train
Deploy
static website
hosted on S3
Inference requests
Amazon S3
Amazon
Cloudfront
Web assets on
Cloudfront
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
SageMaker 기반 ML 모델 생성 및 훈련
K-Means Clustering
Principal Component Analysis
Neural Topic Modelling
Factorization Machines
Linear Learner - Regression
XGBoost
Latent Dirichlet Allocation
Image Classification
Seq2Seq
Linear Learner - Classification
BUILT
ALGORITHMS
Caffe2, CNTK, PyTorch, Torch
IM Estimators in Spark
DEEP LEARNING
FRAMEWORKS
Bring Your Own Script
(IM builds the Container)
BRING YOUR OWN
MODEL
ML
Training
code
Fetch Training data
Save Model
Artifacts
Amazon ECR
Save Inference
Image
Amazon S3
AWS MARKETPLACE
MACHINE LEARNING
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
SageMaker - 자동 하이퍼 파라미터 최적화(HPO) 기능
https://medium.com/datadriveninvestor/auto-model-tuning-for-keras-on-amazon-sagemaker-plant-seedling-dataset-7b591334501e
https://aws.amazon.com/blogs/machine-learning/amazon-sagemaker-automatic-model-tuning-produces-better-models-faster/
CPU (ml.m5.xlarge) 작업 시
Speed = 4 mins/epoch
Total Runtime = ~20 hours
Cost = .269 * 20 = $5.38
GPU (ml.p2.xlarge) 작업 시
Speed = 4.8 seconds/epoch
Total Runtime = ~3 hours
Cost = 1.26 * 3 = $3.78
Keras 기반 Plant Seedling
Dataset을 위한 CNN 학습 모델
(최대 150 Epoch 학습)
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
$$$$
$$$
$$
$
Minutes Hours Days Weeks Months
Single
Machine
Distributed, with
Strong Machines
ML 모델 훈련에 대한 비용과 시간 대비 효과
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
$$$$
$$$
$$
$
Minutes Hours Days Weeks Months
EC2 + AMI
Amazon SageMaker
On-premise
ML 모델 훈련에 대한 비용과 시간 대비 효과
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Demo – SageMaker 기반 모델 훈련하기
사례. SageMaker 기반 기계 학습 구현 사례
“광고 기술 서비스 스타트업인 IGAWorks는 AWS 기반으로
일 50억 건의 디스플레이 광고 요청를 처리하는
트레이딩웍스와 22,000여개 모바일 앱이 탑재된
애드브릭스 등을 운영하고 있습니다. 광고 효율 개선 및
지속적인 최적화를 위한 기계 학습 모델 관리의 편의성과
프로덕션 적용 시간을 단축하는 Amazon SageMaker를
도입해 A.I Lab의 업무 효율성이 높아졌습니다.
기업 규모와 상관 없이
다양한 고객 활용 중!
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
추론 작업이 전체 기계 학습
비용의 대부분을 차지함 Inference
Training
Infrastructure
costs
추론 Inference 작업은?
Machine Learning 모델 학습은 쉽고,
빠르며, 비용 효과적으로 가능하지만…
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
추론 비효율의 두 가지 주요 요인 :
복잡성 및 비용
다양한 추론
케이스가 존재
탄력적인 추론이
가능해야 함
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
추론 작업을 더 효율적으로 하는 방법
더 작은 P2 인스턴스를 더 작은 배치 크기로 실행하는 것이 더 효과적입니다.
N E W !
EC2
Instance
EC2
Instance
EC2
Instance
GPU
훨씬 저렴한 비용으로 신속한 추론을 위해 Amazon EC2 인스턴스에 GPU 가속 기능 추가 (최대 75 % 절감)
Amazon
Elastic Inference
P 3 . 8 X L
P 3 P 3
P 3 P 3
Amazon
Elastic Inference
36 TOPS GPU
M5.large
Amazon
Elastic Inference
Before After
N E W !
고성능 처리량
낮은 대기시간
수백 TOPS 지원
다양한
데이터 타입
다양한
ML 프레임워크
INT8, FP16,
mixed precision
TensorFlow, MXNet,
PyTorch, Caffe2, ONNX
EC2 인스턴스 지원
Amazon SageMaker 지원
Amazon Elastic Inference 지원
고성능 기계 학습 추론을 위한 AWS에서 설계 한 맞춤형 칩셋
AWS Inferentia
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
Starting at
1 TFLOPS
다양한 인스턴스
타입 활용 가능
간단한 음성 인식 및
자연어 처리 모델
Up to
32 TFLOPS
추천 엔진 또는 사기
탐지 모델
VPC 내부의 추론
탄력성 보장
360,000ResNet-50
컴퓨터 비전 사례
딥러능 모델
추론에 필요한 시간당
이미지 숫자
$0.22
시간당 비용
75%
기존 대비
비용 절감
L O W E S T C O S T
A V A I L A B L E
Amazon Elastic Inference - 확장성 및 비용
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
원하는 용량에 따라 가속기 타입 추가 가능
Accelerator
Type
FP32
Throughput
(TOPS)
FP16
Throughput
(TOPS)
Accelerator
Memory
(GB)
Price ($/hr)
(US)
eia1.medium 1 8 1 $0.13
eia1.large 2 16 2 $0.26
eia1.xlarge 4 32 4 $0.52
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
기존 GPU와 Elastic Inference와 비용 차이
0
20
40
60
80
100
120
0
10
20
30
40
50
60
70
0
20
40
60
80
100
120
140
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
EC2에 활용하는 방법
VPC
Region
Availability Zone
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
EC2 Auto Scaling groups에 적용하기
Auto Scaling group
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
SageMaker에 적용하기
SageMaker Notebooks
SageMaker Hosted Endpoints
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Elastic Inference 설정 및 사용 방법
$ aws ec2 run-instances
--image-id <preconfigured_ami_id>
--instance-type <ec2_instance_type>
--key-name <key_name>
--subnet-id <subnet_id>
--security-group-ids <security_group_id
--iam-instance-profile Name=”iam_profile_name”
--elastic-inference-accelerator Type=eia1.<size>
• 일반 EC2 인스턴스 선택 후, 미리 설정된 AMI에서 원하는 EI 가속기 선택
• EI 가속기가 접속할 수 있는 VPC 엔드포인트 권한 설정 필수
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
© 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved.
Elastic Inference 설정 및 사용 방법
classifier = tf.estimator.Estimator(…)
input_tensor = tf.placeholder(dtype=tf.float32,
shape=[1, 80, 128, 128, 1],
name='images_tensor’)
input_map = {'images’ : input_tensor}
classifier.export_savedmodel(model_dir,
tf.estimator.export.build_raw_serving_input_receiver_fn(input_map))
• MVCNN 모델 등 TF Estimators 포맷에 추가
• Dimensions: [batch_size , num_views , width , height , color_channels]
AmazonEI_TensorFlow_Serving_v1.11_v1 --model_name=mvcnn 
--model_base_path=model_dir --port=9000
• Tensorflow Serving API를 이용하여 모델 예측 사용
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
맺으면서
• AWS Deep Learning AMI를 사용하시면, 기존 EC2 보다 7배 이상 빠릅니다!
• 스팟 구매 옵션으로 EC2 GPU 인스턴스를 활용하시면, 70% 저렴 합니다.
• SageMaker를 활용하시면, 모델 생성 부터 훈련, 배포 및 서비스까지 기계 학습
전 과정을 자동화 할 수 있습니다. (다음 세션에서 SageMaker의 더 많은 신기능을 살펴 보세요!)
• Elastic Inference를 활용하면, 추론 비용을 75% 이상 절감 할 수 있습니다.
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
마지막으로… AWS Innovate 에서는
데모 존
실제 사용 환경에서
기계학습의 사용방법을
살펴보세요
AWS 기반 머신러닝
https://aws.amazon.com/
machine-learning/
전문가에게 물어보세요
AWS 전문가가 질문에
답변드립니다
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
클라우드 및 인공 지능 관련 AWS 전문 교육 프로그램
클라우드 역량을 개발할 준비가 되셨다면
https://www.aws.training 을 방문하세요!
온라인 교육
AWS 전문가가 진행하는
무료 온라인 교육 과정
강의식 교육
AWS 공인 강사가 진행하는
오프라인 교육 과정
AWS 자격증
클라우드 전문성 입증을 위한
업계에서 인정 받는
AWS 공인 자격증
© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.
AWS Innovate 에 참석해주셔서 대단히 감사합니다.
저희가 준비한 내용, 어떻게 보셨나요?
더 나은 세미나를 위하여 설문을 꼭 작성해 주시기 바랍니다.
aws-korea-marketing@amazon.com
twitter.com/AWSKorea
facebook.com/amazonwebservices.ko
youtube.com/user/AWSKorea
slideshare.net/awskorea
twitch.tv/aws
AWS Innovate 에 참석해주셔서
대단히 감사합니다.

More Related Content

PDF
AWSではじめるDNSSEC
PDF
데이터 분석가를 위한 신규 분석 서비스 - 김기영, AWS 분석 솔루션즈 아키텍트 / 변규현, 당근마켓 소프트웨어 엔지니어 :: AWS r...
PDF
Amazon EMR과 SageMaker를 이용하여 데이터를 준비하고 머신러닝 모델 개발 하기
PDF
AWS DMS를 통한 오라클 DB 마이그레이션 방법 - AWS Summit Seoul 2017
PDF
20200422 AWS Black Belt Online Seminar Amazon Elastic Container Service (Amaz...
PDF
AWS Personalize 중심으로 살펴본 추천 시스템 원리와 구축
PPTX
20211109 JAWS-UG SRE keynotes
PDF
20190814 AWS Black Belt Online Seminar AWS Serverless Application Model
AWSではじめるDNSSEC
데이터 분석가를 위한 신규 분석 서비스 - 김기영, AWS 분석 솔루션즈 아키텍트 / 변규현, 당근마켓 소프트웨어 엔지니어 :: AWS r...
Amazon EMR과 SageMaker를 이용하여 데이터를 준비하고 머신러닝 모델 개발 하기
AWS DMS를 통한 오라클 DB 마이그레이션 방법 - AWS Summit Seoul 2017
20200422 AWS Black Belt Online Seminar Amazon Elastic Container Service (Amaz...
AWS Personalize 중심으로 살펴본 추천 시스템 원리와 구축
20211109 JAWS-UG SRE keynotes
20190814 AWS Black Belt Online Seminar AWS Serverless Application Model

What's hot (20)

PDF
고객의 플랫폼/서비스를 개선한 국내 사례 살펴보기 – 장준성 AWS 솔루션즈 아키텍트, 강산아 NDREAM 팀장, 송영호 야놀자 매니저, ...
PDF
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
PDF
20200526 AWS Black Belt Online Seminar AWS X-Ray
PDF
AWS Summit Seoul 2023 | Amazon Neptune 및 Elastic을 이용한 추천 서비스 및 검색 플랫폼 구축하기
PPTX
[社内勉強会]ELBとALBと数万スパイク負荷テスト
PDF
202106 AWS Black Belt Online Seminar 小売現場のデータを素早くビジネス に活用するAWSデータ基盤
PDF
AWS 상의 컨테이너 서비스 소개 ECS, EKS - 이종립 / Principle Enterprise Evangelist @베스핀글로벌
PDF
20200219 AWS Black Belt Online Seminar オンプレミスとAWS間の冗長化接続
PDF
Amazon Aurora 성능 향상 및 마이그레이션 모범 사례 - AWS Summit Seoul 2017
PDF
Amazon Personalize 소개 (+ 실습 구성)::김영진, 솔루션즈 아키텍트, AWS::AWS AIML 스페셜 웨비나
PDF
AWS 기반의 마이크로 서비스 아키텍쳐 구현 방안 :: 김필중 :: AWS Summit Seoul 20
PDF
[AWS EXpert Online for JAWS-UG 18] 見せてやるよ、Step Functions の本気ってやつをな
PDF
개발자가 알아야 할 Amazon DynamoDB 활용법 :: 김일호 :: AWS Summit Seoul 2016
PDF
AWS Black Belt Online Seminar 2018 Amazon DynamoDB Advanced Design Pattern
PPTX
老朽化したオンプレ環境をクラウドへ移設
PDF
Amazon Personalize Event Tracker 실시간 고객 반응을 고려한 추천::김태수, 솔루션즈 아키텍트, AWS::AWS ...
PDF
20190122 AWS Black Belt Online Seminar Amazon Redshift Update
PDF
AWS Summit Seoul 2023 | Snowflake: 모든 데이터 워크로드를 위한 하나의 클라우드 데이터 플랫폼
PDF
AWS Black Belt Online Seminar 2017 AWSへのネットワーク接続とAWS上のネットワーク内部設計
PDF
Route53 및 CloudFront를 이용한 CDN 활용기 - AWS Summit Seoul 2017
고객의 플랫폼/서비스를 개선한 국내 사례 살펴보기 – 장준성 AWS 솔루션즈 아키텍트, 강산아 NDREAM 팀장, 송영호 야놀자 매니저, ...
AWS 고객이 주로 겪는 운영 이슈에 대한 해법-AWS Summit Seoul 2017
20200526 AWS Black Belt Online Seminar AWS X-Ray
AWS Summit Seoul 2023 | Amazon Neptune 및 Elastic을 이용한 추천 서비스 및 검색 플랫폼 구축하기
[社内勉強会]ELBとALBと数万スパイク負荷テスト
202106 AWS Black Belt Online Seminar 小売現場のデータを素早くビジネス に活用するAWSデータ基盤
AWS 상의 컨테이너 서비스 소개 ECS, EKS - 이종립 / Principle Enterprise Evangelist @베스핀글로벌
20200219 AWS Black Belt Online Seminar オンプレミスとAWS間の冗長化接続
Amazon Aurora 성능 향상 및 마이그레이션 모범 사례 - AWS Summit Seoul 2017
Amazon Personalize 소개 (+ 실습 구성)::김영진, 솔루션즈 아키텍트, AWS::AWS AIML 스페셜 웨비나
AWS 기반의 마이크로 서비스 아키텍쳐 구현 방안 :: 김필중 :: AWS Summit Seoul 20
[AWS EXpert Online for JAWS-UG 18] 見せてやるよ、Step Functions の本気ってやつをな
개발자가 알아야 할 Amazon DynamoDB 활용법 :: 김일호 :: AWS Summit Seoul 2016
AWS Black Belt Online Seminar 2018 Amazon DynamoDB Advanced Design Pattern
老朽化したオンプレ環境をクラウドへ移設
Amazon Personalize Event Tracker 실시간 고객 반응을 고려한 추천::김태수, 솔루션즈 아키텍트, AWS::AWS ...
20190122 AWS Black Belt Online Seminar Amazon Redshift Update
AWS Summit Seoul 2023 | Snowflake: 모든 데이터 워크로드를 위한 하나의 클라우드 데이터 플랫폼
AWS Black Belt Online Seminar 2017 AWSへのネットワーク接続とAWS上のネットワーク内部設計
Route53 및 CloudFront를 이용한 CDN 활용기 - AWS Summit Seoul 2017
Ad

Similar to AWS의 비용 효율적 고성능기계학습(ML) 플랫폼 뛰어들기 - 윤석찬 수석 테크 에반젤리스트, AWS :: AWS Innovate 2019 (20)

PDF
VUCA 시대의 디지털 네이티브 리더가 알아야할 AWS의 기술 ::: AWS ExecLeaders Korea 2023
PDF
인공지능 / 기계학습 기반의 디지털 트랜스포메이션 및 글로벌 사례 - 김선수 사업개발 담당, AWS / 정진환 팀장, SK텔레콤 / 구태훈...
PDF
아마존은 반도체를 어떻게 설계하는가? -LS 산전 HPC 적용 사례와 함께 - 이현석 사업 개발 담당 이사, AWS / 유성열 책임 연구원...
PDF
[Games on AWS 2019] AWS 사용자를 위한 만랩 달성 트랙 | AWS 최적화 사용을 위해 운영자가 아닌 개발자들이 해야 할 ...
PDF
AWS 기반 클라우드 아키텍처 모범사례 - 삼성전자 개발자 포털/개발자 워크스페이스 - 정영준 솔루션즈 아키텍트, AWS / 유현성 수석,...
PDF
AWS re:Invent 2018를 통해 본 개발자들이 원하는 4가지 클라우드 동향 :: 윤석찬 - AWS Community Day 2019
PDF
[AWS Dev Day] 이머징 테크 | AWS AI 서비스로 SAP 비지니스 프로세스 자동화하기 - 이상규 AWS 솔루션즈 아키텍트, 이...
PDF
SAP on AWS 사례로 알아보는 핵심 업무 이전 : SAP Competency 파트너사의 경험과 비젼 - 이상규 솔루션즈 아키텍트, A...
PDF
[25D2S09]_Amazon Nova팀이 선택한 Amazon SageMaker HyperPod 활용하기.pdf
PDF
[AWS Innovate 온라인 컨퍼런스] 수백만 사용자 대상 기계 학습 서비스를 위한 확장 비법 - 윤석찬, AWS 테크 에반젤리스트
PDF
데이터 과학자를 위한 신규 인공지능 서비스 - 김대근, 이유동, AWS AI/ML 스페셜리스트 솔루션즈 아키텍트 / 소성운, 카카오스타일 ...
PDF
유연하고 빠른 딥러닝 프레임워크 Apache MXNet::김무현::AWS Summit Seoul 2018
PDF
개발자들이 직접 선정한 re:Invent 2019 상위 12 신규 서비스 알아보기 - 윤석찬 (AWS 테크에반젤리스트)
PDF
AWS와 함께하는 슬기로운 재택생활
PDF
클라우드를 활용한 디지털 제조(Digital Manufacturing)실현 방법 및 사례 소개 - 윤석찬 (AWS 테크에반젤리스트) :: ...
PDF
[25D2S08]_Amazon Bedrock과 SageMaker를 이용한 LLM 파인튜닝 및 커스터마ᄋ...
PDF
[25D2S07]_Amazon Nova를 이용해 향샹된 RAG 활용하기.pdf
PDF
[OpenLAB] AWS reInvent를 통해 바라본 글로벌 Cloud 기술동향.pdf
PDF
AWS CLOUD 2018- AWS의 새로운 통합 머신러닝 플랫폼 서비스, Amazon SageMaker (김무현 솔루션즈 아키텍트)
PDF
AWS Builders Online Series | AWS와 함께하는 클라우드 컴퓨팅 - 강철, AWS 어카운트 매니저
VUCA 시대의 디지털 네이티브 리더가 알아야할 AWS의 기술 ::: AWS ExecLeaders Korea 2023
인공지능 / 기계학습 기반의 디지털 트랜스포메이션 및 글로벌 사례 - 김선수 사업개발 담당, AWS / 정진환 팀장, SK텔레콤 / 구태훈...
아마존은 반도체를 어떻게 설계하는가? -LS 산전 HPC 적용 사례와 함께 - 이현석 사업 개발 담당 이사, AWS / 유성열 책임 연구원...
[Games on AWS 2019] AWS 사용자를 위한 만랩 달성 트랙 | AWS 최적화 사용을 위해 운영자가 아닌 개발자들이 해야 할 ...
AWS 기반 클라우드 아키텍처 모범사례 - 삼성전자 개발자 포털/개발자 워크스페이스 - 정영준 솔루션즈 아키텍트, AWS / 유현성 수석,...
AWS re:Invent 2018를 통해 본 개발자들이 원하는 4가지 클라우드 동향 :: 윤석찬 - AWS Community Day 2019
[AWS Dev Day] 이머징 테크 | AWS AI 서비스로 SAP 비지니스 프로세스 자동화하기 - 이상규 AWS 솔루션즈 아키텍트, 이...
SAP on AWS 사례로 알아보는 핵심 업무 이전 : SAP Competency 파트너사의 경험과 비젼 - 이상규 솔루션즈 아키텍트, A...
[25D2S09]_Amazon Nova팀이 선택한 Amazon SageMaker HyperPod 활용하기.pdf
[AWS Innovate 온라인 컨퍼런스] 수백만 사용자 대상 기계 학습 서비스를 위한 확장 비법 - 윤석찬, AWS 테크 에반젤리스트
데이터 과학자를 위한 신규 인공지능 서비스 - 김대근, 이유동, AWS AI/ML 스페셜리스트 솔루션즈 아키텍트 / 소성운, 카카오스타일 ...
유연하고 빠른 딥러닝 프레임워크 Apache MXNet::김무현::AWS Summit Seoul 2018
개발자들이 직접 선정한 re:Invent 2019 상위 12 신규 서비스 알아보기 - 윤석찬 (AWS 테크에반젤리스트)
AWS와 함께하는 슬기로운 재택생활
클라우드를 활용한 디지털 제조(Digital Manufacturing)실현 방법 및 사례 소개 - 윤석찬 (AWS 테크에반젤리스트) :: ...
[25D2S08]_Amazon Bedrock과 SageMaker를 이용한 LLM 파인튜닝 및 커스터마ᄋ...
[25D2S07]_Amazon Nova를 이용해 향샹된 RAG 활용하기.pdf
[OpenLAB] AWS reInvent를 통해 바라본 글로벌 Cloud 기술동향.pdf
AWS CLOUD 2018- AWS의 새로운 통합 머신러닝 플랫폼 서비스, Amazon SageMaker (김무현 솔루션즈 아키텍트)
AWS Builders Online Series | AWS와 함께하는 클라우드 컴퓨팅 - 강철, AWS 어카운트 매니저
Ad

More from Amazon Web Services Korea (20)

PDF
[D3T1S01] Gen AI를 위한 Amazon Aurora 활용 사례 방법
PDF
[D3T1S06] Neptune Analytics with Vector Similarity Search
PDF
[D3T1S03] Amazon DynamoDB design puzzlers
PDF
[D3T1S04] Aurora PostgreSQL performance monitoring and troubleshooting by use...
PDF
[D3T1S07] AWS S3 - 클라우드 환경에서 데이터베이스 보호하기
PDF
[D3T1S05] Aurora 혼합 구성 아키텍처를 사용하여 예상치 못한 트래픽 급증 대응하기
PDF
[D3T1S02] Aurora Limitless Database Introduction
PDF
[D3T2S01] Amazon Aurora MySQL 메이저 버전 업그레이드 및 Amazon B/G Deployments 실습
PDF
[D3T2S03] Data&AI Roadshow 2024 - Amazon DocumentDB 실습
PDF
AWS Modern Infra with Storage Roadshow 2023 - Day 2
PDF
AWS Modern Infra with Storage Roadshow 2023 - Day 1
PDF
사례로 알아보는 Database Migration Service : 데이터베이스 및 데이터 이관, 통합, 분리, 분석의 도구 - 발표자: ...
PDF
Amazon DocumentDB - Architecture 및 Best Practice (Level 200) - 발표자: 장동훈, Sr. ...
PDF
Amazon Elasticache - Fully managed, Redis & Memcached Compatible Service (Lev...
PDF
Internal Architecture of Amazon Aurora (Level 400) - 발표자: 정달영, APAC RDS Speci...
PDF
[Keynote] 슬기로운 AWS 데이터베이스 선택하기 - 발표자: 강민석, Korea Database SA Manager, WWSO, A...
PDF
Demystify Streaming on AWS - 발표자: 이종혁, Sr Analytics Specialist, WWSO, AWS :::...
PDF
Amazon EMR - Enhancements on Cost/Performance, Serverless - 발표자: 김기영, Sr Anal...
PDF
Amazon OpenSearch - Use Cases, Security/Observability, Serverless and Enhance...
PDF
Enabling Agility with Data Governance - 발표자: 김성연, Analytics Specialist, WWSO,...
[D3T1S01] Gen AI를 위한 Amazon Aurora 활용 사례 방법
[D3T1S06] Neptune Analytics with Vector Similarity Search
[D3T1S03] Amazon DynamoDB design puzzlers
[D3T1S04] Aurora PostgreSQL performance monitoring and troubleshooting by use...
[D3T1S07] AWS S3 - 클라우드 환경에서 데이터베이스 보호하기
[D3T1S05] Aurora 혼합 구성 아키텍처를 사용하여 예상치 못한 트래픽 급증 대응하기
[D3T1S02] Aurora Limitless Database Introduction
[D3T2S01] Amazon Aurora MySQL 메이저 버전 업그레이드 및 Amazon B/G Deployments 실습
[D3T2S03] Data&AI Roadshow 2024 - Amazon DocumentDB 실습
AWS Modern Infra with Storage Roadshow 2023 - Day 2
AWS Modern Infra with Storage Roadshow 2023 - Day 1
사례로 알아보는 Database Migration Service : 데이터베이스 및 데이터 이관, 통합, 분리, 분석의 도구 - 발표자: ...
Amazon DocumentDB - Architecture 및 Best Practice (Level 200) - 발표자: 장동훈, Sr. ...
Amazon Elasticache - Fully managed, Redis & Memcached Compatible Service (Lev...
Internal Architecture of Amazon Aurora (Level 400) - 발표자: 정달영, APAC RDS Speci...
[Keynote] 슬기로운 AWS 데이터베이스 선택하기 - 발표자: 강민석, Korea Database SA Manager, WWSO, A...
Demystify Streaming on AWS - 발표자: 이종혁, Sr Analytics Specialist, WWSO, AWS :::...
Amazon EMR - Enhancements on Cost/Performance, Serverless - 발표자: 김기영, Sr Anal...
Amazon OpenSearch - Use Cases, Security/Observability, Serverless and Enhance...
Enabling Agility with Data Governance - 발표자: 김성연, Analytics Specialist, WWSO,...

AWS의 비용 효율적 고성능기계학습(ML) 플랫폼 뛰어들기 - 윤석찬 수석 테크 에반젤리스트, AWS :: AWS Innovate 2019

  • 1. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AWS 기반 비용 효율적 고성능 기계학습(ML) 플랫폼 뛰어들기 윤석찬 / AWS 테크니컬 에반젤리스트
  • 2. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 본 세션에서 다루는 점  클라우드 기반 기계 학습 및 딥러닝 모델 훈련 방법을 알고 싶으세요?  시간과 비용을 적게 들이고 빠르게 좋은 모델을 만들고 싶으세요?  모델 훈련 및 서비스까지 자동화 하는 방법에 대한 고민이 많으세요?  추론 작업을 좀 더 빠르게 하는 방법을 알고 싶으세요?
  • 3. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. FRAM EW O RKS ML 프레임워크 + 인프라 ML 서비스 AI 서비스 I NTERFACES I NFRASTRUCTURE Am azon SageM ak er Amazon Lex C H A T B OT S Amazon Rekognition Image Amazon Rekognition Video V IS ION Amazon Transcribe Amazon Polly S P E E C H Amazon Comprehend Amazon Translate L A N GU A GE S P3 P3dn C5 C5n Elastic inference Inferentia AWS Greengrass N E WN E W Ground Truth Notebooks Algorithms + Marketplace RL Training Optimization Deployment Hosting N E W N E W N E W N E W Amazon Personalize Amazon Forecast V E R T IC A L N E W N E W Amazon Textract N E W 모든 개발자를 위한 인공 지능 도구 제공
  • 4. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AWS Deep Learning AMIs 다양한 딥러닝 프레임워크를 미리 설치하고 최적 설정을 완료한 머신 이미지(Machine Image) 제공 https://aws.amazon.com/machine-learning/amis/ Conda AMI 별도 가상 환경에 사전 설치된 딥 러닝 프레임워크 및 PIP 패키지 제공 (우분투, 아마존리눅스, 윈도용) Base AMI 개별 딥러닝 엔진 리포지토리 또는 맞춤형 빌드를 설치 가능 (우분투, 아마존리눅스용) AMI with source code 공유 Python 개발 환경에서 DL 엔진 및 소스 코드를 함께 제공
  • 5. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 심지어 Deep Learning AMI는 진짜 빠릅니다! https://aws.amazon.com/ko/blogs/machine-learning/faster-training-with-optimized- tensorflow-1-6-on-amazon-ec2-c5-and-p3-instances/ 차세대 C5 인스턴스에서 Intel AVX 및 MKL-dnn에 최적화된 TensorFlow 1.6 포함 ImageNet 데이터세트로 일반 바이너리 버전 대비 7.4배 빠른 모델 훈련 속도 제공
  • 6. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AVX 512 72 vCPUs “Skylake” 144 GiB memory C5 12 Gbps to EBS 2X vCPUs 2X performance 3X throughput 2.4X memory C4 36 vCPUs “Haswell” 4 Gbps to EBS 60 GiB memory Intel® AVX-512 고급 명령어 세트를 지원하므로 AI/기계 학습 또는 동영상 처리와 같은 단일 및 이중 부동 소수점 정밀도 기반 벡터 처리 작업을 효율적으로 수행 여기서 잠깐! C5 인스턴스 이란? 차세대 클라우드 가상화 환경인 Nitro를 기반한 컴퓨팅 전용 타입
  • 7. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. EC2 P3 인스턴스 - 클라우드 기반 고성능 GPU 지원 P3 인스턴스 세부 정보 • NVIDIA Tesla V100 GPU 기반 • 40,960 CUDA cores 및 5120 Tensor Codes • 128GB의 GPU 메모리 • 최대 8개의 GPU를 지원하는 다양한 인스턴스 타입 (p3.2xlarge, 8xlarge 및 16xlarge) 제공 1 PetaFLOPs의 컴퓨팅 성능 제공 300 GB/s GPU-to-GPU(NVLink) 네트워크 속도 만약… 인터넷에서 구매하시면?
  • 8. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. EC2 P3 인스턴스로 GPU 클러스터를 만들어 본다면? p3.2xlarge = $5 per hour (서울 리전 기준) x 20 CPU 2,000 개 연산 능력 p3.2xlarge x 20 = $100 per hour 초당 1페타플롭스 (CPU 100개에 해당 하는 연산 능력)
  • 9. 남는 여유 자원을 70% 할인된 가격에 모델 훈련 시에만 사용한다면 = $30 per hour
  • 10. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 손으로 하실 필요 없어요~ 인프라를 코드로 짜면 됩니다! $aws ec2-run-instances ami-b232d0db --instance-count 1 --instance-type p2.8xlarge --region us-east-1 --user-data my_data_training.sh $aws ec2-stop-instances i-10a64379 API와 데브옵스를 통해 손쉽게 딥러닝 클러스터 구성 가능 다양한 CI/CD 기반 데브옵스 환경으로 빠른 학습 가능
  • 11. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 여러분… 인생은 짧습니다! 시간을 아끼세요~ http://www.fast.ai/2018/08/10/fastai-diu-imagenet/ https://aws.amazon.com/blogs/machine-learning/new-speed-record-set-for-training-deep-learning-models-on-aws/ • 16개의 P3.16xlarge 인스턴스를 사용해서 18분만에 ResNet-50 모델 학습 완료 (정확도 93%) • 저렴한 스팟 인스턴스 구매 옵션을 활용하여 $40 비용에 처리 가능 • PyTorch 기반으로 기존 DAWNBench 기록 보다 40% 빠른 속도
  • 12. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 1 4.75 8.5 12.25 16 1 4.75 8.5 12.25 16 Speedup(x) # GPUs Resnet 152 Inceptin V3 Alexnet Ideal 여기서 잠깐… 시간을 더 아끼시려면? P2.16xlarge (8 Nvidia Tesla K80 - 16 GPUs) Synchronous SGD (Stochastic Gradient Descent) 91% Efficiency 88% Efficiency 16x P2.16xlarge by AWS CloudFormation Mounted on Amazon EFS Apache MXNet은 GPU 갯수가 증가하더라도 이상적인 수준의 성능을 보여주는 오픈 소소 딥러닝 프레임워크로서 멀티 GPU 환경에서 탁월한 성능 제공
  • 13. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. MXNET 공부하세요… 아직은 블루오션입니다!
  • 14. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Demo - 딥러닝 AMI와 스팟 인스턴스 구동하기
  • 15. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 데이터 수집 및 저장 및 전처리 괜찮아 보이는 기계학습 알고리즘 선택 모델 훈련을 위한 서버 인프라 설정 모델 훈련 및 튜닝 (계속 반복) 최적화한 모델 배포 API 서비스 확장 및 운영 기계학습은 일반 개발자에게 여전히 복잡하고 어렵다?! 지겨운 데이터 전처리… 모델 튜닝… 될때까지 계속 반복&반복
  • 16. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 그래서 준비했습니다… Amazon SageMaker 모델 생성 Jupyter Notebook 기반 서비스 고성능 알고리즘 미리 제공 원클릭 데이터 훈련 모델 훈련 Hyper- parameter 최적화 완전 관리 및 자동 스케일링 모델 배포 원클릭 모델 배포 모델 개발 및 생성, 훈련 및 서비스 배포를 위한 완전 관리 서비스 https://aws.amazon.com/ko/sagemaker
  • 17. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. SageMaker를 통한 ML 서비스 아키텍처 SageMaker Notebooks Training Algorithm SageMaker Training Amazon ECR Code Commit Code Pipeline SageMaker Hosting AWS Lambda API Gateway Build Train Deploy static website hosted on S3 Inference requests Amazon S3 Amazon Cloudfront Web assets on Cloudfront
  • 18. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. SageMaker 기반 ML 모델 생성 및 훈련 K-Means Clustering Principal Component Analysis Neural Topic Modelling Factorization Machines Linear Learner - Regression XGBoost Latent Dirichlet Allocation Image Classification Seq2Seq Linear Learner - Classification BUILT ALGORITHMS Caffe2, CNTK, PyTorch, Torch IM Estimators in Spark DEEP LEARNING FRAMEWORKS Bring Your Own Script (IM builds the Container) BRING YOUR OWN MODEL ML Training code Fetch Training data Save Model Artifacts Amazon ECR Save Inference Image Amazon S3 AWS MARKETPLACE MACHINE LEARNING
  • 19. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. SageMaker - 자동 하이퍼 파라미터 최적화(HPO) 기능 https://medium.com/datadriveninvestor/auto-model-tuning-for-keras-on-amazon-sagemaker-plant-seedling-dataset-7b591334501e https://aws.amazon.com/blogs/machine-learning/amazon-sagemaker-automatic-model-tuning-produces-better-models-faster/ CPU (ml.m5.xlarge) 작업 시 Speed = 4 mins/epoch Total Runtime = ~20 hours Cost = .269 * 20 = $5.38 GPU (ml.p2.xlarge) 작업 시 Speed = 4.8 seconds/epoch Total Runtime = ~3 hours Cost = 1.26 * 3 = $3.78 Keras 기반 Plant Seedling Dataset을 위한 CNN 학습 모델 (최대 150 Epoch 학습)
  • 20. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. $$$$ $$$ $$ $ Minutes Hours Days Weeks Months Single Machine Distributed, with Strong Machines ML 모델 훈련에 대한 비용과 시간 대비 효과
  • 21. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. $$$$ $$$ $$ $ Minutes Hours Days Weeks Months EC2 + AMI Amazon SageMaker On-premise ML 모델 훈련에 대한 비용과 시간 대비 효과
  • 22. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Demo – SageMaker 기반 모델 훈련하기
  • 23. 사례. SageMaker 기반 기계 학습 구현 사례 “광고 기술 서비스 스타트업인 IGAWorks는 AWS 기반으로 일 50억 건의 디스플레이 광고 요청를 처리하는 트레이딩웍스와 22,000여개 모바일 앱이 탑재된 애드브릭스 등을 운영하고 있습니다. 광고 효율 개선 및 지속적인 최적화를 위한 기계 학습 모델 관리의 편의성과 프로덕션 적용 시간을 단축하는 Amazon SageMaker를 도입해 A.I Lab의 업무 효율성이 높아졌습니다. 기업 규모와 상관 없이 다양한 고객 활용 중!
  • 24. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 추론 작업이 전체 기계 학습 비용의 대부분을 차지함 Inference Training Infrastructure costs 추론 Inference 작업은? Machine Learning 모델 학습은 쉽고, 빠르며, 비용 효과적으로 가능하지만…
  • 25. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 추론 비효율의 두 가지 주요 요인 : 복잡성 및 비용 다양한 추론 케이스가 존재 탄력적인 추론이 가능해야 함
  • 26. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 추론 작업을 더 효율적으로 하는 방법 더 작은 P2 인스턴스를 더 작은 배치 크기로 실행하는 것이 더 효과적입니다.
  • 27. N E W ! EC2 Instance EC2 Instance EC2 Instance GPU 훨씬 저렴한 비용으로 신속한 추론을 위해 Amazon EC2 인스턴스에 GPU 가속 기능 추가 (최대 75 % 절감) Amazon Elastic Inference P 3 . 8 X L P 3 P 3 P 3 P 3 Amazon Elastic Inference 36 TOPS GPU M5.large Amazon Elastic Inference Before After
  • 28. N E W ! 고성능 처리량 낮은 대기시간 수백 TOPS 지원 다양한 데이터 타입 다양한 ML 프레임워크 INT8, FP16, mixed precision TensorFlow, MXNet, PyTorch, Caffe2, ONNX EC2 인스턴스 지원 Amazon SageMaker 지원 Amazon Elastic Inference 지원 고성능 기계 학습 추론을 위한 AWS에서 설계 한 맞춤형 칩셋 AWS Inferentia
  • 29. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Starting at 1 TFLOPS 다양한 인스턴스 타입 활용 가능 간단한 음성 인식 및 자연어 처리 모델 Up to 32 TFLOPS 추천 엔진 또는 사기 탐지 모델 VPC 내부의 추론 탄력성 보장 360,000ResNet-50 컴퓨터 비전 사례 딥러능 모델 추론에 필요한 시간당 이미지 숫자 $0.22 시간당 비용 75% 기존 대비 비용 절감 L O W E S T C O S T A V A I L A B L E Amazon Elastic Inference - 확장성 및 비용
  • 30. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 원하는 용량에 따라 가속기 타입 추가 가능 Accelerator Type FP32 Throughput (TOPS) FP16 Throughput (TOPS) Accelerator Memory (GB) Price ($/hr) (US) eia1.medium 1 8 1 $0.13 eia1.large 2 16 2 $0.26 eia1.xlarge 4 32 4 $0.52
  • 31. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 기존 GPU와 Elastic Inference와 비용 차이 0 20 40 60 80 100 120 0 10 20 30 40 50 60 70 0 20 40 60 80 100 120 140
  • 32. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. EC2에 활용하는 방법 VPC Region Availability Zone
  • 33. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. EC2 Auto Scaling groups에 적용하기 Auto Scaling group
  • 34. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. SageMaker에 적용하기 SageMaker Notebooks SageMaker Hosted Endpoints
  • 35. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Elastic Inference 설정 및 사용 방법 $ aws ec2 run-instances --image-id <preconfigured_ami_id> --instance-type <ec2_instance_type> --key-name <key_name> --subnet-id <subnet_id> --security-group-ids <security_group_id --iam-instance-profile Name=”iam_profile_name” --elastic-inference-accelerator Type=eia1.<size> • 일반 EC2 인스턴스 선택 후, 미리 설정된 AMI에서 원하는 EI 가속기 선택 • EI 가속기가 접속할 수 있는 VPC 엔드포인트 권한 설정 필수
  • 36. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. © 2018, Amazon Web Services, Inc. or its affiliates. All rights reserved. Elastic Inference 설정 및 사용 방법 classifier = tf.estimator.Estimator(…) input_tensor = tf.placeholder(dtype=tf.float32, shape=[1, 80, 128, 128, 1], name='images_tensor’) input_map = {'images’ : input_tensor} classifier.export_savedmodel(model_dir, tf.estimator.export.build_raw_serving_input_receiver_fn(input_map)) • MVCNN 모델 등 TF Estimators 포맷에 추가 • Dimensions: [batch_size , num_views , width , height , color_channels] AmazonEI_TensorFlow_Serving_v1.11_v1 --model_name=mvcnn --model_base_path=model_dir --port=9000 • Tensorflow Serving API를 이용하여 모델 예측 사용
  • 37. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 맺으면서 • AWS Deep Learning AMI를 사용하시면, 기존 EC2 보다 7배 이상 빠릅니다! • 스팟 구매 옵션으로 EC2 GPU 인스턴스를 활용하시면, 70% 저렴 합니다. • SageMaker를 활용하시면, 모델 생성 부터 훈련, 배포 및 서비스까지 기계 학습 전 과정을 자동화 할 수 있습니다. (다음 세션에서 SageMaker의 더 많은 신기능을 살펴 보세요!) • Elastic Inference를 활용하면, 추론 비용을 75% 이상 절감 할 수 있습니다.
  • 38. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 마지막으로… AWS Innovate 에서는 데모 존 실제 사용 환경에서 기계학습의 사용방법을 살펴보세요 AWS 기반 머신러닝 https://aws.amazon.com/ machine-learning/ 전문가에게 물어보세요 AWS 전문가가 질문에 답변드립니다
  • 39. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved.© 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. 클라우드 및 인공 지능 관련 AWS 전문 교육 프로그램 클라우드 역량을 개발할 준비가 되셨다면 https://www.aws.training 을 방문하세요! 온라인 교육 AWS 전문가가 진행하는 무료 온라인 교육 과정 강의식 교육 AWS 공인 강사가 진행하는 오프라인 교육 과정 AWS 자격증 클라우드 전문성 입증을 위한 업계에서 인정 받는 AWS 공인 자격증
  • 40. © 2019, Amazon Web Services, Inc. or its Affiliates. All rights reserved. AWS Innovate 에 참석해주셔서 대단히 감사합니다. 저희가 준비한 내용, 어떻게 보셨나요? 더 나은 세미나를 위하여 설문을 꼭 작성해 주시기 바랍니다. aws-korea-marketing@amazon.com twitter.com/AWSKorea facebook.com/amazonwebservices.ko youtube.com/user/AWSKorea slideshare.net/awskorea twitch.tv/aws AWS Innovate 에 참석해주셔서 대단히 감사합니다.