100% found this document useful (1 vote)
71 views

Deep Learning with Python 2nd Edition Nikhil Ketkar download pdf

Deep

Uploaded by

pachosletfi
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
100% found this document useful (1 vote)
71 views

Deep Learning with Python 2nd Edition Nikhil Ketkar download pdf

Deep

Uploaded by

pachosletfi
Copyright
© © All Rights Reserved
Available Formats
Download as PDF, TXT or read online on Scribd
You are on page 1/ 40

Experience Seamless Full Ebook Downloads for Every Genre at ebookmeta.

com

Deep Learning with Python 2nd Edition Nikhil


Ketkar

https://ebookmeta.com/product/deep-learning-with-python-2nd-
edition-nikhil-ketkar/

OR CLICK BUTTON

DOWNLOAD NOW

Explore and download more ebook at https://ebookmeta.com


Recommended digital products (PDF, EPUB, MOBI) that
you can download immediately if you are interested.

Deep Learning with Python 1st Edition Nikhil Ketkar

https://ebookmeta.com/product/deep-learning-with-python-1st-edition-
nikhil-ketkar/

ebookmeta.com

Fundamentals of Deep Learning Nikhil Buduma

https://ebookmeta.com/product/fundamentals-of-deep-learning-nikhil-
buduma/

ebookmeta.com

Applied Deep Learning with TensorFlow 2: Learn to


Implement Advanced Deep Learning Techniques with Python,
2nd Edition Umberto Michelucci
https://ebookmeta.com/product/applied-deep-learning-with-
tensorflow-2-learn-to-implement-advanced-deep-learning-techniques-
with-python-2nd-edition-umberto-michelucci-2/
ebookmeta.com

Accounting for Goodwill and Other Intangible Assets 1st


Edition Mark L. Zyla

https://ebookmeta.com/product/accounting-for-goodwill-and-other-
intangible-assets-1st-edition-mark-l-zyla/

ebookmeta.com
Beautiful Fiend An enemies to lovers dark romance North
Shore Stories Book 1 1st Edition Lola King

https://ebookmeta.com/product/beautiful-fiend-an-enemies-to-lovers-
dark-romance-north-shore-stories-book-1-1st-edition-lola-king/

ebookmeta.com

John Locke and Agrarian Capitalism Neal Wood

https://ebookmeta.com/product/john-locke-and-agrarian-capitalism-neal-
wood/

ebookmeta.com

The Battle for Syria International Rivalry in the New


Middle East Christopher Phillips

https://ebookmeta.com/product/the-battle-for-syria-international-
rivalry-in-the-new-middle-east-christopher-phillips/

ebookmeta.com

Fangs For the Memories Haunted Singles Weekend 1st Edition


Banks Tamrin

https://ebookmeta.com/product/fangs-for-the-memories-haunted-singles-
weekend-1st-edition-banks-tamrin/

ebookmeta.com

50 Strategies for Teaching English Language Learners


Adrienne L Herrell Michael Jordan

https://ebookmeta.com/product/50-strategies-for-teaching-english-
language-learners-adrienne-l-herrell-michael-jordan/

ebookmeta.com
Unit Cohesion and Warfare in the Ancient World Military
and Social Approaches 1st Edition Joshua R. Hall

https://ebookmeta.com/product/unit-cohesion-and-warfare-in-the-
ancient-world-military-and-social-approaches-1st-edition-joshua-r-
hall/
ebookmeta.com
Nikhil Ketkar and Jojo Moolayil
Deep Learning with Python
Learn Best Practices of Deep Learning Models with
PyTorch
2nd ed.
Nikhil Ketkar
Bangalore, Karnataka, India

Jojo Moolayil
Vancouver, BC, Canada

Any source code or other supplementary material referenced by the


author in this book is available to readers on GitHub via the book’s
product page, located at www.​apress.​com/​978-1-4842-5363-2. For
more detailed information, please visit http://​www.​apress.​com/​
source-code.

