SlideShare una empresa de Scribd logo
1 de 36
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 2
Vish Abrams
Architect, Cloud Develompent, Oracle
October 9, 2018
Blazingly Fast Machine Learning Inference
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Program Agenda
Machine Learning Model Serving
What is GraphPipe?
Advantages
Protocol Deep Dive
Real World Demo
More Info
1
2
3
4
Confidential – Oracle Internal/Restricted/Highly Restricted 3
5
6
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Program Agenda
Machine Learning Inference
What is GraphPipe?
Performance
Protocol Deep Dive
Real World Demo
More Info
1
2
3
4
Confidential – Oracle Internal/Restricted/Highly Restricted 4
5
6
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Machine Learning Inference (Model Serving)
• Building machine learning models has become much easier due to open
source frameworks like TensorFlow and Pytorch
• Serving machine learning models means putting your trained model onto a
server so that it can be accessed by client applications
• This involves two components: the ML client and the ML server.
• The client talks to the server using some kind of communication protocol:
often JSON over HTTP.
Confidential – Oracle Internal/Restricted/Highly Restricted 5
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
ML Client
Confidential – Oracle Internal/Restricted/Highly Restricted 6
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
ML Server
Confidential – Oracle Internal/Restricted/Highly Restricted 7
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Program Agenda
Machine Learning Model Serving
What is GraphPipe?
Advantages
Protocol Deep Dive
Real World Demo
More Info
1
2
3
4
Confidential – Oracle Internal/Restricted/Highly Restricted 8
5
6
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
What is GraphPipe?
GraphPipe is an open source protocol and collection of software designed
to simplify machine learning model deployment and decouple it from
framework-specific model implementations.
Confidential – Oracle Internal/Restricted/Highly Restricted 9
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
What is GraphPipe?
In other words, it turns this:
Confidential – Oracle Internal/Restricted/Highly Restricted 10
mxnet servertensorflow serving custom server
standard jsoncustom protocolprotocol buffers
custom clientautogenerated client custom client
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
What is GraphPipe?
Confidential – Oracle Internal/Restricted/Highly Restricted 11
Into this:
graphpipe-onnxgraphpipe-tf
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
GraphPipe Features
• A minimalist machine learning transport specification based on flatbuffers
• Simple reference model servers for Tensorflow, Caffe2, and ONNX.
• Efficient client implementations in Go, Python, and Java.
Confidential – Oracle Internal/Restricted/Highly Restricted 12
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Why Did we Make It?
• Production deployments of AI agents are around the corner
• Model Serving is an important part of production solutions
• Existing solutions suffer from various problems:
– Inconsistent
– Inefficient
– Custom Clients
• A standard along with simple implementations moves the industry forward
Confidential – Oracle Internal/Restricted/Highly Restricted 13
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Program Agenda
Machine Learning Model Serving
What is GraphPipe?
Advantages
Protocol Deep Dive
Real World Demo
More Info
1
2
3
4
Confidential – Oracle Internal/Restricted/Highly Restricted 14
5
6
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Ease of Development
• Model Servers are written in Go – a very accessible language
• Flatbuffer code generation makes it easy to produce new clients
• Open spec makes it possible to integrate with existing servers
Confidential – Oracle Internal/Restricted/Highly Restricted 15
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Protocol Performance
Confidential – Oracle Internal/Restricted/Highly Restricted 16
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Serving Performance
Confidential – Oracle Internal/Restricted/Highly Restricted 17
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Program Agenda
Machine Learning Model Serving
What is GraphPipe?
Advantages
Protocol Deep Dive
Real World Demo
More Info
1
2
3
4
Confidential – Oracle Internal/Restricted/Highly Restricted 18
5
6
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Flatbuffers
• Extensible protocol
• Small code footprint
• Near-zero deserialization overhead
Confidential – Oracle Internal/Restricted/Highly Restricted 19
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Protocol Summary
Confidential – Oracle Internal/Restricted/Highly Restricted 20
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Program Agenda
Machine Learning Model Serving
What is GraphPipe?
Advantages
Protocol Deep Dive
Real World Demo
More Info
1
2
3
4
Confidential – Oracle Internal/Restricted/Highly Restricted 21
5
6
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
AlphaZero
• Algorithm for training a machine to play any game*
• Any game that can be represented with a Markov Process
• Trained without human information through self play
• Needs a structured representation of the game state
• Needs rules for transitioning from one state to the next
Confidential – Oracle Internal/Restricted/Highly Restricted 22
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
AlphaZero Timeline
AlphaGo
Beats Fan Hui
Oct-16
Paper
published in
Nature Jan-
16
AlphaGo
Beats Lee
Sedol Mar-16
AlphaGo
Beats Ke Jie
May-17
AlphaGoZero
published
Oct-17
AlphaZero
published
Dec-17
Confidential – Oracle Internal/Restricted/Highly Restricted 23
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
The Game Playing Black Box
Confidential – Oracle Internal/Restricted/Highly Restricted 24
Neural
NetworkPosition Move
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Training the Network
Confidential – Oracle Internal/Restricted/Highly Restricted 25
TrainingLabeled
Data
Neural
Network
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Generating Data
Confidential – Oracle Internal/Restricted/Highly Restricted 26
Self-Play
(MCTS)
Neural
Network
Labeled
Data
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
AlphaZero In a nutshell
Confidential – Oracle Internal/Restricted/Highly Restricted 27
Self-PlayTraining
Neural Network
Labeled Data
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
AlphaZero for Connnect Four
• We trained a network to play Connect Four using 150 cycles of this process
(and playing about 1,000,000 games during self-play)
• The network finds the correct move in about 99% of positions
• We used GraphPipe as part of the training process because we were
generating games across a cluster of 5 machines with GPUs
• But GraphPipe is even more useful for deploying this model so that people
can use it
• How do we deploy our model for use in an application? GraphPIpe!
Confidential – Oracle Internal/Restricted/Highly Restricted 28
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Serving the AlphaZero Trained Network
Confidential – Oracle Internal/Restricted/Highly Restricted 29
Neural
Network
GraphPipe
Position
Move
GraphPipe
Web
Frontend
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Live Demo!
Confidential – Oracle Internal/Restricted/Highly Restricted 30
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Actual Architecture
Confidential – Oracle Internal/Restricted/Highly Restricted 31
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Program Agenda
Machine Learning Model Serving
What is GraphPipe?
Advantages
Protocol Deep Dive
Real World Demo
More Info
1
2
3
4
Confidential – Oracle Internal/Restricted/Highly Restricted 32
5
6
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
GraphPipe
• https://oracle.github.io/graphpipe/
• https://github.com/oracle/graphpipe
• https://github.com/oracle/graphpipe-go
• https://github.com/oracle/graphpipe-py
• https://github.com/oracle/graphpipe-tf-py
• https://hub.docker.com/r/sleepsonthefloor/
• https://hackernoon.com/machine-learning-model-pipelines-part-i-
e138b7a7c1ef
Confidential – Oracle Internal/Restricted/Highly Restricted 33
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
AlphaZero
• https://azfour.com/
• https://medium.com/oracledevs/lessons-from-implementing-alphazero-
7e36e9054191
• https://medium.com/@sleepsonthefloor/azfour-a-connect-four-webapp-
powered-by-the-alphazero-algorithm-d0c82d6f3ae9
• https://medium.com/applied-data-science/alphago-zero-explained-in-one-
diagram-365f5abf67e0
• https://deepmind.com/documents/119/agz_unformatted_nature.pdf
• https://arxiv.org/abs/1712.01815
Confidential – Oracle Internal/Restricted/Highly Restricted 34
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Questions and Answers
Confidential – Oracle Internal/Restricted/Highly Restricted 35
Copyright © 2017, Oracle and/or its affiliates. All rights reserved. |
Safe Harbor Statement
The preceding is intended to outline our general product direction. It is intended for
information purposes only, and may not be incorporated into any contract. It is not a
commitment to deliver any material, code, or functionality, and should not be relied upon
in making purchasing decisions. The development, release, and timing of any features or
functionality described for Oracle’s products remains at the sole discretion of Oracle.
Confidential – Oracle Internal/Restricted/Highly Restricted 36

