C4DM2013 Software » History » Version 2

Luis Figueira, 2013-03-11 04:05 PM

1 1 Luis Figueira
h1. C4DM2013 Software
2 1 Luis Figueira
3 1 Luis Figueira
You should ensure the following software is installed on your laptop before you arrive at the bootcamp, so that we can get started promptly with the tutorials.
4 1 Luis Figueira
5 1 Luis Figueira
h2. Shortlist
6 1 Luis Figueira
7 1 Luis Figueira
* Bash (the particular Unix shell we’ll be using)
8 1 Luis Figueira
* Mercurial and EasyMercurial (for version control)
9 1 Luis Figueira
* Firefox with SQLite Manager add-on (relational database)
10 1 Luis Figueira
* A text editor (for programming!)
11 1 Luis Figueira
* You can also save time on the day by creating an account beforehand at the "SoundSoftware code site":http://code.soundsoftware.ac.uk.
12 2 Luis Figueira
* Python 2.6+ (the scripting language used in the course)
13 1 Luis Figueira
14 2 Luis Figueira
For the second day of the bootcamp you'll need the following Python packages: 
15 1 Luis Figueira
16 2 Luis Figueira
* Specific Python Packages
17 2 Luis Figueira
** Numpy
18 2 Luis Figueira
** SciPy
19 2 Luis Figueira
** Matplotlib
20 2 Luis Figueira
** Scikits Audiolab
21 2 Luis Figueira
22 2 Luis Figueira
23 1 Luis Figueira
24 1 Luis Figueira
If you run into any trouble, please leave a comment at the bottom of the page. We’ll check them regularly.
25 1 Luis Figueira
26 1 Luis Figueira
Installation on Linux
27 1 Luis Figueira
Bash, Python and Firefox are all available using the appropriate package management tool in all major Linux distributions. Please check that the Python version is 2.x, (2.6 or higher, preferrably). If not, you may need to install a newer version “by hand” or upgrade your Linux installation.
28 1 Luis Figueira
29 1 Luis Figueira
The SQLite Manager add-on can be installed through the “Add-ons Manager” in Firefox.
30 1 Luis Figueira
31 1 Luis Figueira
EasyMercurial can be downloaded as a .deb package (for Debian or Ubuntu installations) from the EasyMercurial download page. Your package manager should automatically install any dependencies, including Mercurial itself. On Red Hat or other Linux distributions you will probably need to install Mercurial first using your package manager, then download the EasyMercurial source code package and compile and install it using the instructions in the included file README.txt: just run qmake and then make. The qmake tool is part of the qt-devel package, which you may need to install first.
32 1 Luis Figueira
33 1 Luis Figueira
If you use Linux, you probably already have a favourite text editor. Emacs and Nano are popular choices, but there are many others.
34 1 Luis Figueira
35 1 Luis Figueira
Installation on Windows
36 1 Luis Figueira
Note: We have recently changed these requirements from Cygwin to
37 1 Luis Figueira
MinGW/MSYS
38 1 Luis Figueira
39 1 Luis Figueira
You should install MinGW and MSYS. Check that you can run (from the Windows Start menu) MinGW -> MinGW Shell in order to open a Bash prompt.
40 1 Luis Figueira
41 1 Luis Figueira
Install Python 2.7 using the MSI installer from python.org, then both NumPy and SciPy packages from scipy.org.
42 1 Luis Figueira
43 1 Luis Figueira
Install the scikits.audiolab package from this site, and matplotlib from SourceForge.
44 1 Luis Figueira
45 1 Luis Figueira
You can download Firefox from the Mozilla web site, and then the SQLite Manager add-on can be installed through the “Add-ons Manager” in Firefox.
46 1 Luis Figueira
47 1 Luis Figueira
EasyMercurial can be downloaded from the EasyMercurial download page and the Windows installer will also install Mercurial itself.
48 1 Luis Figueira
49 1 Luis Figueira
You will need to edit the PATH environment variable to add Python and Mercurial. To do this, go to Control Panel -> System and Security -> System -> Advanced system settings -> Advanced and click the Environment Variables button; then edit the PATH user variable and copy and paste
50 1 Luis Figueira
51 1 Luis Figueira
C:\Python27;C:\Program Files\EasyMercurial;C:\Program Files (x86)\EasyMercurial
52 1 Luis Figueira
53 1 Luis Figueira
onto the end of it.
54 1 Luis Figueira
55 1 Luis Figueira
You can use Wordpad or Notepad as a text editor, or install another editor such as Sublime Text.
56 1 Luis Figueira
57 1 Luis Figueira
Installation on Mac OSX
58 1 Luis Figueira
OSX comes with Bash and Python.
59 1 Luis Figueira
60 1 Luis Figueira
You can download Firefox from the Mozilla web site, and then the SQLite Manager add-on can be installed through the “Add-ons Manager” in Firefox.
61 1 Luis Figueira
62 1 Luis Figueira
You can download Mercurial from the Mercurial web site and EasyMercurial from the EasyMercurial download page.
63 1 Luis Figueira
64 1 Luis Figueira
There are many text editors available for OSX.
65 1 Luis Figueira
66 1 Luis Figueira
The following instructions have been tested under OSX Lion (10.7). Please let us know if you run into any problem
67 1 Luis Figueira
68 1 Luis Figueira
To install the remaining software, you’ll need to have both XCode and Homebrew installed.
69 1 Luis Figueira
70 1 Luis Figueira
XCode: Please follow the instructions on this page to install XCode using the AppStore;
71 1 Luis Figueira
Homebrew: Please follow the instructions in the Homebrew’s page.
72 1 Luis Figueira
The easiest way to install SciPy, Numpy and Matplotlib is to use the following script (just follow the instructions on the page): ScipySuperpack
73 1 Luis Figueira
74 1 Luis Figueira
Audiolab depends on libsndfile, so you need to install it first. To install it run the following command on the Terminal:
75 1 Luis Figueira
76 1 Luis Figueira
brew install libsndfile
77 1 Luis Figueira
78 1 Luis Figueira
After this, you need to install Audiolab. To install Audiolab, you need to run the following commands on the Terminal (you might need to be sudo):
79 1 Luis Figueira
80 1 Luis Figueira
easy_install pip
81 1 Luis Figueira
pip install scikits.audiolab
82 1 Luis Figueira
83 1 Luis Figueira
Alternate approach: using a Virtual Machine
84 1 Luis Figueira
If you would prefer, you can install a VirtualBox image of a virtual
85 1 Luis Figueira
machine running Linux with the necessary software already installed.
86 1 Luis Figueira
87 1 Luis Figueira
You can download the VirtualBox disk image file from the following
88 1 Luis Figueira
link: SoundSoftware_SoftwareCarpentry-20120910.zip (1.2GB) (SHA-1: fff6c4804e61e9fc2aef41f8f5e412eec44909cd). After
89 1 Luis Figueira
downloading, unzip the file to obtain a .vdi disk image.
90 1 Luis Figueira
91 1 Luis Figueira
To use it, you will need to install VirtualBox from
92 1 Luis Figueira
http://virtualbox.org. Install VirtualBox, then create a new virtual
93 1 Luis Figueira
machine using the default settings (with however much memory you think
94 1 Luis Figueira
you can allocate to it) using the .vdi file as its disk image.
95 1 Luis Figueira
96 1 Luis Figueira
When you run the virtual machine, you will need to log in as a user:
97 1 Luis Figueira
the default user is called “ssw” and has password “ssw2012″.
98 1 Luis Figueira
99 1 Luis Figueira
Testing the installed software
100 1 Luis Figueira
We recommend that you try the following simple tests to ensure that everything is installed and working correctly before the course starts.
101 1 Luis Figueira
102 1 Luis Figueira
Bash
103 1 Luis Figueira
104 1 Luis Figueira
At the prompt, type “whoami”. You should be told what your user name is on the computer you are using.
105 1 Luis Figueira
106 1 Luis Figueira
Python
107 1 Luis Figueira
108 1 Luis Figueira
At the prompt, type “print 2+2″ and check that you agree with the result.
109 1 Luis Figueira
110 1 Luis Figueira
Then type “import sqlite3″ and verify that you don’t see an error message.
111 1 Luis Figueira
112 1 Luis Figueira
SQLite Manager
113 1 Luis Figueira
114 1 Luis Figueira
Open SQLite Manager from Firefox. In Firefox 10 on Linux this is under the “Tools” menu, but this may vary depending on the version and operating system you are using.
115 1 Luis Figueira
116 1 Luis Figueira
Create a new database: Database -> New Database.
117 1 Luis Figueira
118 1 Luis Figueira
Mercurial
119 1 Luis Figueira
120 1 Luis Figueira
At the Bash prompt, type “hg”. You should see a list of basic Mercurial commands.
121 1 Luis Figueira
122 1 Luis Figueira
EasyMercurial
123 1 Luis Figueira
124 1 Luis Figueira
Create a directory (folder) somewhere on your computer.
125 1 Luis Figueira
126 1 Luis Figueira
Start EasyMercurial and create a repository in your new directory: Open -> File folder -> navigate to your directory  and click “OK”.
127 1 Luis Figueira
128 1 Luis Figueira
Text editor
129 1 Luis Figueira
130 1 Luis Figueira
Create and save a file with some plain text in it.