
Time Series with PyTorch
Description
Alles über E-Books | Antworten auf Fragen rund um E-Books, Kopierschutz und Dateiformate finden Sie in unserem Info- & Hilfebereich.
Neural networks are powerful tools for time-series forecasting, but applying them effectively requires both practical experience and a clear understanding of architectures, training strategies, and evaluation methods. This book brings these ideas together in a structured and practical way. Starting with PyTorch fundamentals, you will build neural networks from scratch and progress through recurrent networks, attention mechanisms, and transformers before exploring forecasting architectures such as N-BEATS, N-HiTS, and the Temporal Fusion Transformer. Along the way, you will learn robust hyperparameter tuning, conformal prediction for uncertainty estimation, and reliable evaluation practices. Unlike most forecasting books, this text also explores topics often overlooked or treated separately, including transfer learning across collections of series, synthetic data generation with diffusion models, and self-supervised representation learning. Beyond forecasting, later chapters cover classification, clustering, anomaly detection, and embeddings for large-scale time-series modeling. Throughout, the focus is pragmatic: theory is reinforced through experimentation and implementation so you can apply these methods confidently to real-world time-series problems.
All prices
More details
Content
- Cover
- Title Page
- Copyright and Credits
- Dedication
- Acknowledgments
- Contributors
- Table of Contents
- Preface
- To get the most out of this book
- Chapter 1: Time Series for Everyone
- Why time series?
- The early period
- The classical era
- The promise of deep learning
- From language to time
- Forecasting and performance
- Summary
- Get this book's PDF version and more
- Chapter 2: The Challenge of Time Series
- What is time-series data?
- Missing data
- Types of missing data
- Simple imputations
- MICE imputation
- Theoretical foundations of time series analysis
- Patterns in time
- Decomposition
- Additive decomposition
- Multiplicative decomposition
- Alternative decompositions
- Examples of decomposition
- Seasonality plotting
- Beyond decomposition patterns
- Dependence in time series
- Autocorrelation function
- Partial autocorrelation
- Stationarity
- Passengers' mean and variation split check
- Tests for stationarity
- Applying KPSS
- Time series structures
- Univariate
- Multivariate
- Multivariable
- Panel data
- Application of structures to models
- Summary
- Recommended reading
- Join our community on Discord
- Chapter 3: Evaluating Time-Series Models
- Why we evaluate
- Using validation to manage complexity
- Partitioning data
- Introducing the dataset
- ACF and PACF plots
- Conducting residual analysis
- Fixed-origin design
- Train-test split
- Train-validation-test split
- Cross-validation
- Expanding windows
- Rolling windows
- Error metrics
- Intrinsic metrics
- Absolute error
- Absolute percentage error (APE)
- Squared error
- Variations
- Extrinsic metrics
- Grouped error metrics
- Multivariate forecasting
- Which to use and when
- Length of evaluation
- Data leakage
- Transformation-based leakage
- Lookforward bias
- Panel data leakage
- Summary
- Recommended reading
- Get this book's PDF version and more
- Chapter 4: PyTorch Fundamentals
- Introduction to PyTorch
- Working with tensors
- Stride
- Basic tensor construction
- Understanding computational graphs
- Chain rule revisited
- Backpropagation calculations
- A brief look at autograd
- Practicing PyTorch fundamentals
- Pure PyTorch neural network
- Lightning NN
- Summary
- Recommended reading
- Join our community on discord
- Chapter 5: Simple Neural Architecture
- Basic structures of neural networks
- Artificial neurons
- Neural nets
- From scalars to matrices
- Forward propagation
- Loss calculation
- Backpropagation
- Building a neural network
- Summary
- Recommended reading
- Get this book's PDF version and more
- Chapter 6: Optimization
- Optimization costs
- Optimization of neural networks
- Understanding activation functions
- Taxonomy
- Layer-wise activation functions
- Fixed-shape activation functions
- Sigmoid
- Tanh
- ReLU
- Trainable activation functions
- Comparing activation functions
- Hidden layers
- Gradient descent, loss functions, and regularization techniques
- Loss functions
- Optimizing hyperparameters
- Learning rate scheduling
- Epochs
- Batch size
- Dropout
- Weight decay
- Data splitting for neural networks
- Approaches to splitting
- Hyperparameter tuning
- Summary
- Recommended reading
- Join our community on discord
- Chapter 7: Conformal Prediction
- Uncertainty quantification
- Understanding conformal prediction
- Intuition behind conformal prediction
- Improving conformal intervals
- Conformal intervals with quartiles
- Mathematical notation
- Approaches to splitting
- Conformalized regression
- Conformalized forecasting
- Working with EnbPI
- Applying EnbPI to our PyTorch model
- Evaluating conformal interval quality
- Summary
- Recommended reading
- Get this book's PDF version and more
- Chapter 8: Recurrent Neural Networks
- Time-series data and states
- Swing angle forecasting
- Why recurrent models help
- Introducing RNNs
- Simple RNN
- Theoretical background
- RNNs and differential equations
- Implementation
- Introducing LSTM
- Introducing GRUs
- Stacking
- Forecasting using RNNs
- Summary
- Recommended reading
- Chapter 9: Transformers
- The vanilla transformer
- Encoder-decoder
- Attention mechanism
- Knowledge of temporal information
- Implementation of transformers
- The M5 competition
- Summary
- Recommended reading
- Get this book's PDF version and more
- Chapter 10: Other Neural Structures
- Setting up our M5 dataset
- Exploring some neural network families
- Multilayer perceptron
- N-BEATS
- N-HITS
- Convolutional Neural Networks
- Graph neural networks
- Kolmogorov-Arnold networks
- Foundation models
- Summary
- Recommended reading
- Join our community on Discord
- Chapter 11: Transfer Learning and Global Modelling
- What is transfer learning?
- Types of transfer learning
- Applications of transfer learning
- Structuring time series data for transfer learning
- Temporal windowing and sequential organization
- Scale normalization and feature transformation
- Temporal feature engineering
- Global modeling
- Building GFMs with PyTorch
- Feature integration mechanisms
- Data organization and batching
- Training and balanced sampling
- Optimizers, learning rate scheduling, and batching
- Transfer learning with NeuralForecast
- Data preparation
- Statistical baselines
- Decision-tree global models
- Neural network GFMs
- Pretraining with external data
- Summary
- Recommended reading
- Get this book's PDF version and more
- Chapter 12: Synthetic Time Series Data
- The data-generating process
- Data-driven synthetic time series
- Generating time series data using variational autoencoders
- Implementing TimeVAE
- Implementing the model
- Training the model
- Generating synthetic data
- Beyond VAE
- Summary
- Recommended reading
- Join our community on discord
- Chapter 13: Diffusion Models
- Introduction to probabilistic forecasting
- Diffusion as a real-world phenomenon
- Simulating the diffusion process
- Naive diffusion model applied on time series data
- Denoising diffusion model
- Summary
- Recommended reading
- Get this book's PDF version and more
- Chapter 14: Time Series Classification
- Types of time-series comparisons
- Distance-based measures
- Norms
- Dynamic time warping
- Retrieving alignment paths
- Applied distances
- Elastic ensemble
- Proximity forest
- Comparing distance methods
- Feature-based algorithms
- Features built-in
- Interpreting features
- Building features
- Shapelets
- Dictionary-based classification
- Convolution-based classification
- Deep learning approaches
- Convolutional neural networks
- ResNet
- InceptionTime
- H-InceptionTime
- LiteTime
- Summary
- Recommended reading
- Join our community on discord
- Chapter 15: Time Series Clustering
- What is clustering?
- Preprocessing for time series clustering
- Defining time series clustering
- The TSCL pipeline
- Clustering approaches
- Distance-based
- Distribution-based
- Subsequence-based
- Representation learning
- Deep-learning approaches to TSCL
- Two-stage pipeline
- End-to-end neural clustering
- Applying featurization
- Data preparation
- Feature extraction
- Scaling
- Selecting the number of clusters
- Building GFMs with cluster labels
- Denoising with an autoencoder
- Autoencoder hyperparameters
- Evaluating clustering results
- Summary
- Recommended reading
- Get this book's PDF version and more
- Chapter 16: Embeddings for Time Series
- A dynamical systems perspective
- Learned embeddings
- The diversity of time series embeddings
- Summary
- Recommended reading
- Join our community on discord
- Chapter 17: Supervised and Unsupervised Anomaly Detection
- What is an outlier or anomaly?
- Evaluating TSAD systems
- Rule-based approaches
- Adaptive thresholds
- Statistical profiling
- Building profiles
- Residuals as the detection signal
- The One-Class gaussian
- Isolation forest
- Isolation forest - unsupervised
- Standard isolation forest on residuals
- Extended isolation forest
- Local outlier factor
- Matrix profile
- Application to residuals
- Multidimensional matrix profile
- Choosing the window length
- Matrix profile vs. Point-Based methods
- Alternative approaches
- AB-Join: comparing against a reference period
- Window-Overlap evaluation
- Where matrix profile fits
- A comparative summary
- Supervised anomaly detection
- The label quality problem
- Class imbalance
- Gradient boosting on residual features
- Threshold adjustment
- Forecast-First anomaly detection
- The pipeline
- The iteration loop
- Supervised extension
- Composability in practice
- Library ecosystem
- Summary
- Recommended reading
- Get this book's PDF version and more
- Chapter 18: Self-Supervised Learning for Time Series
- Why do we need representations of time series?
- Self-supervised learning
- Contrastive predictive coding
- Data preparation
- Model implementation
- Training preparation
- Training and evaluation
- Summary
- Recommended reading
- Join our community on discord
- Chapter 19: Unlock Your Exclusive Benefits
- Unlock this Book's Free Benefits in 3 Easy Steps
- Other Books You May Enjoy
- Index
Contents
- Acknowledgments
- Preface
- Time Series for Everyone
- The Challenge of Time Series
- Evaluating Time-Series Models
- PyTorch Fundamentals
- Simple Neural Architecture
- Optimization
- Conformal Prediction
- Recurrent Neural Networks ...
System requirements
File format: ePUB
Copy protection: Adobe-DRM (Digital Rights Management)
System requirements:
- Computer (Windows; MacOS X; Linux): Install the free reader Adobe Digital Editions prior to download (see eBook Help).
- Tablet/smartphone (Android; iOS): Install the free app Adobe Digital Editions or the app PocketBook before downloading (see eBook Help).
- E-reader: Bookeen, Kobo, Pocketbook, Sony, Tolino and many more (not Kindle).
The file format ePub works well for novels and non-fiction books – i.e., „flowing” text without complex layout. On an e-reader or smartphone, line and page breaks automatically adjust to fit the small displays.
This eBook uses Adobe-DRM, a „hard” copy protection. If the necessary requirements are not met, unfortunately you will not be able to open the eBook. You will therefore need to prepare your reading hardware before downloading.
Please note: We strongly recommend that you authorise using your personal Adobe ID after installation of any reading software.
For more information, see our ebook Help page.
File format: ePUB
Copy protection: without DRM (Digital Rights Management)
System requirements:
- Computer (Windows; MacOS X; Linux): Use a reader that can handle the file format ePUB, such as Adobe Digital Editions or FBReader – both free (see eBook Help).
- Tablet/Smartphone (Android; iOS): Install the free app Adobe Digital Editions or the app PocketBook (see eBook Help).
- E-reader: Bookeen, Kobo, Pocketbook, Sony, Tolino and many more (not Kindle).
The file format ePUB works well for novels and non-fiction books – i.e., 'flowing' text without complex layout. On an e-reader or smartphone, line and page breaks automatically adjust to fit the small displays.
This eBook does not use copy protection or Digital Rights Management
For more information, see our eBook Help page.