Más contenido relacionado

La actualidad más candente

BYOP: Custom Processor Development with Apache NiFi
BYOP: Custom Processor Development with Apache NiFiBYOP: Custom Processor Development with Apache NiFi
BYOP: Custom Processor Development with Apache NiFi
DataWorks Summit
 

La actualidad más candente (20)

OpenJDK: How to Join In on All the Fun [JavaOne 2017 CON3667]
OpenJDK: How to Join In on All the Fun [JavaOne 2017 CON3667]OpenJDK: How to Join In on All the Fun [JavaOne 2017 CON3667]
OpenJDK: How to Join In on All the Fun [JavaOne 2017 CON3667]
 
Polyglot! A Lightweight Cloud Platform for Java SE, Node, and More
Polyglot! A Lightweight Cloud Platform for Java SE, Node, and MorePolyglot! A Lightweight Cloud Platform for Java SE, Node, and More
Polyglot! A Lightweight Cloud Platform for Java SE, Node, and More
 
Oracle Code in Seoul: Provisioning of Cloud Resource
Oracle Code in Seoul: Provisioning of Cloud ResourceOracle Code in Seoul: Provisioning of Cloud Resource
Oracle Code in Seoul: Provisioning of Cloud Resource
 
Under the Hood of the Smartest Availability Features in Oracle's Autonomous D...
Under the Hood of the Smartest Availability Features in Oracle's Autonomous D...Under the Hood of the Smartest Availability Features in Oracle's Autonomous D...
Under the Hood of the Smartest Availability Features in Oracle's Autonomous D...
 
