Deep Learning for Time Series Cookbook - Vitor Cerqueira - E-Book

Deep Learning for Time Series Cookbook E-Book

Vitor Cerqueira

0,0
35,99 €

-100%
Sammeln Sie Punkte in unserem Gutscheinprogramm und kaufen Sie E-Books und Hörbücher mit bis zu 100% Rabatt.

Mehr erfahren.
Beschreibung

Most organizations exhibit a time-dependent structure in their processes, including fields such as finance. By leveraging time series analysis and forecasting, these organizations can make informed decisions and optimize their performance. Accurate forecasts help reduce uncertainty and enable better planning of operations. Unlike traditional approaches to forecasting, deep learning can process large amounts of data and help derive complex patterns. Despite its increasing relevance, getting the most out of deep learning requires significant technical expertise.
This book guides you through applying deep learning to time series data with the help of easy-to-follow code recipes. You’ll cover time series problems, such as forecasting, anomaly detection, and classification. This deep learning book will also show you how to solve these problems using different deep neural network architectures, including convolutional neural networks (CNNs) or transformers. As you progress, you’ll use PyTorch, a popular deep learning framework based on Python to build production-ready prediction solutions.
By the end of this book, you'll have learned how to solve different time series tasks with deep learning using the PyTorch ecosystem.

Das E-Book können Sie in Legimi-Apps oder einer beliebigen App lesen, die das folgende Format unterstützen:

EPUB
MOBI

Seitenzahl: 269

Veröffentlichungsjahr: 2024

Bewertungen
0,0
0
0
0
0
0
Mehr Informationen
Mehr Informationen
Legimi prüft nicht, ob Rezensionen von Nutzern stammen, die den betreffenden Titel tatsächlich gekauft oder gelesen/gehört haben. Wir entfernen aber gefälschte Rezensionen.



Deep Learning for Time Series Cookbook

Use PyTorch and Python recipes for forecasting, classification, and anomaly detection

Vitor Cerqueira

Luís Roque

Deep Learning for Time Series Cookbook

Copyright © 2024 Packt Publishing

All rights reserved. No part of this book may be reproduced, stored in a retrieval system, or transmitted in any form or by any means, without the prior written permission of the publisher, except in the case of brief quotations embedded in critical articles or reviews.

Every effort has been made in the preparation of this book to ensure the accuracy of the information presented. However, the information contained in this book is sold without warranty, either express or implied. Neither the author(s), nor Packt Publishing or its dealers and distributors, will be held liable for any damages caused or alleged to have been caused directly or indirectly by this book.

Packt Publishing has endeavored to provide trademark information about all of the companies and products mentioned in this book by the appropriate use of capitals. However, Packt Publishing cannot guarantee the accuracy of this information.

Group Product Manager: Ali Abidi

Publishing Product Manager: Sanjana Gupta

Book Project Manager: Aparna Ravikumar Nair

Senior Editor: Nazia Shaikh

Technical Editor: Rahul Limbachiya

Copy Editor: Safis Editing

Proofreader: Safis Editing

Indexer: Pratik Shirodkar

Production Designer: Prashant Ghare

Senior DevRel Marketing Coordinator: Vinishka Kalra

First published: March 2024

Production reference: 1210324

Published by Packt Publishing Ltd.

Grosvenor House

11 St Paul’s Square

Birmingham

B3 1RB, UK

ISBN 978-1-80512-923-3

www.packtpub.com

Contributors

About the authors

Vitor Cerqueira is a machine learning researcher at the Faculty of Engineering at the University of Porto, working on a variety of projects concerning time-series data, including forecasting, anomaly detection, and meta-learning. Vitor earned his Ph.D. with honors, also from the University of Porto, and he also has a background in data analytics and mathematics. He has authored several peer-reviewed publications on related topics.

Luís Roque, is the Founder and Partner of ZAAI, a company focused on AI product development, consultancy, and investment in AI startups. He also serves as the Vice President of Data & AI at Marley Spoon, leading teams across data science, data analytics, data product, data engineering, machine learning operations, and platforms.

