Lab

Lab schedule for the mid-point in the course

  • Week 7 Wednesday: lab to finish the TTS assignment
  • Week 8 Wednesday: lab to learn shell scripting
  • Week 9 Wednesday: lab to start the ASR assignment

In Assignment 2 you will build a simple Automatic Speech Recognition system using the HTK toolkit. This will involve writing shell scripts, which are simple programs written in the shell language. We will use the bash shell. You’ve actually already used it a little bit without realising: it is what is running in the terminal and what you are interacting with when you copy files or start programs from the command line.

Non-computer science students might be pleased to hear that even students with computer science backgrounds often don’t know shell scripting: they will be learning it for the first time in this course!

Unless you are already a shell ninja, we strongly recommend attending a Week 8 lab where we will walk you through a series of exercises in shell scripting and/or you can work through some of the materials below at your own pace, with tutors available to help you when you get stuck.

Learn to use the Unix shell

From experience, the hardest part of the assignment for most students is learning enough shell scripting to automate the experiments. Your motivation for learning shell scripting is very clear: automating the experiments in Assignment 2 will enable you to do more work with less effort. Shell scripting is also a very useful skill in general. The tutors will help you in the labs, but it’s really a very good idea to get some practice with the basics as soon as you can.

If you want to practice on your own computer, you do not need to install Linux! On a Mac you can practice in the Terminal, and there are equivalents available on Windows (e.g. Powershell or Ubuntu WSL). Or simply use the remote desktop provided for this course.

If you’re not really familiar with the unix shell – don’t panic! A good intro to start with is Joe Collins’ Beginner’s Guide to the Bash Terminal (YouTube).  This will show you the very common commands we use in the shell.  The video has topic time stamps so you can go to the demos of specific commands (listed in the info section).

Once you feel ready, try following this Bash Shell scripting Primer which walks you through most of the techniques you will need for the upcoming assignment. The lab session will help you build confidence with these techniques by writing some scripts of your own.

If you have already used the unix shell, but not done much shell scripting, you might want to look at materials on shell scripting on  The Missing Semester of Your CS Education website.

For a complete structured course, we recommend the LinkedIn learning online course Learning Linux Command Line which you can access for free using your University of Edinburgh account. This course goes beyond what you need for the assignment, but is a good investment of time for students who will use the shell in future (e.g., in a dissertation or a job).

There is also a forum for getting help with shell scripting. You can learn a lot from other students’ questions, or the topics started by Simon which are bite-size mini-tutorials.