M A N N I N G Eli Stevens Luca Antiga Essential Excerpts Deep Learning with PyTorch Essential Excerpts Eli Stevens and Luca Antiga
Manning Author Picks Copyright 2019 Manning Publications To pre-order or learn more about this book go to www.manning.com are printed on paper that is at least 15 percent recycled and processed without the use of elemental chlorine. Manning Publications Co. 20 Baldwin Road Technical PO Box 761 Shelter Island, NY 11964 Cover designer: Leslie Haimes ISBN: 9781617297120 Printed in the United States of America 1 2 3 4 5 6 7 8 9 10 - EBM - 24 23 22 21 20 19 iii contents preface v 1 Introducing deep learning and the PyTorch library 1 1.1 What is PyTorch? 2 1.2 What is this book? 2 1.3 Why PyTorch? 3 1.4 PyTorch has the batteries included 10 2 It starts with a tensor 15 2.1 Tensor fundamentals 18 2.2 Tensors and storages 22 2.3 Size, storage offset, and strides 24 2.4 Numeric types 30 2.5 Indexing tensors 31 2.6 NumPy i