Error in "# UNQ_C13 (UNIQUE CELL IDENTIFIER, DO NOT EDIT)"

UNQ_C13 (UNIQUE CELL IDENTIFIER, DO NOT EDIT)

You do not have to input any code in this cell, but it is relevant to grading, so please do not change anything

testing your function

custom_tweet = “RT @Twitter @chapagain Hello There! Have a great day. :slight_smile: #good #morning http://chapagain.com.np
tweet_embedding = get_document_embedding(custom_tweet, en_embeddings_subset)
tweet_embedding[-5:]

Error in Code:

TypeError Traceback (most recent call last)
in
5 custom_tweet = “RT @Twitter @chapagain Hello There! Have a great day. :slight_smile: #good #morning http://chapagain.com.np
6 tweet_embedding = get_document_embedding(custom_tweet, en_embeddings_subset)
----> 7 tweet_embedding[-5:]

TypeError: ‘int’ object is not subscriptable

Hey @akseal,
Welcome back to the community! As you can observe, you didn’t have to write any code in this cell, so the error lies in your implementation of get_document_embedding. Do check your implementation of the same once, you can try to debug it using some print statements, to see if the variables hold the expected values or not. I hope this helps.

Cheers,
Elemento