Hello,
I’m having issues with the exercise 2 of this assignment. I have completed the convert_to_bert_input_ids
as requested. However, after multiple tries I’m still stuck. Have checked many similar topics, but couldn’t find a satisfactory solution.
The main problem is that the prepare_data seems to not be imported since it is the first line of the code that crashes when we check the output (below):
Please, let me know what I can do to overcome this problem.
Thanks in advance
Hello,
I am facing the same problem. I appreciate any comments to be able to solve it.
Thank you
Hello again! (#mls C2W1)
I’ve tried other things to try to get ahead and commented out line 28 in “prepare_data.py”, to avoid the commit - that it must have been loaded in the main code.
Now, the error that I get is in the following image: for some reason the “transformers” library has not been loaded correctly at the beginning of the code.
(1. I have cycled the workbench, 2. I have reloaded the kernel, 3. I have exited and re-entered the lab. None of this has worked to overcome the problem)
I appreciate any help to overcome this error.
Thank you so much.
Hi,
I only will touch on the code again later today. But your last reply gave me some insight.
Have you tried to install the transformers library manually?
!pip install transformers
Let me know if it can help with anything or any other discovery you might have to overcome the issue.
Thank you
Hi Jasper, thank you for your answer.
In the main notebook “C2 W1 Assignment.ipynb”, the first cell contains the command in which the “transformers” library is (or should have been) installed, here the command and the screenshot:
!pip install --disable-pip-version-check -q transformers==3.5.1
The issue is, I’m afraid, the library is not being loaded correctly and hence the error. I think it is a connection problem (something like that).
Then, I’ll try to connect to the lab again and see if the error has been fixed.
Thank you very much for your comment.
Yes, I saw that on the C2W2 assignment. The transformers library was supposed to be installed in the beginning of the code. But later on there’s a similar issue to the one that you just showed. I ended up installing it manually and it worked. Thought it would be the same for C2W1.
Well, later on the kernel crashed and the whole assignment for C2W2 got lost as well. Will try both assignments later, hope to have better luck.
BTW, I agree with you. I also think there’s some issue when loading the libraries. The installation process print some errors along the way, both on C2W1 and on C2W2. This is so frustrating
1 Like
From the other thread, you can launch the kernel environment “Data Science 2.0”. It is in the top right hand side where the kernel information is. I don’t have one open right now and I forget exactly what the button is called but click around there until something something sound like change kernel and select it from the dropdown menu. SageMaker must have updated what package version are launched at startup and caused dependency errors.
1 Like
Before the !pip install commands add
!pip uninstall -y setuptools
!pip install setuptools==60.8.2
Thanks @graham_broughton . It worked for both c2w1 and c2w2
No problem, let me know if you have any other problems!
Thanks @graham_broughton, this worked for me too.
Thanks Jaspier for posting this issue, it helped me to solve the problem.