Oracle RAC - Roadmap for New Features
Oracle RAC - Roadmap for New FeaturesOracle RAC - Roadmap for New Features
Oracle RAC - Roadmap for New Features
 
20191119 Cloud Native Java : GraalVM
20191119 Cloud Native Java : GraalVM20191119 Cloud Native Java : GraalVM
20191119 Cloud Native Java : GraalVM
 
Oracle goldegate microservice
Oracle goldegate microserviceOracle goldegate microservice
Oracle goldegate microservice
 
Supercharge your Code to get optimal Database Performance
Supercharge your Code to get optimal Database PerformanceSupercharge your Code to get optimal Database Performance
Supercharge your Code to get optimal Database Performance
 
Another compilation method in java - AOT (Ahead of Time) compilation
Another compilation method in java - AOT (Ahead of Time) compilationAnother compilation method in java - AOT (Ahead of Time) compilation
Another compilation method in java - AOT (Ahead of Time) compilation
 
Lightweight Java in the Cloud
Lightweight Java in the CloudLightweight Java in the Cloud
Lightweight Java in the Cloud
 
Introduction to YANG data models and their use in OpenDaylight: an overview
Introduction to YANG data models and their use in OpenDaylight: an overviewIntroduction to YANG data models and their use in OpenDaylight: an overview
Introduction to YANG data models and their use in OpenDaylight: an overview
 
Open Device Programmability: Hands-on Intro to RESTCONF (and a bit of NETCONF)
Open Device Programmability: Hands-on Intro to RESTCONF (and a bit of NETCONF)Open Device Programmability: Hands-on Intro to RESTCONF (and a bit of NETCONF)
Open Device Programmability: Hands-on Intro to RESTCONF (and a bit of NETCONF)
 
WAN Automation Engine API Deep Dive
WAN Automation Engine API Deep DiveWAN Automation Engine API Deep Dive
WAN Automation Engine API Deep Dive
 
Cisco Spark and Tropo and the Programmable Web
Cisco Spark and Tropo and the Programmable WebCisco Spark and Tropo and the Programmable Web
Cisco Spark and Tropo and the Programmable Web
 
Developers vs DBAs - How to win the war
Developers vs DBAs - How to win the warDevelopers vs DBAs - How to win the war
Developers vs DBAs - How to win the war
 
Oracle python pandas merge DataFrames
Oracle python pandas merge DataFramesOracle python pandas merge DataFrames
Oracle python pandas merge DataFrames
 
Bringing Java into the Open
Bringing Java into the Open Bringing Java into the Open
Bringing Java into the Open
 