In addition, he holds the position of AI Advisor at CableLabs, where he contributes to integrating the broadband industry with AI technologies.

Luís is also a Ph.D. Researcher in AI at the University of Porto's AI&CS lab and oversees the Data Science Master's program at Nuclio Digital School in Barcelona. Previously, he co-founded HUUB, where he served as CEO until its acquisition by Maersk.

About the reviewer

Tuhin Sharma is a senior principal data scientist at Red Hat in the corporate development and strategy group. Prior to that, he worked at Hypersonix as an AI architect. He also co-founded and has been CEO of Binaize, a website conversion intelligence product for e-commerce SMBs. He received a master’s degree from IIT in Roorkee and a bachelor’s degree in computer science from IIEST in Shibpur. He loves to code and collaborate on open source and research projects. He has four research papers and five patents in the field of AI and NLP. He is a reviewer of the IEEE MASS conference in the AI track. He writes deep learning articles for O’Reilly in collaboration with the AWS MXNet team. He is a regular speaker at prominent AI conferences such as O’Reilly AI, ODSC, and GIDS.

Table of Contents

Preface

1

Getting Started with Time Series

Technical requirements

Loading a time series using pandas

Getting ready

How to do it…

How it works…

Visualizing a time series

Getting ready

How to do it…

How it works…

There’s more…

Resampling a time series

Getting ready

How to do it…

How it works…

There’s more…

Dealing with missing values

Getting ready

How to do it…

How it works…

There’s more…

Decomposing a time series

Getting ready

How to do it…

How it works…

There’s more…

See also

Computing autocorrelation

Getting ready

How to do it…

How it works…

There’s more…

Detecting stationarity

Getting ready

How to do it…

How it works…

There’s more…

Dealing with heteroskedasticity

Getting ready

How to do it…

How it works…

There’s more…

See also

Loading and visualizing a multivariate time series

Getting ready

How to do it…

How it works…

Resampling a multivariate time series

Getting ready

How to do it…

How it works…

Analyzing correlation among pairs of variables

Getting ready

How to do it…

How it works…

2

Getting Started with PyTorch

Technical requirements

Installing PyTorch

Getting ready

How to do it…

How it works…

Basic operations in PyTorch

Getting ready

How to do it…

How it works…

Advanced operations in PyTorch

Getting ready

How to do it…

How it works…

Building a simple neural network with PyTorch

Getting ready

How to do it…

There’s more…

Training a feedforward neural network

Getting ready

How to do it…

How it works…

Training a recurrent neural network

Getting ready

How to do it…

How it works…

Training an LSTM neural network

Getting ready

How to do it…

How it works…

Training a convolutional neural network

Getting ready

How to do it…

How it works…

3

Univariate Time Series Forecasting

Technical requirements

Building simple forecasting models

Getting ready

How to do it…

How it works…

There’s more…

Univariate forecasting with ARIMA

Getting ready

How to do it…

How it works…

There’s more…

Preparing a time series for supervised learning

Getting ready

How to do it…

How it works…

There’s more…

Univariate forecasting with a feedforward neural network

Getting ready

How to do it…

How it works…

There’s more…

Univariate forecasting with an LSTM

Getting ready

How to do it…

How it works…

There’s more…

Univariate forecasting with a GRU

Getting ready

How to do it…

How it works…

There’s more…

Univariate forecasting with a Stacked LSTM

Getting ready

How to do it…

How it works…

Combining an LSTM with multiple fully connected layers

Getting ready

How to do it…

How it works…

There’s more…

Univariate forecasting with a CNN

Getting ready

How to do it…

How it works…

There’s more…

Handling trend – taking first differences

Getting ready

How to do it…

How it works…

There’s more…

Handling seasonality – seasonal dummies and Fourier series

Getting ready

How to do it…

How it works…

There’s more…

Handling seasonality – seasonal differencing

Getting ready

How to do it…

How it works…

Handling seasonality – seasonal decomposition

Getting ready

How to do it…

How it works…

Handling non-constant variance – log transformation

Getting ready

How to do it…

How it works…

4

