Skip to content

Latest commit

 

History

History
139 lines (80 loc) · 4.28 KB

03Modeling.md

File metadata and controls

139 lines (80 loc) · 4.28 KB

03. Modeling (Azure Machine Learning Studio)

Architecture

After the data preperation on Azure Databricks, it is time to build a machine learning model to prediect customer chrun. In this lab, we'll use Azure Machine Learning Studio for training and modeling.

  • Azure Machine Learning Studio
  • How to understand data
  • Understand traning algorithm
  • Traing models and select the best model

03

1. Create Azure Machine Learning Studio

Create a service from here Azure Portal #Create ML Studio for lab.

Reference following table to create the service

Name Value
workspace Name azlab###
Subscription yoursubscription
Resource Group azlab-###-rg
Localtion South Central US
Storage Account 'Create new' , azhol###storage
Workspace pricing tier Standard
Web service plan 'create new', azlab###Plan

CreateMLStudio

Once you fill out the from, create by clicking button 'Create'

Pin the service to access the service easy CreateMLStudio

2. Access ML Studio

Open a new browser or tap and go to Azure ML Studio

Click on sign in, if you are already loged in on Azure Portal, it'll automatically

WorkspaceName

When you logged in to the service, please make sure your workspace name is correct or not

WorkspaceName

3. Create a new experiment

Click '+ NEW' and click 'Blank Experiment'

newexp

3.1. Rename experiment

Click on the title of the experiment, and name it as azhol###

3.2. Imoprt dataset

3.2.1. Get dataset url

In order to get the dataset url from your blob storage, you need to go to your blob storage account fomr Azure Portal

Open new tab (or browser) go to Azure Portal

Go to you blob by searching name of your blob which is similiar as 'blobdev'

searchblob

In order to get save url to access to the dataset, you need to create a SAS url from the portal

Go to your blob storage account and go to container 'ingest'

Follow menu from the blob blade, Blob Service > Blobs > inget > azmlstudio

To generate SAS, click on the file 'part-00000-tid....csv', 'Generate SAS', 'Generate blob SAS token and URL' and then click on 'copy icon' at the bottom of the screen

searchblob

Come back to Azure Machine Learning Studio

Search import from the left search box and drag and drop the import module to canvas

Click on the 'Import Data' module

Chage some options in the properties on the left panel

Name Value
Data Source Web URL via HTTP
Data Source URL paste url from the blob SAS generater
Data format csv
CSV or TSV has header Check
Use cached resutls Check

import

Click 'Run' button in the bottom of the canvas, then it will download the dataset from blob to Azure ML Studio in a minute (around 10 sec)

3.3. Understand data

When the running is done, you will see green check mark on your right coner of the canvas

Right click on the port of the module and click on 'Visualize'

From the visualize you can see summary informatio about the dataset

import

3.4. Split data

Search split Data from the left search box and drag and drop the import module to canvas

And drag bottom port of Import Data module drop to top port of Split Data module to link between thoes two module

import

Update split ratio in the properites

import

3.5. Train

To trian the model we'll use:

  • Two-Calss Logistic Regression
  • Two-Class Boosted Decision Tree

And the label is 'Churn' since we are trying to build a machine learning to predict a customer churn

import


Next > 04. Operationalization


Main