>> Hi, everyone. In this video,
we are going to talk about
time series forecasting with Azure Machine Learning.
Machine learning is a data science technique
that allows computers to use
existing data to forecast future behaviors, outcomes, and trends.
Using machine learning, computers
learn without being explicitly programmed.
Time series forecasting is the task of predicting
future values in a time order sequence of observations.
It is a common problem and has
application in many different industries.
This video shows how
time series forecasting can be
performed through applying machine learning techniques.
Azure Machine Learning service is a Cloud service that
you can use to develop and deploy machine learning models.
Using the Azure Machine Learning service,
you can prepare your data,
track your models as you build, train,
deployed and manage them
all at the broad scale that the Cloud provides.
From the main Azure Machine Learning service documentation,
you can click on "Quickstarts" and
then experiment with a Cloud notebook.
In this tutorial, we are going to use
Azure Notebooks to run our code.
First of all, we need to
create an Azure Machine Learning workspace,
if you don't have one.
The workspace is the top-level resource
for Azure Machine Learning service.
It provides a centralized place to work with
all the artifacts that you create
when you use Azure Machine Learning service.
You can also open your workspace in the Azure portal.
So let's see how this works.
On the Azure portal,
I have already created my machine learning service workspace.
As you can see, one of the option is
"Get started in Azure notebooks".
So let's click on this.
Azure Notebooks is a free hosted service to develop and
run Jupyter Notebooks in the Cloud with no installation.
For these specific scenarios,
we're going to use also automated machine learning that
is a capability within the Azure Machine Learning service,
that identifies the best machine learning pipelines
for your labeled data.
This scenario focuses on
energy demand forecasting where the goal
is to predict the future load on an energy grid.
The solution is strain on a public dataset from
the New York Independent System Operator
which operates the power grid for New York State.
The dataset includes hourly power demand data
for the New York City over the period of five years.
An additional dataset containing hourly weather condition in
the New York City over
the same time period was taken from darksky.net.
Let's see together how we can ingest
our data and start building our machine learning model.
As a part of the setup,
you have already created a workspace.
For AutoML, you need also to credit an "Experiment."
An "Experiment" is a name object in a workspace.
So here, as you can see,
you can retrieve your workspace and also you
can create your "Experiment" and give it a name.
After this we can ingest
our energy demand data and have also a preview of our dataset.
As you can see, we have a timestamp,
demand, the precipitation, and temperature columns.
Then we can split the data to train and test and then also
split the train data to train and validation datasets.
At this moment, we are ready to
instantiate an AutoML configure object.
This one defines the setting and
the data used to run these experiments.
Since we are in a forecasting scenario,
the task that we're going to define here is forecasting.
Then the primary math that we're going to use
is the normalized root-mean-squared error.
The iteration is the number of iteration that
you want to run for this specific Experiment,
and you can also define the time limit,
the minutes for each iteration.
After that, you define your x values
and your y values meaning that they're target values.
You can also define your x value,
then y value so that these are the data used to
evaluate a model in iteration,
and then finally the path.
This is, of course, the relative path to the project folder.
After teaser, we can have a look at our best model.
Here we selected the best pipeline from our iterations.
We can retrieve explanation for our best model
if we want and we can also monitor the different runs here.
As you can see, we have a pipeline, iteration metric,
best metric, status, and duration information.
After this, we are ready to test the best of each model.
We can use the "Check data" function to remove the NaN values from
the y tests if we want to
avoid error when we calculate our metrics,
and we can also plot the prediction to
compare them to the actual data.
Finally, we can deploy our model.
So we can register our model here, as you can see,
and then we can create a scoring script that this will be
used to run the model on the new data for predictions.
Now let's see from the Azure portal if
our model was registered and deployed successfully.
You just need to go to Azure Portal.
Here again there is my machine learning service workspace.
You just need to click on "Experiment".
The Experiment that I was working on right
now is the AutoML energy-demanding forecasting,
and here is a very nice because I can see
all the metrics that I need to see and
also the different pipelines, compute, models.
So for example, this case.
If I click on "Model," you can see that
the model that I created is here.
If you want to learn more about
the Azure Machine Learning service and time series forecasting,
you can check out the link to
Azure Machine Learning service and
Automated Machine Learning documentation.
If you don't have an Azure subscription,
you can create one for free so that you
can get started with Azure Machine Learning service.
[MUSIC]