Forecasting with PyTorch Lightning

Technical requirements

Preparing a multivariate time series for supervised learning

Getting ready

How to do it…

How it works…

Training a linear regression model for forecasting with a multivariate time series

Getting ready

How to do it…

How it works…

Feedforward neural networks for multivariate time series forecasting

Getting ready

How to do it…

How it works…

There’s more…

LSTM neural networks for multivariate time series forecasting

Getting ready

How to do it…

How it works…

There’s more…

Monitoring the training process using Tensorboard

Getting ready

How to do it…

How it works…

There’s more…

Evaluating deep neural networks for forecasting

Getting ready

How to do it…

How it works…

There’s more…

Using callbacks – EarlyStopping

Getting ready

How to do it…

How it works…

There’s more…

5

Global Forecasting Models

Technical requirements

Multi-step forecasting with multivariate time series

Getting ready

How to do it…

How it works…

There’s more…

Multi-step and multi-output forecasting with multivariate time series

Getting ready

How to do it…

How it works…

Preparing multiple time series for a global model

Getting ready

How to do it…

How it works…

Training a global LSTM with multiple time series

Getting ready

How to do it…

How it works…

Global forecasting models for seasonal time series

Getting ready

How to do it…

How it works…

There’s more…

Hyperparameter optimization using Ray Tune

Getting ready

How to do it…

How it works…

There’s more…

6

Advanced Deep Learning Architectures for Time Series Forecasting

Technical requirements

Interpretable forecasting with N-BEATS

Getting ready

How to do it…

How it works…

There’s more…

Optimizing the learning rate with PyTorch Forecasting

Getting ready

How to do it…

How it works…

There’s more…

Getting started with GluonTS

Getting ready

How to do it…

How it works…

Training a DeepAR model with GluonTS

Getting ready

How to do it…

How it works…

There’s more…

Training a Transformer model with NeuralForecast

Getting ready

How to do it…

How it works…

There’s more…

Training a Temporal Fusion Transformer with GluonTS

Getting ready

How to do it…

How it works…

There’s more…

Training an Informer model with NeuralForecast

Getting ready

How to do it…

How it works…

There’s more…

Comparing different Transformers with NeuralForecast

Getting ready

How to do it…

How it works…

7

Probabilistic Time Series Forecasting

Technical requirements

Introduction to exceedance probability forecasting

Getting ready

How to do it…

How it works…

There’s more…

Exceedance probability forecasting with an LSTM

Getting ready

How to do it…

How it works…

There’s more…

Creating prediction intervals using conformal prediction

Getting ready

How to do it…

How it works…

Probabilistic forecasting with an LSTM

Getting ready

How to do it…

How it works…

Probabilistic forecasting with DeepAR

Getting ready

How to do it…

How it works…

Introduction to Gaussian Processes

Getting ready

How to do it…

How it works…

Using Prophet for probabilistic forecasting

Getting ready

How to do it…

How it works…

There’s more…

8

Deep Learning for Time Series Classification

Technical requirements

Tackling TSC with K-nearest neighbors

Getting ready

How to do it…

How it works…

There’s more…

Building a DataModule class for TSC

Getting ready

How to do it…

How it works…

Convolutional neural networks for TSC

Getting ready

How to do it…

How it works…

ResNets for TSC

Getting ready

How to do it…

How it works…

Tackling TSC problems with sktime

Getting ready

How to do it…

How it works…

There’s more…

9

Deep Learning for Time Series Anomaly Detection

Technical requirements

Time series anomaly detection with ARIMA

Getting ready

How to do it…

How it works…

There’s more…

Prediction-based anomaly detection using DL

Getting ready

How to do it…

How it works…

There’s more…

Anomaly detection using an LSTM AE

Getting ready

How to do it…

How it works…

Building an AE using PyOD

Getting ready

How to do it…

How it works…

There’s more…

Creating a VAE for time series anomaly detection

Getting ready

How to do it…

How it works…

There’s more…

Using GANs for time series anomaly detection

Getting ready…

How to do it…

How it works…

There’s more…

Index

Other Books You May Enjoy