Presentation is loading. Please wait.

Presentation is loading. Please wait.

5/16/2018 3:45 AM BRK3298 Building machine learning applications using R and Python in SQL Server 2017 Umachandar Jayachandran (UC) Sumit Kumar Program.

Similar presentations


Presentation on theme: "5/16/2018 3:45 AM BRK3298 Building machine learning applications using R and Python in SQL Server 2017 Umachandar Jayachandran (UC) Sumit Kumar Program."— Presentation transcript:

1 5/16/2018 3:45 AM BRK3298 Building machine learning applications using R and Python in SQL Server 2017 Umachandar Jayachandran (UC) Sumit Kumar Program Managers © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

2 Agenda Machine Learning Intro SQL Server Machine Learning Services
Customer scenarios What’s coming?

3 Bringing intelligence to where data lives
Application Application + Intelligence VS Intelligence + Database Database Regular Database + App Intelligence Database + App

4 Why Machine Learning in SQL Server?
5/16/2018 3:45 AM Why Machine Learning in SQL Server? Eliminate data movement Leverage database security Push ML compute to the database R integration Python integration Operationalize ML scripts and models Calling familiar T-SQL stored procedures Model management in SQL Server Data Scientist Interacts directly with data Analytics library Enterprise grade performance and scale Scale your R and Python analytics with multi- threading and parallel processing SQL Server security, compliance, resource governance, query performance, always on secondaries 010101 100100 010010 010101 100100 010010 010010 100100 010101 SQL Developer/ DBA SQL Transformations Relational data Manage data and analytics together © 2013 Microsoft Corporation. All rights reserved. Microsoft, Windows, and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

5 Customer Story - PROS Pricing Optimization Segmentation
Expert Target Floor Group customers, products & transactions into micro-segments of similar willingness-to-pay Apply optimization algorithms to target the pricing envelope ‘sweet spot’ in every segment

6 Attribute Selection Tool
5/16/2018 3:45 AM Before After SQL Server Attribute Selection Tool C++/R SQL Server Attribute Selection sp_execute_external_script ‘R code’ Data tables Data tables Segmentation Tool C++/R Segmentation sp_execute_external_script ‘R code’ Stored Proc Scoring sp_execute_external_script ‘R code’ © 2014 Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

7 Customer stories ATTOM Data Solutions Acxiom Heartland Bank
ATTOM will be able to take advantage of a host of new capabilities, including machine learning and predictive analytics. ATTOM Data Solutions Real estate property insights Acxiom Migrating from SAS Targeted marketing campaigns Heartland Bank Build financial models With R Services, Acxiom is building better, more accurate models using larger data sets, which results in more precisely targeted marketing for customers. The bank has moved its credit scorecard development, arrears analysis, investment forecasting, and analysis of intermediary and broker performance to the R Server platform.

8 5/16/2018 3:45 AM Hello Iris! Demo © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

9 SQL Server Machine Learning Services
R support (3.2.2 version) Microsoft R Server (under Modern Lifecycle Policy) SQL Server 2017 Native scoring using PREDICT function (+Linux support) EXTERNAL LIBRARY DDL for R package management Batch mode execution support for input data R support (3.3.3 version) Python support (Anaconda 3.5.2)

10 Azure SQL Database Machine Learning Services
Native scoring using PREDICT function R support preview (3.3.3 version) Available in West Central US Region Premium & Premium RS Service Tiers Base R packages & RevoscaleR package Training & Scoring of Models that fit in memory Trivial Parallelism & Streaming support One concurrent execution of R script

11 Machine Learning Server
5/16/2018 3:45 AM Machine Learning Server Multi-platform support Windows, Linux, Hadoop, SQL Server Microsoft R Server RevoScaleR, MicrosoftML, olapR, sqlrutils packages Web services operationalization Microsoft Machine Learning Server R & Python support revoscalepy, microsoftml python libraries rxExecBy Hadoop Licensing changes 5 nodes for every SQL Server EE core under Software Assurance © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

12 Data Scientists - Data Exploration and Model Development
Microsoft Tech Summit FY17 5/16/2018 3:45 AM Data Scientists - Data Exploration and Model Development train <- RxSqlServerData(query, connectionString, computeContext) rxLogit(formula, train) 2 Execution 1 Script SQL Server Data Scientist Workstation 3 Results Machine Learning Services Any R/Python IDE R/Python Runtime © 2016 Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

13 Machine Learning Services
Microsoft Data Amp 5/16/2018 3:45 AM Application Developer - Model Operationalization 2 Execution Stored Proc call Results 1 3 The stored procedure contains R or Python code and executes in-database SQL Server Application Machine Learning Services exec sp_execute_external_script @language = ‘Python’ , @script = -- Python code -- R/Python Runtime © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