AMIS Oracle OpenWorld en Code One Review 2018 - Pillar 1: Data
AMIS Oracle OpenWorld en Code One Review 2018 - Pillar 1: DataAMIS Oracle OpenWorld en Code One Review 2018 - Pillar 1: Data
AMIS Oracle OpenWorld en Code One Review 2018 - Pillar 1: Data
 
BYOP: Custom Processor Development with Apache NiFi
BYOP: Custom Processor Development with Apache NiFiBYOP: Custom Processor Development with Apache NiFi
BYOP: Custom Processor Development with Apache NiFi
 
Autonomous Data Warehouse
Autonomous Data WarehouseAutonomous Data Warehouse
Autonomous Data Warehouse
 

Similar a GraphPipe - Blazingly Fast Machine Learning Inference by Vish Abrams

Similar a GraphPipe - Blazingly Fast Machine Learning Inference by Vish Abrams (20)

Migrate Oracle WebLogic Applications onto a Containerized Cloud Data Center
Migrate Oracle WebLogic Applications onto a Containerized Cloud Data CenterMigrate Oracle WebLogic Applications onto a Containerized Cloud Data Center
Migrate Oracle WebLogic Applications onto a Containerized Cloud Data Center
 
Everything You Wanted to Know About JIT Compilation but Were Afraid to Ask [J...
Everything You Wanted to Know About JIT Compilation but Were Afraid to Ask [J...Everything You Wanted to Know About JIT Compilation but Were Afraid to Ask [J...
Everything You Wanted to Know About JIT Compilation but Were Afraid to Ask [J...
 
Separation of Concerns through APIs: the Essence of #SmartDB
Separation of Concerns through APIs: the Essence of #SmartDBSeparation of Concerns through APIs: the Essence of #SmartDB
Separation of Concerns through APIs: the Essence of #SmartDB
 
MySQL innodb cluster and Group Replication in a nutshell - hands-on tutorial ...
MySQL innodb cluster and Group Replication in a nutshell - hands-on tutorial ...MySQL innodb cluster and Group Replication in a nutshell - hands-on tutorial ...
MySQL innodb cluster and Group Replication in a nutshell - hands-on tutorial ...
 
20190615 hkos-mysql-troubleshootingandperformancev2
20190615 hkos-mysql-troubleshootingandperformancev220190615 hkos-mysql-troubleshootingandperformancev2
20190615 hkos-mysql-troubleshootingandperformancev2
 
Gartner pace and bi-modal models
Gartner pace and bi-modal modelsGartner pace and bi-modal models
Gartner pace and bi-modal models
 
EPM, ERP, Cloud, and On-Premise: All Integration Options Explained
EPM, ERP, Cloud, and On-Premise:  All Integration Options ExplainedEPM, ERP, Cloud, and On-Premise:  All Integration Options Explained
EPM, ERP, Cloud, and On-Premise: All Integration Options Explained
 
Novinky v Oracle Database 18c
Novinky v Oracle Database 18cNovinky v Oracle Database 18c
Novinky v Oracle Database 18c
 
Cloud Native Java:GraalVM
Cloud Native Java:GraalVMCloud Native Java:GraalVM
Cloud Native Java:GraalVM
 
Cloud Native 자바 플랫폼: Graalvm Overview
Cloud Native 자바 플랫폼: Graalvm OverviewCloud Native 자바 플랫폼: Graalvm Overview
Cloud Native 자바 플랫폼: Graalvm Overview
 
Api design and prototype
Api design and prototypeApi design and prototype
Api design and prototype
 
Meetup Oracle Database: 3 Analizar, Aconsejar, Automatizar… las nuevas funcio...
Meetup Oracle Database: 3 Analizar, Aconsejar, Automatizar… las nuevas funcio...Meetup Oracle Database: 3 Analizar, Aconsejar, Automatizar… las nuevas funcio...
Meetup Oracle Database: 3 Analizar, Aconsejar, Automatizar… las nuevas funcio...
 
Seminole County Teach In 2017: Crooms Acadamy of Information Technology
Seminole County Teach In 2017: Crooms Acadamy of Information TechnologySeminole County Teach In 2017: Crooms Acadamy of Information Technology
Seminole County Teach In 2017: Crooms Acadamy of Information Technology
 
Streaming solutions for real time problems
Streaming solutions for real time problems Streaming solutions for real time problems
Streaming solutions for real time problems
 
Functions and DevOps
Functions and DevOpsFunctions and DevOps
Functions and DevOps
 
Serverless Kotlin
Serverless KotlinServerless Kotlin
Serverless Kotlin
 
Oracle Database Appliance, ODA, X7-2 portfolio.
Oracle Database Appliance, ODA, X7-2 portfolio.Oracle Database Appliance, ODA, X7-2 portfolio.
Oracle Database Appliance, ODA, X7-2 portfolio.
 
Oracle Cloud Café hybrid Cloud 19 mai 2016
Oracle Cloud Café hybrid Cloud 19 mai 2016Oracle Cloud Café hybrid Cloud 19 mai 2016
Oracle Cloud Café hybrid Cloud 19 mai 2016
 
Oracle Management Cloud - HybridCloud Café - May 2016
Oracle Management Cloud - HybridCloud Café - May 2016Oracle Management Cloud - HybridCloud Café - May 2016
Oracle Management Cloud - HybridCloud Café - May 2016
 
18. Madhur Hemnani - Result Orientated Innovation with Oracle HR Analytics
18. Madhur Hemnani - Result Orientated Innovation with Oracle HR Analytics18. Madhur Hemnani - Result Orientated Innovation with Oracle HR Analytics
18. Madhur Hemnani - Result Orientated Innovation with Oracle HR Analytics
 

Más de Oracle Developers

Más de Oracle Developers (20)

Running Kubernetes Workloads on Oracle Cloud Infrastructure
Running Kubernetes Workloads on Oracle Cloud InfrastructureRunning Kubernetes Workloads on Oracle Cloud Infrastructure
Running Kubernetes Workloads on Oracle Cloud Infrastructure
 
Apex atp customer_presentation_wwc march 2019
Apex atp customer_presentation_wwc march 2019Apex atp customer_presentation_wwc march 2019
Apex atp customer_presentation_wwc march 2019
 
Building Cloud Native Applications with Oracle Autonomous Database.
Building Cloud Native Applications with Oracle Autonomous Database.Building Cloud Native Applications with Oracle Autonomous Database.
Building Cloud Native Applications with Oracle Autonomous Database.
 
Fn meetup by Sardar Jamal Arif
Fn meetup by Sardar Jamal ArifFn meetup by Sardar Jamal Arif
Fn meetup by Sardar Jamal Arif
 
Get ready for_an_autonomous_data_driven_future_ext
Get ready for_an_autonomous_data_driven_future_extGet ready for_an_autonomous_data_driven_future_ext
Get ready for_an_autonomous_data_driven_future_ext
 
Cloud Native Meetup Santa Clara 07-11-2019 by Manish Kapur
Cloud Native Meetup Santa Clara 07-11-2019 by Manish KapurCloud Native Meetup Santa Clara 07-11-2019 by Manish Kapur
Cloud Native Meetup Santa Clara 07-11-2019 by Manish Kapur
 
Container Native Development Tools - Talk by Mickey Boxell
Container Native Development Tools - Talk by Mickey BoxellContainer Native Development Tools - Talk by Mickey Boxell
Container Native Development Tools - Talk by Mickey Boxell
 
General Capabilities of GraalVM by Oleg Selajev @shelajev
General Capabilities of GraalVM by Oleg Selajev @shelajevGeneral Capabilities of GraalVM by Oleg Selajev @shelajev
General Capabilities of GraalVM by Oleg Selajev @shelajev
 
GraalVM Native Images by Oleg Selajev @shelajev
GraalVM Native Images by Oleg Selajev @shelajevGraalVM Native Images by Oleg Selajev @shelajev
GraalVM Native Images by Oleg Selajev @shelajev
 
Serverless Patterns by Jesse Butler
Serverless Patterns by Jesse ButlerServerless Patterns by Jesse Butler
Serverless Patterns by Jesse Butler
 
Java Library for High Speed Streaming Data
Java Library for High Speed Streaming Data Java Library for High Speed Streaming Data
Java Library for High Speed Streaming Data
 
Artificial Intelligence
Artificial IntelligenceArtificial Intelligence
Artificial Intelligence
 
Reactive Java Programming: A new Asynchronous Database Access API by Kuassi M...
Reactive Java Programming: A new Asynchronous Database Access API by Kuassi M...Reactive Java Programming: A new Asynchronous Database Access API by Kuassi M...
Reactive Java Programming: A new Asynchronous Database Access API by Kuassi M...
 
Managing containers on Oracle Cloud by Jamal Arif
Managing containers on Oracle Cloud by Jamal ArifManaging containers on Oracle Cloud by Jamal Arif
Managing containers on Oracle Cloud by Jamal Arif
 
North America November Meetups
North America November MeetupsNorth America November Meetups
North America November Meetups
 
North America Meetups in September
North America Meetups in September North America Meetups in September
North America Meetups in September
 
Introduction to the Oracle Container Engine
Introduction to the Oracle Container EngineIntroduction to the Oracle Container Engine
Introduction to the Oracle Container Engine
 
Oracle Data Science Platform
Oracle Data Science PlatformOracle Data Science Platform
Oracle Data Science Platform
 
Persistent storage with containers By Kaslin Fields
Persistent storage with containers By Kaslin FieldsPersistent storage with containers By Kaslin Fields
Persistent storage with containers By Kaslin Fields
 
The Fn Project by Jesse Butler
 The Fn Project by Jesse Butler The Fn Project by Jesse Butler
The Fn Project by Jesse Butler
 

Último

Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
WSO2
 

Último (20)

ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemkeProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
ProductAnonymous-April2024-WinProductDiscovery-MelissaKlemke
 
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
Navigating the Deluge_ Dubai Floods and the Resilience of Dubai International...
 
AWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of TerraformAWS Community Day CPH - Three problems of Terraform
AWS Community Day CPH - Three problems of Terraform
 
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, AdobeApidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
Apidays New York 2024 - Scaling API-first by Ian Reasor and Radu Cotescu, Adobe
 
Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)Introduction to Multilingual Retrieval Augmented Generation (RAG)
Introduction to Multilingual Retrieval Augmented Generation (RAG)
 
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdfRising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
Rising Above_ Dubai Floods and the Fortitude of Dubai International Airport.pdf
 
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWEREMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
EMPOWERMENT TECHNOLOGY GRADE 11 QUARTER 2 REVIEWER
 
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
Apidays New York 2024 - Passkeys: Developing APIs to enable passwordless auth...
 
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
Apidays New York 2024 - APIs in 2030: The Risk of Technological Sleepwalk by ...
 
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
Biography Of Angeliki Cooney | Senior Vice President Life Sciences | Albany, ...
 
MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024MINDCTI Revenue Release Quarter One 2024
MINDCTI Revenue Release Quarter One 2024
 
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost SavingRepurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
Repurposing LNG terminals for Hydrogen Ammonia: Feasibility and Cost Saving
 
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 AmsterdamDEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
DEV meet-up UiPath Document Understanding May 7 2024 Amsterdam
 
Architecting Cloud Native Applications
Architecting Cloud Native ApplicationsArchitecting Cloud Native Applications
Architecting Cloud Native Applications
 
How to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected WorkerHow to Troubleshoot Apps for the Modern Connected Worker
How to Troubleshoot Apps for the Modern Connected Worker
 
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ..."I see eyes in my soup": How Delivery Hero implemented the safety system for ...
"I see eyes in my soup": How Delivery Hero implemented the safety system for ...
 
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
Web Form Automation for Bonterra Impact Management (fka Social Solutions Apri...
 
Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...Apidays New York 2024 - The value of a flexible API Management solution for O...
Apidays New York 2024 - The value of a flexible API Management solution for O...
 
presentation ICT roal in 21st century education
presentation ICT roal in 21st century educationpresentation ICT roal in 21st century education
presentation ICT roal in 21st century education
 
Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..Understanding the FAA Part 107 License ..
Understanding the FAA Part 107 License ..
 

GraphPipe - Blazingly Fast Machine Learning Inference by Vish Abrams

  • 1.
  • 2. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Confidential – Oracle Internal/Restricted/Highly Restricted 2 Vish Abrams Architect, Cloud Develompent, Oracle October 9, 2018 Blazingly Fast Machine Learning Inference
  • 3. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Program Agenda Machine Learning Model Serving What is GraphPipe? Advantages Protocol Deep Dive Real World Demo More Info 1 2 3 4 Confidential – Oracle Internal/Restricted/Highly Restricted 3 5 6
  • 4. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Program Agenda Machine Learning Inference What is GraphPipe? Performance Protocol Deep Dive Real World Demo More Info 1 2 3 4 Confidential – Oracle Internal/Restricted/Highly Restricted 4 5 6
  • 5. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Machine Learning Inference (Model Serving) • Building machine learning models has become much easier due to open source frameworks like TensorFlow and Pytorch • Serving machine learning models means putting your trained model onto a server so that it can be accessed by client applications • This involves two components: the ML client and the ML server. • The client talks to the server using some kind of communication protocol: often JSON over HTTP. Confidential – Oracle Internal/Restricted/Highly Restricted 5
  • 6. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | ML Client Confidential – Oracle Internal/Restricted/Highly Restricted 6
  • 7. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | ML Server Confidential – Oracle Internal/Restricted/Highly Restricted 7
  • 8. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Program Agenda Machine Learning Model Serving What is GraphPipe? Advantages Protocol Deep Dive Real World Demo More Info 1 2 3 4 Confidential – Oracle Internal/Restricted/Highly Restricted 8 5 6
  • 9. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | What is GraphPipe? GraphPipe is an open source protocol and collection of software designed to simplify machine learning model deployment and decouple it from framework-specific model implementations. Confidential – Oracle Internal/Restricted/Highly Restricted 9
  • 10. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | What is GraphPipe? In other words, it turns this: Confidential – Oracle Internal/Restricted/Highly Restricted 10 mxnet servertensorflow serving custom server standard jsoncustom protocolprotocol buffers custom clientautogenerated client custom client
  • 11. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | What is GraphPipe? Confidential – Oracle Internal/Restricted/Highly Restricted 11 Into this: graphpipe-onnxgraphpipe-tf
  • 12. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | GraphPipe Features • A minimalist machine learning transport specification based on flatbuffers • Simple reference model servers for Tensorflow, Caffe2, and ONNX. • Efficient client implementations in Go, Python, and Java. Confidential – Oracle Internal/Restricted/Highly Restricted 12
  • 13. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Why Did we Make It? • Production deployments of AI agents are around the corner • Model Serving is an important part of production solutions • Existing solutions suffer from various problems: – Inconsistent – Inefficient – Custom Clients • A standard along with simple implementations moves the industry forward Confidential – Oracle Internal/Restricted/Highly Restricted 13
  • 14. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Program Agenda Machine Learning Model Serving What is GraphPipe? Advantages Protocol Deep Dive Real World Demo More Info 1 2 3 4 Confidential – Oracle Internal/Restricted/Highly Restricted 14 5 6
  • 15. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Ease of Development • Model Servers are written in Go – a very accessible language • Flatbuffer code generation makes it easy to produce new clients • Open spec makes it possible to integrate with existing servers Confidential – Oracle Internal/Restricted/Highly Restricted 15
  • 16. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Protocol Performance Confidential – Oracle Internal/Restricted/Highly Restricted 16
  • 17. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Serving Performance Confidential – Oracle Internal/Restricted/Highly Restricted 17
  • 18. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Program Agenda Machine Learning Model Serving What is GraphPipe? Advantages Protocol Deep Dive Real World Demo More Info 1 2 3 4 Confidential – Oracle Internal/Restricted/Highly Restricted 18 5 6
  • 19. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Flatbuffers • Extensible protocol • Small code footprint • Near-zero deserialization overhead Confidential – Oracle Internal/Restricted/Highly Restricted 19
  • 20. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Protocol Summary Confidential – Oracle Internal/Restricted/Highly Restricted 20
  • 21. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Program Agenda Machine Learning Model Serving What is GraphPipe? Advantages Protocol Deep Dive Real World Demo More Info 1 2 3 4 Confidential – Oracle Internal/Restricted/Highly Restricted 21 5 6
  • 22. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | AlphaZero • Algorithm for training a machine to play any game* • Any game that can be represented with a Markov Process • Trained without human information through self play • Needs a structured representation of the game state • Needs rules for transitioning from one state to the next Confidential – Oracle Internal/Restricted/Highly Restricted 22
  • 23. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | AlphaZero Timeline AlphaGo Beats Fan Hui Oct-16 Paper published in Nature Jan- 16 AlphaGo Beats Lee Sedol Mar-16 AlphaGo Beats Ke Jie May-17 AlphaGoZero published Oct-17 AlphaZero published Dec-17 Confidential – Oracle Internal/Restricted/Highly Restricted 23
  • 24. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | The Game Playing Black Box Confidential – Oracle Internal/Restricted/Highly Restricted 24 Neural NetworkPosition Move
  • 25. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Training the Network Confidential – Oracle Internal/Restricted/Highly Restricted 25 TrainingLabeled Data Neural Network
  • 26. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Generating Data Confidential – Oracle Internal/Restricted/Highly Restricted 26 Self-Play (MCTS) Neural Network Labeled Data
  • 27. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | AlphaZero In a nutshell Confidential – Oracle Internal/Restricted/Highly Restricted 27 Self-PlayTraining Neural Network Labeled Data
  • 28. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | AlphaZero for Connnect Four • We trained a network to play Connect Four using 150 cycles of this process (and playing about 1,000,000 games during self-play) • The network finds the correct move in about 99% of positions • We used GraphPipe as part of the training process because we were generating games across a cluster of 5 machines with GPUs • But GraphPipe is even more useful for deploying this model so that people can use it • How do we deploy our model for use in an application? GraphPIpe! Confidential – Oracle Internal/Restricted/Highly Restricted 28
  • 29. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Serving the AlphaZero Trained Network Confidential – Oracle Internal/Restricted/Highly Restricted 29 Neural Network GraphPipe Position Move GraphPipe Web Frontend
  • 30. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Live Demo! Confidential – Oracle Internal/Restricted/Highly Restricted 30
  • 31. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Actual Architecture Confidential – Oracle Internal/Restricted/Highly Restricted 31
  • 32. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Program Agenda Machine Learning Model Serving What is GraphPipe? Advantages Protocol Deep Dive Real World Demo More Info 1 2 3 4 Confidential – Oracle Internal/Restricted/Highly Restricted 32 5 6
  • 33. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | GraphPipe • https://oracle.github.io/graphpipe/ • https://github.com/oracle/graphpipe • https://github.com/oracle/graphpipe-go • https://github.com/oracle/graphpipe-py • https://github.com/oracle/graphpipe-tf-py • https://hub.docker.com/r/sleepsonthefloor/ • https://hackernoon.com/machine-learning-model-pipelines-part-i- e138b7a7c1ef Confidential – Oracle Internal/Restricted/Highly Restricted 33
  • 34. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | AlphaZero • https://azfour.com/ • https://medium.com/oracledevs/lessons-from-implementing-alphazero- 7e36e9054191 • https://medium.com/@sleepsonthefloor/azfour-a-connect-four-webapp- powered-by-the-alphazero-algorithm-d0c82d6f3ae9 • https://medium.com/applied-data-science/alphago-zero-explained-in-one- diagram-365f5abf67e0 • https://deepmind.com/documents/119/agz_unformatted_nature.pdf • https://arxiv.org/abs/1712.01815 Confidential – Oracle Internal/Restricted/Highly Restricted 34
  • 35. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Questions and Answers Confidential – Oracle Internal/Restricted/Highly Restricted 35
  • 36. Copyright © 2017, Oracle and/or its affiliates. All rights reserved. | Safe Harbor Statement The preceding is intended to outline our general product direction. It is intended for information purposes only, and may not be incorporated into any contract. It is not a commitment to deliver any material, code, or functionality, and should not be relied upon in making purchasing decisions. The development, release, and timing of any features or functionality described for Oracle’s products remains at the sole discretion of Oracle. Confidential – Oracle Internal/Restricted/Highly Restricted 36