Assignment: should loading the pre-trained model in Part 4 take a really long time?

In the assignment for Course 4, Week 2, Part 4: Evaluation has the folllowing code:

# Get the model architecture
model = TransformerLM(mode='eval')

# Load the pre-trained weights
model.init_from_file('model.pkl.gz', weights_only=True)

but it has been running for many, many minutes now (so far). There’s usually a warning above or inside a code cell if it will take a long time to run, but I don’t see one. I’m about to finish the assignment but this is preventing me from doing so.

Hi,

Unfortunately, this cell currently takes some 15 minutes to run. I have made a note on this to people working on the backend in the hope that this will be resolved. There are some suggestions on how to finish the notebook nonetheless in another thread, starting here.

2 Likes