ISBN 978-1-4842-5363-2 e-ISBN 978-1-4842-5364-9


https://doi.org/10.1007/978-1-4842-5364-9

© Nikhil Ketkar, Jojo Moolayil 2021

Apress Standard

Trademarked names, logos, and images may appear in this book. Rather
than use a trademark symbol with every occurrence of a trademarked
name, logo, or image we use the names, logos, and images only in an
editorial fashion and to the benefit of the trademark owner, with no
intention of infringement of the trademark. The use in this publication
of trade names, trademarks, service marks, and similar terms, even if
they are not identified as such, is not to be taken as an expression of
opinion as to whether or not they are subject to proprietary rights.

The publisher, the authors and the editors are safe to assume that the
advice and information in this book are believed to be true and accurate
at the date of publication. Neither the publisher nor the authors or the
editors give a warranty, express or implied, with respect to the material
contained herein or for any errors or omissions that may have been
made. The publisher remains neutral with regard to jurisdictional
claims in published maps and institutional affiliations.

Distributed to the book trade worldwide by Springer Science+Business


Media New York, 233 Spring Street, 6th Floor, New York, NY 10013.
Phone 1-800-SPRINGER, fax (201) 348-4505, e-mail orders-
ny@springer-sbm.com, or visit www.springeronline.com. Apress Media,
LLC is a California LLC and the sole member (owner) is Springer
Science + Business Media Finance Inc (SSBM Finance Inc). SSBM
Finance Inc is a Delaware corporation.
Introduction
This book has been drafted with a unique approach. The second edition
focuses on the practicality of the topics within deep learning that help
the reader to embrace modern tools with the right mathematical
foundations. The first edition focused on introducing a meaningful
foundation for the subject, while limiting the depth of the practical
implementations. While we explored a breadth of technical frameworks
for deep learning (Theano, TensorFlow, Keras, and PyTorch), we limited
the depth of the implementation details. The idea was to distill the
mathematical foundations while focusing briefly on the practical tools
used for implementation.
A lot has changed over the past three years. The deep learning
fraternity is now stronger than ever, and the frameworks have evolved
in size and adoption. Theano is now deprecated (ceased development);
TensorFlow saw huge adoption in the industry and academia; and
Keras became more popular among beginners and deep learning
enthusiasts. However, PyTorch has emerged recently as a widely
popular choice for academia as well as industry. The growing number
of research publications that recently have used PyTorch over
TensorFlow is a testament to its growth within deep learning.
On the same note, we felt the need to revise the book with a focus
on engaging readers with hands-on exercises to aid a more meaningful
understanding of the subject. In this book, we have struck the perfect
balance, with mathematical foundations as well as hands-on exercises,
to embrace practical implementation exclusively on PyTorch. Each
exercise is supplemented with the required explanations of PyTorch’s
functionalities and required abstractions for programming
complexities.
Part I serves as a brief introduction to machine learning, deep
learning, and PyTorch. We explore the evolution of the field, from early
rule-based systems to the present-day sophisticated algorithms, in an
accelerated fashion.
Part II explores the essential deep learning building blocks. Chapter
3 introduces a simple feed-forward neural network. Incrementally and
logically, we uncover the various building blocks that constitute a
neural network and which can be reused in building any other network.
Though foundational, Chapter 3 focuses on building a baby neural
network with the required framework that helps to construct and train
networks of all kinds and complexities. In Chapter 4, we explore the
core idea that enabled the possibility of training large networks
through backpropagation using automatic differentiation and chain
rule. We explore PyTorch’s Autograd module with a small example to
understand how the solution works programmatically. In Chapter 5, we
look at orchestrating all the building blocks discussed through so far,
along with the performance metrics of deep learning models and the
artifacts required to enable an improved means for training—i.e.,
regularization, hyperparameter tuning, overfitting, underfitting, and
model capacity. Finally, we leverage all this content to develop a deep
neural network for a real-life dataset using PyTorch. In this exercise, we
also explore additional PyTorch constructs that help in the
orchestration of various deep learning building blocks.
Part III covers three important topics within deep learning. Chapter
6 explores convolutional neural networks and introduces the field of
computer vision. We explore the core topics within convolutional
neural networks, including how they learn and how they are
distinguished from other networks. We also leverage a few hands-on
exercises—using a small MNIST dataset as well as the popular Cats and
Dogs dataset—to study the practical implementation of a convolutional
neural network. In Chapter 7, we study recurrent neural networks and
enter the field of natural language processing. Similar to Chapter 6, we
incrementally build an intuition around the fundamentals and later
explore practical exercises with real-life datasets. Chapter 8 concludes
the book by looking at some of the recent trends within deep learning.
This chapter is only a cursory introduction and does not include any
implementation details. The objective is to highlight some advances in
the research and the possible next steps for advanced topics.
Overall, we have put in great efforts to write a structured, concise,
exercise-rich book that balances the coverage between the
mathematical foundations and the practical implementation.
Acknowledgments
I would like to thank my colleagues at Flipkart and Indix, and the
technical reviewers, for their feedback and comments. I will also like to
thank Charu Mudholkar for proofreading the book in its final stages.

