ap.Abhishek Patel

Search

Search notes, essays, projects, the library and the AI course. Use arrow keys to choose and Enter to open.

Module 29

Sequence Modelling and Multi-IO Architectures

Teach networks to read things in order. You build RNNs, LSTMs and GRUs and see exactly why gates help them remember, forecast daily pastry sales honestly against real baselines, and design models with several inputs and several outputs whose losses are balanced on purpose. The module ends with a multi-input OCR model that reads supplier invoice fields from images plus metadata.

By the end of this module you can

  • explain how an RNN’s hidden state works and why LSTM and GRU gates keep memory and gradients alive
  • build PyTorch sequence models with the right input shapes, gradient clipping and sequence-level outputs
  • forecast a time series with sliding windows, time-based splits and known-in-advance features, and prove it beats naive baselines
  • design multi-input, multi-output models with embeddings, fusion and several heads
  • balance multiple losses by scaling and weighting them, and check the result with per-head metrics and ablations
  • train a CNN plus BiLSTM OCR model with CTC loss and evaluate it with character error rate

Lessons

4 in this module
  1. 01RNNs, LSTMs and GRUsBuild RNN, LSTM and GRU classifiers for proofing-cabinet logs and explain, with numbers, why gated cells remember longer than plain RNNs.30 min
  2. 02Forecasting with RNNsForecast daily croissant sales with an LSTM using sliding windows, time-based splits and known-in-advance features, and prove it beats the store manager’s baseline.35 min
  3. 03Multi-input and multi-output modelsBuild one PyTorch model that fuses a sales sequence, category embeddings and metadata, predicts both units sold and sell-out risk, and balances its two losses on purpose.30 min
  4. 04Project: multi-input models for OCRBuild a multi-input PyTorch OCR model that fuses invoice-field images with supplier and device metadata, reads text with a CTC head, adds an auxiliary field-type head, and proves each design choice with ablations.Project480 min