Successfully reported this slideshow.
We use your LinkedIn profile and activity data to personalize ads and to show you more relevant ads. You can change your ad preferences anytime.

Keith Steward - SageMaker Algorithms Infinitely Scalable Machine Learning_VK.pdf

253 views

Published on

Amazon SageMaker is a fully-managed service that enables developers and data scientists to quickly and easily build, train, and deploy machine learning (ML) models, at any scale. Amazon SageMaker provides high-performance, machine learning algorithms optimized for speed, scale, and accuracy, to perform training on petabyte-scale data sets. This webinar will introduce you to the collection of distributed streaming ML algorithms that come with Amazon SageMaker. You will learn about the difference between streaming and batch ML algorithms, and how SageMaker has been architected to run these algorithms at scale. We will demo Neural Topic Modeling of text documents using a sample SageMaker Notebook, which will be made available to attendees.

  • Keith - I was at your presentation at the AWS Summit in NYC yesterday. Thanks for a very insightful session. You had a slide called "The Machine Learning Process Is Complex" that had a workflow diagram starting with "Business Problem". Can you share that slide? Thanks in advance!
       Reply 
    Are you sure you want to  Yes  No
    Your message goes here
  • Be the first to like this

Keith Steward - SageMaker Algorithms Infinitely Scalable Machine Learning_VK.pdf

  1. 1. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Amazon SageMaker Algorithms: Infinitely Scalable Machine Learning Keith Steward Sr. Specialist SA
  2. 2. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved What is Amazon SageMaker? Exploration Training Hosting
  3. 3. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved The Amazon Machine Learning Stack FRAMEWORKS & INTERFACES Caffe2 CNTK Apache MXNet PyTorch TensorFlo w Chainer Keras Gluon AWS Deep Learning AMIs Amazon SageMaker Rekognition Transcribe Translate Polly Comprehend Lex AWS DeepLens EDUCATION PLATFORM SERVICES APPLICATION SERVICES Amazon Mechanical Turk
  4. 4. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Challenges in Machine Learning
  5. 5. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Machine Learning
  6. 6. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Large Scale Machine Learning
  7. 7. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Large Scale Machine Learning
  8. 8. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Our Customers use ML at a massive scale “We collect 160M events daily in the ML pipeline and run training over the last 15 days and need it to complete in one hour. Effectively there's 100M features in the model” Valentino Volonghi, CTO “We process 3 million ad requests a second, 100,000 features per request. That’s 250 trillion per day. Not your run of the mill Data science problem!” Bill Simmons, CTO “Our data warehouse is 100TB and we are processing 2TB daily. We're running mostly gradient boosting (trees), LDA and K-Means clustering and collaborative filtering.“ Shahar Cizer Kobrinsky, VP Architecture
  9. 9. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Cost vs. Time $$$$ $$$ $$ $ Minutes Hours Days Weeks Months
  10. 10. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Cost vs. Time $$$$ $$$ $$ $ Minutes Hours Days Weeks Months Single Machine
  11. 11. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Cost vs. Time $$$$ $$$ $$ $ Minutes Hours Days Weeks Months Single Machine Distributed, with Strong Machines
  12. 12. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved© 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved. Cost vs. Time $$$$ $$$ $$ $ Minutes Hours Days Weeks Months Single Machine Distributed, with Strong Machines
  13. 13. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Model Selection 1 1
  14. 14. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Incremental Training 2 3 1 2
  15. 15. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Production Readiness Data/Model Size Investment
  16. 16. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Production Readiness Data/Model Size Investment Reasonable Investment Level
  17. 17. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Production Readiness Data/Model Size Investment Reasonable Investment Level Unusable Data / Wasted opportunity
  18. 18. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Architecture and Design Streaming, GPU/CPU, Distributed with a Shared State
  19. 19. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Streaming State
  20. 20. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Streaming Data Size Memory Data Size Time/Cost
  21. 21. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Incremental Training 2 3 1 2
  22. 22. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Incremental Training 3 1 2
  23. 23. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved GPU/CPU GPU State
  24. 24. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Distributed GPU State GPU State GPU State
  25. 25. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Shared State GPU GPU GPU Local State Shared State Local State Local State
  26. 26. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Cost vs. Time vs. Accuracy $$$$ $$$ $$ $ Minutes Hours Days Weeks Months
  27. 27. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved State Model GPU State
  28. 28. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Model Selection 1 1
  29. 29. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Model Selection 1
  30. 30. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Abstraction and Containerization def initialize(...) def update(...) def finalize(...)
  31. 31. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Production Readiness Data/Model Size Investment Reasonable Investment Level No unusable Data / No wasted opportunity
  32. 32. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Amazon SageMaker Algorithms • DeepAR • Factorization Machines • Gradient Boosted Trees (XGBoost) • Image Classification (ResNet) • K-Means Clustering • Latent Dirichlet Allocation (LDA) • Linear Learner Classification and Regression • Neural Topic Modeling (NTM) • Principal Components Analysis (PCA) • Random Cut Forest • Seq2Seq
  33. 33. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Linear Learner Regression: Estimate a real valued function Binary Classification: Predict a 0/1 class
  34. 34. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Linear Learner Train Fit thresholds and select Select model with best validation performance >8x speedup over naïve parallel training!
  35. 35. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved 30GB datasets for web-spam and web-url classification
  36. 36. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved
  37. 37. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved K-Means Clustering
  38. 38. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved
  39. 39. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved
  40. 40. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Principal Component Analysis (PCA)
  41. 41. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Principal Component Analysis (PCA)
  42. 42. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Neural Topic Modeling Encoder: feedforward net Input term counts vector Document Posterior Sampled Document Representation Decoder: Softmax Output term counts vector Perplexity vs. Number of Topic
  43. 43. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved DeepAR –time series forecasting Mean absolute percentage error P90 Loss DeepAR R DeepAR R traffic Hourly occupancy rate of 963 bay area freeways 0.14 0.27 0.13 0.24 electricity Electricity use of 370 homes over time 0.07 0.11 0.08 0.09 pageviews Page view hits of websites 10k 0.32 0.32 0.44 0.31 180k 0.32 0.34 0.29 NA One hour on p2.xlarge, $1 Input Network
  44. 44. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Using AmazonSageMaker Algorithms Command Line SageMaker Notebooks Amazon EMR
  45. 45. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Input Data >> aws --profile <profile> --region us-west-2 sm create-training-job --training-job-name kmeans-demo --algorithm-specification TrainingImage=0123456789.dkr.ecr.us-east- 1.amazonaws.com/kmeanswebscale:latest,TrainingInputMode=File --role-arn "arn:aws:iam::0123456789:role/demo" --input-data-config '{"ChannelName": "train", "DataSource": {"S3DataSource":{"S3DataType": "S3Prefix", "S3Uri": "s3://kmeans_demo/train", "S3DataDistributionType": "FullyReplicated"}}, "CompressionType": "None", "RecordWrapperType": "None"}' --output-data-config S3OutputPath=s3://kmeans_demo/output --resource-config InstanceCount=2,InstanceType=c4.8xlarge,VolumeSizeInGB=50 --stopping-condition MaxRuntimeInHours=1 From Command Line Hardware
  46. 46. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved From Amazon SageMaker Notebooks Parameters Hardware Start Training Host model
  47. 47. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved From Amazon EMR Start Training Parameters Hardware Apply Model
  48. 48. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved Questions?
  49. 49. © 2017, Amazon Web Services, Inc. or its Affiliates. All rights reserved aws.amazon.com/activate Everything and Anything Startups Need to Get Started on AWS

×