—Nikhil Ketkar

I would like to thank my beloved wife, Divya, for her constant


support.

—Jojo Moolayil
Table of Contents
Chapter 1:​Introduction to Machine Learning and Deep Learning
Defining Deep Learning
A Brief History
Advances in Related Fields
Prerequisites
The Approach Ahead
Installing the Required Libraries
The Concept of Machine Learning
Binary Classification
Regression
Generalization
Regularization
Summary
Chapter 2:​Introduction to PyTorch
Why Do We Need a Deep Learning Framework?​
What Is PyTorch?​
Why PyTorch?​
It All Starts with a Tensor
Creating Tensors
Tensor Munging Operations
Mathematical Operations
Element-Wise Mathematical Operations
Trigonometric Operations in Tensors
Comparison Operations for Tensors
Linear Algebraic Operations
Summary
Chapter 3:​Feed-Forward Neural Networks
What Is a Neural Network?​
Unit
The Overall Structure of a Neural Network
Expressing a Neural Network in Vector Form
Evaluating the Output of a Neural Network
Training a Neural Network
Deriving Cost Functions Using Maximum Likelihood
Binary Cross-Entropy
Cross-Entropy
Squared Error
Summary of Loss Functions
Types of Activation Functions
Linear Unit
Sigmoid Activation
Softmax Activation
Rectified Linear Unit
Hyperbolic Tangent
Backpropagation
Gradient Descent Variants
Gradient-Based Optimization Techniques
Practical Implementation with PyTorch
Summary
Chapter 4:​Automatic Differentiation in Deep Learning
Numerical Differentiation
Symbolic Differentiation
Automatic Differentiation Fundamentals
Implementing Automatic Differentiation
Summary
Chapter 5:​Training Deep Leaning Models
Performance Metrics
Classification Metrics
Regression Metrics
Data Procurement
Splitting Data for Training, Validation, and Testing
Establishing the Achievable Limit on the Error Rate
Establishing the Baseline with Standard Choices
Building an Automated, End-to-End Pipeline
Orchestration for Visibility
Analysis of Overfitting and Underfitting
Hyperparameter Tuning
Model Capacity
Regularizing the Model
Early Stopping
Norm Penalties
Dropout
A Practical Implementation in PyTorch
Interpreting the Business Outcomes for Deep Learning
Summary
Chapter 6:​Convolutional Neural Networks
Convolution Operation
Pooling Operation
Convolution-Detector-Pooling Building Block
Stride
Padding
Batch Normalization
Filter
Filter Depth
Number of Filters
Summarizing key learnings from CNNs
Implementing a basic CNN using PyTorch
Implementing a larger CNN in PyTorch
CNN Thumb Rules
Summary
Chapter 7:​Recurrent Neural Networks
Introduction to RNNs
Training RNNs
Bidirectional RNNs
Vanishing and Exploding Gradients
Gradient Clipping
Long Short-Term Memory
Practical Implementation
Summary
Chapter 8:​Recent Advances in Deep Learning
Going Beyond Classification in Computer Vision
Object Detection
Image Segmentation
Pose Estimation
Generative Computer Vision
Natural Language Processing with Deep Learning
Transformer Models
Bidirectional Encoder Representations from Transformers
GrokNet
Additional Noteworthy Research
Concluding Thoughts
Index
About the Authors
Nikhil Ketkar
currently leads the Machine Learning
Platform team at Flipkart, India’s largest
ecommerce company. He received his
PhD from Washington State University.
Following that, he conducted
postdoctoral research at University of
North Carolina at Charlotte, which was
followed by a brief stint in high-
frequency trading at TransMarket in
Chicago. More recently, he led the data
mining team at Guavus, a startup doing
big data analytics in the telecom domain,
and Indix, a startup doing data science in the ecommerce domain. His
research interests include machine learning and graph theory.

