nlp-with-transformers / notebooks

Jupyter notebooks for the Natural Language Processing with Transformers book
https://transformersbook.com/
Apache License 2.0
3.92k stars 1.23k forks source link

Chapter 7 doesn't run on SageMaker (SM) Notebook instance #59

Open heiko-hotz opened 2 years ago

heiko-hotz commented 2 years ago

Information

The problem arises in chapter:

Describe the bug

Chapter 7 doesn't run on SM Notebook instance

To Reproduce

Steps to reproduce the behavior:

  1. Create and open SM notebook instance
  2. Clone repo
  3. Run all cells in notebook 07_question-answering.ipynb

Expected behavior

The notebook runs successfully without errors.

Additional information

Several minor fixes are required to get the notebook running on SM. I have fixed all of them, see this fork. However, I'm hesitant to create a PR for it as I'm not sure whether this will create issues for other environments (e.g. Colab, etc).

How would you like to incorporate these fixes into your repo, if at all?