C4W3 - ungraded lab versioning - chmod +x setup.sh

Hi everyone,
It seems the command chmod +x setup.sh is not working, as I run setup.sh and it does nothing at all. I am working on WSL2 /Windows 10.
Looking for solutions I did change Settings → Updates → for developers mode “turn on”.
I would appreciate your comments.
Thanks in advance.

Hi Sergio! It seems there is an error and it generated a wget-log file. Can you do a cat wget- log and see if there are useful error messages? Please share them here. Another approach might be to open the setup.sh file and remove one of the -q flags in the wget commands. You can do it on the first line. Then run the script again and see if the output mentions what might be the problem.

Hi Sergio! My guess here is that chmod does not behave as expected since the files you are trying to edit live within the Windows OS (correct me if I’m wrong). One good practice when using WSL2 is to have all your files within the WSL2 filesystem and not under /mnt/c/ since this is the Windows OS and there can be conflicts when changing stuff like permissions of files.

I recommend you clone the repo under the WSL2 filesystem (/home/your-username/ should be fine) and try again.

@scruz03 please let me know if this solves the issue and I will add a note for other learners :slight_smile:

Hi @a-zarta, see the screenshot below. I guess the repo was cloned in the WSL2 file system, please correct me if I am wrong.

Hi @chris.favila I did use cat wget-log and also I modified the setup.sh file, however, nothing new happened. See the screenshots below.

Hi @scruz03! Yes, it looks like it is cloned in the WSL2 filesystem in that case. I was confused because I saw you pasted a screenshot of the repo that was open with the windows explorer but in the latest screenshot it is definitely in the right place.

Are you sure the setup.sh didn’t work? This file is only meant to create the models/animals directory and download some files in there. If you see some files under models/animals then it worked as expected, otherwise let me know!

Hi @a-zarta, yes, it did not work.
Thanks again,

Hi Sergio! This is strange. Can you try just executing the commands from that script? Please run this in your terminal:

wget -P ./models/animals/1/ https://storage.googleapis.com/mlep-public/course_1/week2/model-balanced/saved_model.pb

If this works and you can see the downloaded file, I recommend just copy pasting the commands from the script. If that doesn’t work, can you do a sanity check and just do:

wget google.com

That should download the index.html of the Google website. If even that doesn’t work, then wget might not be setup in your machine. Workaround would be to use other download utilities (e.g. curl) or maybe try reinstalling wget if possible. But let’s see first if this is really the issue.

Hope it works!

1 Like

Hi @chris.favila
Thanks again, I did follow the steps, see the screenshot below.
It seems it is wget that is not working.

Maybe you have an outdated version of wget (?)

Can you paste the output of the wget --version command?

Here it is:

Okay, so that is not it. I’ve got the same version. Are you by any chance using a VPN?

I am checking a github issue related to this and there seems to be a solution, but I cannot say if it will work or not for sure.

We can try to figure it out but in the meantime I will upload a zip containing the required files so you can go through the lab. I recommend unzipping using windows (7zip should be fine) and then moving the models dir into the repo. So if you are within the repo in the lab’s dir it will be something like mv /mnt/c/Users/Sergio/Downloads/models .

Thanks @a-zarta.
I’m using my 4G phone connection to Internet.

Hi Sergio! If you have time, can you also check if curl works instead?

curl -Lo --create-dirs ./models/animals/1/saved_model.pb https://storage.googleapis.com/mlep-public/course_1/week2/model-balanced/saved_model.pb

If this works then maybe your setup.sh can be modified to this:

curl -Lo --create-dirs ./models/animals/1/saved_model.pb https://storage.googleapis.com/mlep-public/course_1/week2/model-balanced/saved_model.pb
curl -Lo --create-dirs ./models/animals/1/variables/variables.data-00000-of-00001 https://storage.googleapis.com/mlep-public/course_1/week2/model-balanced/variables/variables.data-00000-of-00001
curl -Lo --create-dirs ./models/animals/1/variables/variables.index https://storage.googleapis.com/mlep-public/course_1/week2/model-balanced/variables/variables.index

curl -Lo --create-dirs ./models/animals/2/saved_model.pb https://storage.googleapis.com/mlep-public/course_1/week2/model-imbalanced/saved_model.pb
curl -Lo --create-dirs ./models/animals/2/variables/variables.data-00000-of-00001 https://storage.googleapis.com/mlep-public/course_1/week2/model-imbalanced/variables/variables.data-00000-of-00001
curl -Lo --create-dirs ./models/animals/2/variables/variables.index https://storage.googleapis.com/mlep-public/course_1/week2/model-imbalanced/variables/variables.index

curl -Lo --create-dirs ./models/animals/3/saved_model.pb https://storage.googleapis.com/mlep-public/course_1/week2/model-augmented/saved_model.pb
curl -Lo --create-dirs ./models/animals/3/variables/variables.data-00000-of-00001 https://storage.googleapis.com/mlep-public/course_1/week2/model-augmented/variables/variables.data-00000-of-00001
curl -Lo --create-dirs ./models/animals/3/variables/variables.index https://storage.googleapis.com/mlep-public/course_1/week2/model-augmented/variables/variables.index

If it doesn’t, then the zip file is indeed the way to go as Andres mentioned. Thanks!

Hi @chris.favila , thanks, see the screenshot below.

Oh I see. So it’s really a network settings issue. Seems like the DNS needs to be configured as shown in the post above. Hope you’re now able to proceed with the lab using the zip file from Andres. Thank you for bearing with the troubleshooting!