14 Hospital Length of Stay
5/16/2018 3:45 AM Hospital Length of Stay HeaIthcare ISV building intelligence into their application Allow hospitals to optimize resource allocation Dashboard that shows Predictions against actuals © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

15 Operationalize Length of Stay Predictions
Problem Predict accurately how long a newly admitted patient will stay in the hospital Solution Build a model using anonymized patient data Operationalize model using T-SQL stored procedures Train Model using Anonymized data Anonymized Patient information Key variables are number of previous admissions, diagnostic codes, lab results Operationalize Model in Azure SQL Database Deploy model to production database Use model to predict length of stay

16 Predict patient length of stay
5/16/2018 3:45 AM Predict patient length of stay Demo © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

17 Realtime Predictions using Native Scoring
5/16/2018 3:45 AM Realtime Predictions using Native Scoring PREDICT function No dependency on R or Python runtime Enabled on SQL Server in Windows & Linux Usage Single or small number of rows scoring Highly concurrent scoring scenarios Predict during INSERT, UPDATE, MERGE statements Requirements Models built using RevoScaleR or revoscalepy rxLinMod, rxLogit, rxBTrees, rxDTree, rxDForest Serialized using rxSerializeModel (R) or rx_serialize_model (Python) © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

18 PREDICT syntax PREDICT ( MODEL = @model | model_literal,
5/16/2018 3:45 AM PREDICT syntax PREDICT ( MODEL | model_literal, DATA = object AS <table_alias> ) WITH ({ {column_definition } [,...n ] } ) INSERT INTO loan_applications (c1, c2, c3, c4, risk_score) SELECT d.c1, d.c2, d.c3, d.c4, p.score FROM PREDICT(MODEL DATA as d) WITH(score float) as p; © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

19 Fraud Detection using PREDICT
Problem Detect potentially fraudulent transactions with low latency Solution Build a model to learn patterns of fraudulent transactions Train Model using Sample data Historical labelled credit transactions, risk factors for IP address/geographical data, transaction characteristics, account information Operationalize scoring using PREDICT Use model to get probability of fraud for new transactions Use PREDICT to score transactions during INSERT

20 Fraud detection using PREDICT
5/16/2018 3:45 AM Fraud detection using PREDICT Demo © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

21 Deploy predictive analytics
Make your app/reports intelligent by consuming predictions Deploy your ML scripts with sp_execute_external_ script and predict using the models Train models with sp_execute_external_ script and save the models in database Develop, explore and experiment in your favorite IDE Develop Train Deploy Consume

22 Roadmap Machine Learning Services in Azure SQL Database Future release
5/16/2018 3:45 AM Roadmap Machine Learning Services in Azure SQL Database Configuration & Monitoring R support MicrosoftML Package Package installation / management using CREATE EXTERNAL LIBRARY DDL SQL Compute Context support from client or R script executing on the server Parallel execution for R Server models Python support Future release Machine Learning Services in SQL Server on Linux Failover cluster support Partitioning support for input data © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

23 Call to action Resources BRK3261
5/16/2018 3:45 AM Call to action Resources SQL Server Samples – R Services & ML Services SSMS Reports for ML Services SQL Server Machine Learning Services (aka.ms/mlsqldev) Getting started ML tutorials SQL Server Developer Tutorials (aka.ms/sqldev) Getting started SQL tutorials BRK3261 Performance Patterns for SQL Server Machine Learning Services © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

24 Please evaluate this session
Tech Ready 15 5/16/2018 Please evaluate this session From your Please expand notes window at bottom of slide and read. Then Delete this text box. PC or tablet: visit MyIgnite Phone: download and use the Microsoft Ignite mobile app Your input is important! © 2012 Microsoft Corporation. All rights reserved. Microsoft, Windows, Windows Vista and other product names are or may be registered trademarks and/or trademarks in the U.S. and/or other countries. The information herein is for informational purposes only and represents the current view of Microsoft Corporation as of the date of this presentation. Because Microsoft must respond to changing market conditions, it should not be interpreted to be a commitment on the part of Microsoft, and Microsoft cannot guarantee the accuracy of any information provided after the date of this presentation. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.

25

26 What is Machine Learning?
5/16/2018 3:45 AM What is Machine Learning? Uses data mining and learning techniques to train models using historical data to predict future outcomes Examples Predict store sales based on historical performance Predict default of a loan based on loan/transaction history Predict sentiment of a new tweet or review or call log Classify customers into groups based on transaction characteristics Classify images and extract features from images © Microsoft Corporation. All rights reserved. MICROSOFT MAKES NO WARRANTIES, EXPRESS, IMPLIED OR STATUTORY, AS TO THE INFORMATION IN THIS PRESENTATION.


Download ppt "5/16/2018 3:45 AM BRK3298 Building machine learning applications using R and Python in SQL Server 2017 Umachandar Jayachandran (UC) Sumit Kumar Program."

Similar presentations


Ads by Google