Jojo Moolayil
is an artificial intelligence professional
and published author of three books on
machine learning, deep learning, and IoT.
He is currently working with Amazon
Web Services as a Research Scientist –
A.I. in their Vancouver, BC office.
In his current role with AWS, Jojo
works on researching and developing
large-scale A.I. solutions for combating
fraud and enriching the customer’s
payment experience in the cloud. He is
also actively involved as a technical
reviewer and AI consultant with leading
publishers and has reviewed over a
dozen books on machine learning, deep
learning, and business analytics.
You can reach Jojo at:
https://www.jojomoolayil.com/
https://www.linkedin.com/in/jojo62000
https://twitter.com/jojo62000
Other documents randomly have
different content
The Project Gutenberg eBook of Letters from the
peninsula, 1808-1812
This ebook is for the use of anyone anywhere in the United
States and most other parts of the world at no cost and with
almost no restrictions whatsoever. You may copy it, give it away
or re-use it under the terms of the Project Gutenberg License
included with this ebook or online at www.gutenberg.org. If you
are not located in the United States, you will have to check the
laws of the country where you are located before using this
eBook.

Title: Letters from the peninsula, 1808-1812

Author: Sir William Warre

Editor: Edmond Warre

Release date: March 30, 2024 [eBook #73292]

Language: English

Original publication: London: John Murray, 1909

Credits: MWS and the Online Distributed Proofreading Team at


https://www.pgdp.net (This file was produced from
images generously made available by The Internet
Archive/Canadian Libraries)

*** START OF THE PROJECT GUTENBERG EBOOK LETTERS


FROM THE PENINSULA, 1808-1812 ***
LETTERS FROM THE
PENINSULA
Lt. General Sir William Warre C.B., K.T.S.

From the miniature by J.C.D. Engleheart in the possession of the Rev. Canon
Warre

Emery Walker, Ph.sc.

LETTERS FROM THE


PENINSULA
1808-1812

BY LIEUT.-GEN. SIR WILLIAM WARRE


C.B., K.T.S.

EDITED BY HIS NEPHEW


THE REV. EDMOND WARRE, D.D., C.B., M.V.O.

WITH FRONTISPIECE AND MAP


