Open schinto opened 3 years ago
Had the same problem. Now slowly training with num_workers=0
.
Anyway, thanks for research about this error of multiprocessing and pytorch in macOS.
In addition, I found some minor error too in chapter 2: the link for downloading the coco annotation captions link is not valid. PIL.Image is slightly changed.
a) In the
forward
function ofclass LSTMModel
the parametercapts
is used, butthe
self.embedding_layer
getscaps
without the character tb) Model training on Mac OS X does only work with
num_workers=0
. The data is not loaded whennum_workers
is larger than 0 as used in the notebook.Related PyTorch issues:
c) Proposal of improving the image captioning example in Chapter 2 of the book:
d) I really like the explanation of transfomer models in the YouTube playlist Visual Guide to Transformers Neural Networks, which is more intuitiv compared to the explanation on page 149 "Understanding the transformer model architecture" of the Mastering PyTorch book.