Assignment 2: Modeling and Transforming Text Data for ML

C4_W2 Assignment 2
c4_w2 __4.2.2.
Hello, I have a little problem here.Error: (‘Connection aborted.’, RemoteDisconnected. I have tried to solve it in the following way. go to the AWS console and head to the EC2 section. There should be an EC2 instance with the name de-c4w2a1-ml-model-instance, go to the Instance state dropdown and click on Reboot instance. But the problem still hasn’t gone away. If anyone knows the reason, could you please explain it to me?
thank you in advance

Hi,

The error you’re encountering — TypeError: 'NoneType' object is not subscriptable — is likely due to one of the following reasons:

  1. The API call inside get_text_embeddings may have failed
    Please ensure the API endpoint is correctly defined and functioning as expected (refer to step 4.2.1). If the request fails, the function might return None, leading to this error.
  2. The text input may be invalid or empty
    Double-check that product_information_df is not empty

Thank you @benjamintabaresjr I must have put the wrong endpoint API. I fixed it and it worked fine.

1 Like

You’re welcome! Glad to hear you got it working. Let me know if you run into anything else!