LONDON
JOHN MURRAY, ALBEMARLE STREET, W.
1909
PREFACE
Some years before his death in 1875, my father entrusted to me a
packet containing letters written by his eldest brother, my uncle, Sir
William Warre, from the Peninsula during his service there from 1808
to 1812.
The packet was not opened by me until the year 1908.
The letters, on perusal, seemed to be of interest, as giving a
graphic description of the life and opinions of an officer serving on
the Staff during the Peninsular War, and, in particular, of one
immediately concerned in the organisation of the Portuguese army.
Moreover, the letters, which are written on the spot and without
reserve, being chiefly addressed to his father or mother, seem to
reflect in some measure, as regards the campaign, and as to home
politics, to which there are plentiful allusions, the conversation and
opinions of the Headquarters’ Staff at the time; and further, the
intimate acquaintance of the writer with the Portuguese character,
and with the methods of the Portuguese Government, enhances the
illustration of the difficulties which had to be overcome in the effort of
Great Britain to save her ally from the crushing yoke of French
imperial despotism.
Mr James Warre of Oporto, the father of Sir William Warre, was a
man of great ability, and of influence both in Portugal and at home.
He was a partner in the firm of Warre & Co., which was at the time
one of the leading commercial houses in Oporto—an old firm,
established in the seventeenth century—with which, however, the
family connection was severed at the death of Sir William Warre’s
brother George, in the year 1850.
The letters themselves, considering the circumstances under
which they were written, are very fairly legible; but in places there
are lacunæ which are sometimes difficult to fill up. The orthography
is not at all consistent—often old-fashioned, sometimes faulty. I have
corrected it in some places, but in many have left it as in the original.
I cannot claim to have any particular knowledge of military history,
and, as regards the brief introductions to the several chapters, wish
to acknowledge in limine my indebtedness to Napier’s great work, to
Professor Oman’s three most interesting volumes, which bring the
story of the war down to 1810, and to Sir Herbert Maxwell’s Life of
the Duke of Wellington.
I am indebted also to my cousin, Mr George Warre, for help in
translating the Portuguese words and phrases that occur in the
letters.
My thanks are also due to my cousin, Mrs Wm. Rathbone, for
kindly allowing me to use several of the collection of family letters in
her possession, extracts from which help to fill up some of the gaps
in the correspondence.
Lastly, I must acknowledge my debt of gratitude to my friend and
publisher, Mr John Murray, for his most valuable help in many ways.
Without his assistance, the map which illustrates the volume could
not have been constructed.
EDMOND WARRE.
Finchampstead, 1909.
LIST OF LETTERS
PAGE

1808
CHAPTER I
Portsmouth, May 22 3
H.M.S. Resistance, St Helens, May 24 4
Cove, June 8 5
Cove, June 17 8
Cove, June 22 11
Cove, June 27 41
1808
CHAPTER II
Porto Roads, July 25 19
Off Ovar, Monday evening, July 25 20
Camp Lavos, near Figueira, Aug. 8 21
Lourinhao, 12 miles south of Peniche, Aug. 19 24
Vimiero, Aug. 22 25
Buenos Ayres, Lisbon, Sept. 27 28
Lisbon, Sept. 29 36
1808-9
CHAPTER III
Avanilla, near Sahagun, 5½ leagues from Saldaña, half-past
5 p.m., Dec. 23, 1808 46
Sobrado, between Lugo and St Jago, Jan. 4, 1809 48
Barfleur, at sea, Jan. 18 50
Plymouth, Jan. 23 51
Lisbon, March 3 53
Lisbon, April 1 56
Undated (?) April 7 59
Headquarters, Thomar, April 27 60
Lisbon, July 13—arrived Aug. 24, per Colonel Brown 66
Lacebo, Aug. 10—Los Hoyos, Aug. 13 68
Salvaterra, Aug. 18—Castello Branco, Aug. 20 71
Headquarters, Lisbon, Sept. 6 77
Headquarters, Lisbon, Sept. 11 81
Lisbon, Sept. 25 85
Lisbon, Oct. 10 86
Lisbon, Oct. 26 90
Lisbon, Oct. 26 93
Lisbon, Dec. 1 95
Thomar, Dec. 31 97
1810
CHAPTER IV
Lisbon, Feb. 6 104
Lisbon, Feb. 17 108
Lisbon, March 10 112
Coimbra, March 21 115
Coimbra, March 30 117
Headquarters, Mango Aide, May 3 119
Fornos d’Algodres, May 9 (extract from letter to Sister) 123
Headquarters, Fornos d’Algodres, May 15 125
Headquarters, Fornos d’Algodres, May 23 130
Extract (London, June 20), Fornos, June 6 132
Extract (Hendon, July 8), Fornos, June 13 133
Headquarters, Fornos d’Algodres, June 20 134
Headquarters, P.A., Francoso, near Pinhel, June 27 137
Francoso, July 9 139
Francoso, July 10 151
Francoso, July 25 154
Lagiosa, Aug. 8 156
Lagiosa, Aug. 22 158
Lagiosa, Aug. 29 162
Lagiosa, Aug. 29, 6 p.m. 166
Hendon Place, Oct. 2 167
Hendon Place, Oct. 16 (extract, news of Bussaco, Sept. 27) 168
Hendon Place, Oct. 25 (referring to letter Oct. 6) 169
Headquarters, P.A., Casal Eschin, a mile to the eastward of
Enxara dos Cavaleiros, 5 leagues from Lisbon, Oct. 20 171
Extract, Falmouth, Nov. 14 175
Extract, Honiton, Nov. 18 177
1811
CHAPTER V
Portsmouth, May 5 180
Portsmouth, May 7 181
Portsmouth, May 9 183
Headquarters, St Olaia, June 20 184
Headquarters, St Olaia, June 27 188
Headquarters, St Olaia, July 1 191
Lisbon, July 5 192
Lisbon, Aug. 2 192
Cintra, Aug. 17 195
Cintra, Aug. 23 198
Cintra, Sept. 7 202
Lisbon, Oct. 17 205
Lisbon, Nov. 23 209
Lisbon, Nov. 30 212
Lisbon, Dec. 6 213
Lisbon, Dec. 14 216
1812
CHAPTER VI
January to September
Torres Novas, Jan. 4 221
Coimbra, Jan. 10 222
Gallegos, Jan. 20 223
Elvas, March 6, extract 226
Elvas, March 18 229
Camp before Badajos, March 20 234
Camp before Badajos, March 29-(April 3), extract 235
Camp before Badajos, April 2 236
Badajos Camp, April 7 241
Camp before Badajos, April 10 247
Nava, on the road between Sabugal and Alfaiates, April 24 248
Fuente Guinaldo, May 20, extract 252
Fuente Guinaldo, May 28 254
Salamanca, June 17 258
Salamanca, June 25 262
Villa Escusa, Province of Toro, June 30 269
La Seca, Province of Valladolid, July 7 274
La Seca, July 10, extract 278
La Seca, July 13 279
Salamanca, July 24 284
Salamanca, July 27 292
Salamanca, Aug. 29, extract 295
(?) Salamanca, Sept. 2, extract 297
CHRONOLOGICAL TABLE OF
EVENTS

1807.
Nov. French Conquest of Portugal.
Nov. 30. Junot occupies Lisbon.
Portuguese Royal Family fly to Brazil.
1808.
May. Napoleon makes Joseph Buonaparte King of
Spain.
Outbreak of Spanish insurrection.
June. French invade Valencia and Andalusia.
Siege of Saragossa.
July 14. Battle of Medina del Rio Seco.
” 20. Capitulation of Baylen.
Aug. 1-4. Landing of British army in Portugal.
” 17. Combat of Roliça.
” 21. Battle of Vimiero.
” 30. Convention of Cintra.
Oct. Napoleon’s invasion of Spain.
Oct. 6. Sir John Moore takes command of British troops
in Portugal.
Nov. 13. Moore at Salamanca.
” 23. Battle of Tudela. Spaniards defeated.
Dec. 4. Napoleon arrives at Madrid.
” 15. Soult with 15,000 men at Saldaña.
” 20. Moore reaches Mayorga; junction with Baird.
” 21. Combat of Sahagun.
” 22. Napoleon’s pursuit of Moore begins.
” 23. Avanilla, near Sahagun, 5½ leagues from
Saldaña, half-past 5 p.m.—orders to march
on Saldaña, 6 p.m.; news received about 7
p.m. of Napoleon’s advance; Moore resolves
on and orders retreat.
” 28. Benavente.
” 29. Astorga.
” 31. Bembibre.
Napoleon leaves the pursuit to Soult and returns
to France.
1809.
Jan. Retreat of Sir John Moore’s army continued.
Jan. 2. Bembibre.
” 3. Villa Franca.
” 6. Rearguard finds army at Lugo in position.
” 8-9. Lugo evacuated.
” 9-10. Betanzos.
” 11. Corunna—no transports.
” 14. Transports arrive.
” 16. Battle of Corunna.
” 17. Embarkation completed.
” 18. H.M.S. Barfleur sails from Corunna.
” 23. Arrives Plymouth.
Feb. 20. Fall of Saragossa.
Feb. (end). Beresford appointed to command Portuguese
army.
March (early). Beresford arrives at Lisbon.
March 10-20. Soult’s operations in Portugal; capture of Oporto.
” 29. Battle of Medellin—Spaniards defeated.
April 22. Sir A. Wellesley arrives in Lisbon.
May 12-22. Oporto retaken; Soult’s retreat to Orense and
Lugo.
June. Advance of British army from Abrantes.
July 27-28. Battle of Talavera.
Aug. 4. Wellesley retires on Badajos.
Oct. 18. Battle of Tamames—French defeated.
Nov. 19. Battle of Ocaña—Spaniards defeated.
” 29. Battle of Alba de Tormes—Spaniards defeated.
1810.
Jan. Lord Wellington retires into Portugal.
Jan. and Feb. The French invade Andalusia.
Feb. 1. King Joseph enters Seville.
Siege of Cadiz.
” 12. Badajos summoned by Mortier.
March to April 22. Siege of Astorga.
May to July 9. Siege of Ciudad Rodrigo.
July 24. Combat of the Coa.
July to Aug. 27. Siege of Almeida.
Sept. 16. Masséna advances into Portugal.
” 27. Battle of Bussaco.
Oct. 1-9. Wellington retires within the lines of Torres
Vedras.
Oct. to Nov. Masséna before the lines.
Nov. 14. Masséna retreats to Santarem.
Dec. 21. Soult moves northward to support Masséna.
1811.
Jan. 27. Soult invests Badajos.
March 5. Masséna leaves Santarem.
” 11. Surrender of Badajos; Soult returns to the South.
” 15. Foz d’Aronce.
” 29. The Allies take Guarda.
April 3. Combat of Sabugal.
Masséna leaves Portugal.
” 20. Wellington to the Alemtejo.
May 2. Masséna resumes the offensive.
” 4. Beresford lays siege to Badajos.
” 5. Battle of Fuentes d’Onoro.
” 8. Masséna retreats; is removed from command.
” 10. Brennier escapes with garrison from Almeida.
” 12. Soult raises the siege of Badajos.
” 16. Battle of Albuera.
King Joseph leaves Madrid.
Marmont takes command of the army of
Portugal.
” 25. Reinvestment of Badajos.
June 12. Siege raised the second time.
The French retire from Estremadura.
Aug. 8. Wellington blockades Ciudad Rodrigo.
Sept. 21. Marmont advances to relieve Ciudad Rodrigo.
” 24. Action at El Bodon.
” 25-27. The Allies retreat, and take up position covering
the line of the Coa.
” 27. The French withdrawal—Marmont to Talavera,
Dorsenne to Salamanca.
Ciudad Rodrigo again invested.
The British army goes into cantonments on the
Coa.
Marmont concentrates near Toledo.
1812.
Jan. 8. Siege of Ciudad Rodrigo.
” 19. Taking of Ciudad Rodrigo by storm.
March 16. Siege of Badajos.
April 6-7. Taking of Badajos.
May 18. Hill destroys bridge at Almaraz.
June. Wellington advances into Castille.
June 17. Allies enter Salamanca.
” 27. Forts at Salamanca taken.
July 22. Battle of Salamanca—Beresford severely
wounded.
Aug. 12. Allies enter Madrid.
Sept. Siege of Burgos.
Oct. Retreat from Burgos.
Nov. Winter quarters near Ciudad Rodrigo.
MEMOIR OF WILLIAM WARRE
William Warre, the subject of this Memoir, was the eldest son of
James Warre of Oporto, and Eleanor, née Greg, his wife. He was
born at Oporto, 15th April 1784, and spent most of his childhood
there. He was sent to Harrow, but seems to have left early, and to
have been placed in the office of Messrs Warre & Co., of which his
uncle, William Warre, was the senior partner, in order that he might
learn the business which both his uncle and his father desired him to
follow.
But his own strong wish was to be a soldier, and, as it turned out,
a piece of mischief achieved that which arguments and entreaties
had failed to obtain. One day in the office, when letters had to be got
ready for the mail, the duty of sealing them, in which, after the
fashion of the day much wax, red or black, was consumed, devolved
upon the young clerk, who, observing that the pigtail of Pedro Alves,
the Portuguese member of the firm, had lapped over to his side of
the desk, while the old gentleman was enjoying a peaceful post-
prandial slumber, felt moved to play a practical joke, which had
momentous consequences. He poured the red wax upon the ribbon
of the pigtail, fastening it to the desk, sealed it with the seal of the
firm, and fled. Great was the wrath that ensued. No apologies could
be accepted. It was the end of his commercial career.
He was then sent to a private tutor at Bonn to learn foreign
languages, and to prepare for the Army. On the breaking out of the
war between France and Austria, he and another fellow-student
joined the Austrians, and went out, as they said, to see the fun. As
luck would have it, they were taken prisoners in a skirmish, and were
brought before General Custine, who commanded the French force
in the neighbourhood. Custine, seeing that they were English and
mere boys, scolded them and told them that it was very lucky for
them that Marshal Davoust had not arrived to take over the
command, “for,” said he, “he would have hanged you without mercy
on the nearest tree. Now go back to your books and your tutor, and
don’t meddle with affairs which do not concern you.”
Shortly after this William Warre was sent back to England, and on
the 5th November 1803, when he was 19 years of age, received his
commission in the 52nd Light Infantry, then under the command of
Sir John Moore. He served with the 52nd till 25th April 1805, when
he was promoted Lieutenant in the 98th, which was then in Canada.
He did not, however, proceed thither, having purchased promotion as
Captain in the 23rd Dragoons.
He served with this regiment in Ireland until the summer of 1807,
when he was sent to the Royal Military College, then established at
High Wycombe, to study for Staff employment.
In 1808 General Ferguson selected him as A.D.C., and took him
with him to Portugal. There he was present at the combat of Roliça,
and at the Battle of Vimeiro, both of which are described in his
letters. His health gave way under the hardships of this campaign,
and he was detained ill at Lisbon for several months. His knowledge
of the Portuguese language enhanced the value of his services, and
after his recovery, General Ferguson having returned to England, he
was attached by General Beresford to his personal staff, and served
with him as his principal A.D.C. until the year 1812.
Captain Warre took part in Sir John Moore’s retreat and, with
General Beresford, was the last to embark after the Battle of
Corunna, 16th January 1809.
In March 1809, Beresford, with the rank of Field-Marshal, was
placed in chief command of the Portuguese Army, and employed
Captain Warre, his A.D.C., in the organisation of the national troops.
He entered the Portuguese service and was promoted therein to the
rank of Major, and appointed first A.D.C. to the Field-Marshal.
After the passage of the Douro, May 1809, Major Warre was sent
forward by Beresford to raise the armed peasantry in the province of
Minho, with a view to harassing the French forces under Marshal
Soult, which were then in full retreat. He succeeded in getting the
peasantry to dismantle the bridges of Ponte Nova and the Saltador,

You might also like