source: anuga_core/documentation/user_manual/anuga_installation_guide.tex @ 5799

Last change on this file since 5799 was 5799, checked in by rwilson, 16 years ago

Major changes throughout - XP, Vista and Linux made separate streams.

  • Property svn:keywords set to LastChangedDate LastChangedRevision LastChangedBy HeadURL Id
File size: 17.5 KB
Line 
1\documentclass{manual}
2
3
4\title{ANUGA Installation Guide}
5
6\author{Ole Nielsen, Duncan Gray, Jane Sexton}
7
8\usepackage{graphicx}
9
10
11% Please at least include a long-lived email address;
12% the rest is at your discretion.
13\authoraddress{Geoscience Australia \\
14  Email: \email{ole.nielsen@ga.gov.au}
15}
16
17%Draft date
18\date{\today}                   % update before release!
19                % Use an explicit date so that reformatting
20                % doesn't cause a new date to be used.  Setting
21                % the date to \today can be used during draft
22                % stages to make it easier to handle versions.
23
24               
25\input{version} % Get version info - this file may be modified by
26                % update_anuga_user_manual.py - if not a dummy
27                % will be used.
28                               
29
30\makeindex          % tell \index to actually write the .idx file
31%\makemodindex          % If this contains a lot of module sections.
32
33
34
35\begin{document}
36\maketitle
37
38
39
40% This makes the contents more accessible from the front page of the HTML.
41\ifhtml
42\chapter*{Front Matter\label{front}}
43\fi
44
45
46
47
48\chapter{Introduction}
49
50This document outlines the procedure for installing the Anuga toolbox.
51All components are licensed as open source and readily available from the net.
52It is assumed that the reader is familiar with the Python programming language
53and the process of downloading, installing and unpacking files into directories.
54
55
56\section{System requirements}
57\label{sec:requirements}
58
59To run ANUGA you will need a Windows PC (XP or Vista) or a Linux PC with at
60least 512MB RAM.
61
62The viewer (Windows only) requires a graphics adapter that
63is OpenGL compatible. It has been tested with ATI FireGL X1 cards
64and the NVIDIA family. It may not work with other cards such as those from the
65Intel(R) 82915G Express chipset family.
66
67
68\section{Installation}
69
70Below are the install procedures for Windows XP, Windows Vista and Linux.
71
72\subsection{Quick install - Windows XP}
73\label{sec:winxp}
74
75This procedure assumes that you do not have python installed on the target machine.
76If you do have a python installed already then skip the installation of python as
77long as you have version 2.3 or later installed.
78
79\begin{enumerate} 
80  \item Install the support software.
81    These packages are available from either:
82    \begin{itemize} 
83      \item The supplied ANUGA distribution folder: \code{pre_requisites$\backslash$2.5}.
84        Install in order:
85        \begin{enumerate}
86          \item Execute \code{python-2.5.msi} to install python.
87          \item Execute \code{Numeric-23.8.2.win32-py2.5.exe} to install Numeric Python.
88          \item Execute \code{ScientificPython-2.7.8.win32-py2.5.exe} to install Scientific Python.
89          \item Execute \code{MinGW-5.1.4.exe} to install MinGW.
90        \end{enumerate} and then unpack \code{netcdf-3.6.1-win32dll.zip} into a folder that is available on the system path.
91        We suggest unpacking it into \code{C:$\backslash$bin}.
92      \item The Internet. Install in order:
93        \begin{enumerate} 
94          \item \url{http://www.python.org/download/}. Click on the \code{Python 2.5.x Windows installer} link to get
95            \code{python-2.5.x.msi}. Execute this file to install python.
96          \item \url{http://sourcesup.cru.fr/frs/?group\%5Fid=180}. Download \code{Numeric-23.8.2.win32-py2.5.exe}
97            and execute it to install Numeric Python.
98          \item \url{http://sourcesup.cru.fr/frs/?group\%5Fid=180}. Download \code{ScientificPython-2.X.X.win32-py2.5.exe}
99            and execute it to install Scientific Python.
100          \item \url{http://sourceforge.net/project/showfiles.php?group\%5Fid=2435}. Click on the \code{Download} link for
101            the \code{MinGW_5.1.4} package. Execute the file \code{MinGW-5.X.X.exe} to install the MinGW environment.
102            Note that you need a working internet connection to install WinGW.
103          \item \url{http://www.unidata.ucar.edu/software/netcdf/binaries.html}. Click on the
104            \code{Windows DLL} link in the NetCDF 3.6.1 section.  This will download the file \code{netcdf-3.6.1-win32.zip}.
105            Unpack this in a folder that is available on the system path.
106            We suggest unpacking it into \code{C:$\backslash$bin}.
107        \end{enumerate}   
108    \end{itemize}   
109 
110  \item Add the following to the PATH environment variable:
111    \begin{verbatim}PATH=C:\Python25;C:\MingW\bin;C:\bin\end{verbatim}
112    For details on how to do this under Windows please refer to Appendix \ref{sec:setwindowspath}.
113
114    Note that if you have another version of python installed, 2.4  say, you would replace any
115    \code{Python25} above with \code{Python24}.
116    A similar replacement should be made in all following steps wherever you see \code{Python25}.
117
118  \item Unpack the ANUGA source code (\code{anuga-1.0_xxxx.tgz})\footnote{Internet Explorer has the habit of renaming the .tgz files to .gz -
119                                                                          the remedy is to rename them back or use another browser such as Firefox.} 
120    in the python site-packages directory \code{C:$\backslash$Python25$\backslash$Lib$\backslash$site-packages}.
121    This is often done in Windows by double clicking on the \code{.tgz} file and then 'browse to' the destination directory.
122
123  \item In the ANUGA root directory (\code{C:$\backslash$Python25$\backslash$Lib$\backslash$site-packages$\backslash$anuga}),
124    run the compilation script (either from the commandline or by running it in IDLE):
125    \begin{verbatim}python compile_all.py\end{verbatim}
126
127  \item In the ANUGA root directory (\code{C:$\backslash$Python25$\backslash$Lib$\backslash$site-packages$\backslash$anuga}),
128    run the test suite (either from the commandline or by running it in IDLE):
129    \begin{verbatim}python test_all.py\end{verbatim} ANUGA has been succesfully installed if the tests pass.
130
131  \item To verify that ANUGA succesfully reproduces a series of validation examples, go
132    to the directory
133    \linebreak
134    \code{anuga_validation$\backslash$automated_validation_tests} under the ANUGA root directory where you can run:
135    \begin{verbatim}python validate_all.py\end{verbatim}
136    This may take some time.
137
138  \item To install the ANUGA viewer:
139    \begin{enumerate} 
140      \item Unpack the distribution (\code{anuga_viewer_1.0.tgz}) into:
141        \begin{verbatim}C:\Program Files\end{verbatim}
142
143      \item Double click on the test file:
144        \begin{verbatim}C:\Program Files\anuga_viewer\cylinders.sww\end{verbatim}
145
146      \item Associate \code{.sww} files with the executable:
147      \begin{verbatim}C:\Program Files\anuga_viewer\animate.exe\end{verbatim}       
148      For details on how to do this under Windows please refer to Appendix \ref{sec:assocanimatesww}.
149    \end{enumerate} 
150
151    Try the demonstrations provided in the ANUGA directory \code{anuga\_demos} 
152    (discussed in the ANUGA user manual at
153    \url{http://datamining.anu.edu.au/\%7Eole/anuga/user\%5Fmanual/anuga\%5Fuser\%5Fmanual.pdf})
154    and view the resulting \code{.sww} files with the ANUGA viewer.
155\end{enumerate}   
156
157
158%To run the ANUGA against the Okushiri Island wave tank validation dataset
159%(\url{http://www.cee.cornell.edu/longwave})
160%go to \code{anuga_validation}
161% into
162%any directory and run the scripts \code{create_okushiri.py},
163%\code{run_okushiri.py} and \code{compare_timeseries.py}.  See also the
164%\code{README.txt} file that comes with the validation scripts for more
165%details.
166
167\subsection{Quick install - Windows Vista}
168\label{sec:winvista}
169
170There has been one reported instance of ANUGA being installed successfully on Windows Vista.
171The following steps should be read in conjunction with the windows XP procedures above:
172
173\begin{enumerate} 
174  \item Install \code{python-2.5.msi}.
175  \item Add the directory \code{C:$\backslash$Python25} to the \code{PATH} environment variable (appendix \ref{sec:setwindowspath}).
176  \item Install \code{Numeric-23.8.2.win32-py2.5.exe} (as administrator).
177  \item Install \code{ScientificPython-2.7.8.win32-py2.5.exe} (as administrator).
178  \item Install \code{MinGW-5.1.4.exe} (as administrator). Use the default package selection.  Don't use old packages and let it make fresh downloads.
179  \item Unpack \code{netcdf-3.6.1-beta1-win32dll.zip} into \code{C:$\backslash$bin}.
180  \item Add the directory \code{C:$\backslash$bin} to the \code{PATH} environment variable (appendix \ref{sec:setwindowspath}).
181  \item Install \code{pysco-1.6.win32-py2.5.exe} (as administrator).
182  \item Install \code{matplotlib-0.91.2.win32-py2.5.exe} (as administrator).
183  \item Install \code{numpy-1.1.0-win32-superpack-python2.5.exe} (as administrator).
184  \item Check that the system variable \code{PATH} contains
185        \code{C:$\backslash$Python2.5;C:$\backslash$Python25$\backslash$DLLs;C:$\backslash$bin;C:$\backslash$MinGW$\backslash$bin}
186        (appendix \ref{sec:setwindowspath}).
187  \item Now follow the Windows XP install steps from the ANUGA source code install step.
188\end{enumerate}
189
190Some of the installed packages above are optional and may not be required, but this is the reported working install we have received.
191
192\subsection{Quick install - Linux}
193\label{sec:linux}
194
195The procedure to install onto a Linux platform is targetted at a Debian-like Linux, such as Ubuntu.
196If you use another Linux the overall procedure should be followed, although the details will vary.
197
198This steps below assume that you do not have python installed on the target machine.
199If you do have a python installed already then skip the installation of python as
200long as you have version 2.3 or later.
201
202Note that even if you already have python installed you should still check if things like
203\code{python-dev} and \code{python-profiler} need to be installed.
204
205\begin{itemize}
206  \item Install support software (in order):
207    \begin{enumerate} 
208      \item Install python development environment, either through Synaptic or by:
209        \begin{verbatim}sudo apt-get install python python-dev python-profiler\end{verbatim}
210      \item Install Numeric Python, either through Synaptic or by:
211        \begin{verbatim}sudo apt-get install python-numeric\end{verbatim}
212      \item Install Scientific Python, either through Synaptic or by:
213        \begin{verbatim}sudo apt-get install python-scientific\end{verbatim}
214      \item Install NetCDF, either through Synaptic or by:
215        \begin{verbatim}sudo apt-get install python-netcdf\end{verbatim}
216      \item Install \code{gcc} and it's development environment if you don't have it, either through Synaptic or by:
217        \begin{verbatim}sudo apt-get install gcc libc6-dev\end{verbatim}
218        Ensure that \code{libc6-dev} is installed even if \code{gcc} is already installed.
219    \end{enumerate}   
220  \item Get the ANUGA source from \url{http://sourceforge.net/projects/anuga} (\code{anuga-1.0_5789.tgz} say),
221    and expand it into the python site-packages directory \code{/usr/lib/python2.5/site-packages}.
222    In the unpacked ANUGA directory \code{/usr/lib/python2.5/site-packages/anuga_core} run the command:
223    \begin{verbatim}sudo python compile_all.py\end{verbatim}
224\end{itemize}
225
226\section{Optional but recommended software}
227This software is not required to run the ANUGA toolbox, but it is recommended.
228\begin{itemize}
229  \item psyco. Speeds up ANUGA by about 30\%. Under Ubuntu install either through Synaptic or by:
230    \begin{verbatim}sudo apt-get install python-psyco\end{verbatim}
231    Under Windows install the file \code{psyco-1.6.win32-py25.exe}
232    which you can find from the \url{http://psyco.sourceforge.net/download.html} page.
233  \item matplotlib. For quality 2d plotting (moving towards mandatory requirement). Under Ubuntu install either through Synaptic or by:
234    \begin{verbatim}sudo apt-get install python-matplotlib\end{verbatim}
235    Under Windows install the file \code{matplotlib-0.98.3.win32-py2.5.exe}
236    which you can find from the \url{http://sourceforge.net/projects/matplotlib} page.
237  \item VTK. The Visualization Toolkit. Under Ubuntu install either through Synaptic or by:
238    \begin{verbatim}sudo apt-get install python-vtk\end{verbatim}
239    Under Windows install the file \code{vtk-5.2.0-win32.exe}
240    from the \url{http://www.vtk.org/get-software.php} page.
241\end{itemize}
242
243
244
245\section{Testing}
246
247In the ANUGA root directory, run the test suite:
248\begin{verbatim}
249python test_all.py
250\end{verbatim}
251ANUGA has been succesfully installed if the tests pass as follows:
252\begin{verbatim}
253  ...
254  test_data_manager.py
255  test_interpolate_sww.py
256  test_mesh.py
257  test_mesh_interface.py
258  test_triangmodule.py
259  test_triangmoduleII.py
260  test_advection.py
261............................................................................................................................................
262............................................................................................................................................
263............................................................................................................................................
264............................................................................................................................................
265.................................
266----------------------------------------------------------------------
267Ran 593 tests in 42.712s
268
269OK
270\end{verbatim}
271
272
273
274%\section{Other stuff to be included}
275%
276%\begin{verbatim}
277%Install tortoise from downloads (ITs didn't integrate wih explorer).
278%In settings set proxy to proxy.agso.gov.au  8080
279%%
280%
281%Install swollen from latest distro (in subversion)
282%
283%
284%\end{verbatim}
285
286
287\appendix
288\chapter{Miscellaneous procedures}
289\section{Setting the PATH on Windows}
290\label{sec:setwindowspath}
291
292The method of setting the PATH environment variable for Windows XP is shown here.
293Setting the variable for Windows Vista should be similar.
294
295\setlength\fboxsep{0pt}
296\setlength\fboxrule{1.0pt}
297
298First, open the Control Panel:
299\begin{figure}[ht]
300  \centerline{\fbox{\includegraphics[scale=0.75]{installgraphics/winsetpath1.png}}}
301%  \caption{Run Control Panel from the Start menu}
302  \label{fig:winsetpath1}
303\end{figure}
304
305Next, start the System applet:
306\begin{figure}[ht]
307  \centerline{\fbox{\includegraphics[scale=0.75]{installgraphics/winsetpath2.png}}}
308%  \caption{Start the System applet}
309  \label{fig:winsetpath2}
310\end{figure}
311
312\pagebreak
313
314Select the \code{Advanced} tab in the System Properties window:
315\begin{figure}[ht]
316  \centerline{\includegraphics[scale=0.5]{installgraphics/winsetpath3.png}}
317%  \caption{Select the Advanced tab}
318  \label{fig:winsetpath3}
319\end{figure}
320
321%\pagebreak
322
323Press the \code{Environment Variables} button in the \code{Advanced} tab:
324\begin{figure}[ht]
325  \centerline{\includegraphics[scale=0.5]{installgraphics/winsetpath4.png}}
326%  \caption{Press the Environment Variables button}
327  \label{fig:winsetpath4}
328\end{figure}
329
330\pagebreak
331
332If the \code{PATH} variable is not defined in the top window, press the \code{New} button.
333If \code{PATH} already exists, select the row with the \code{PATH} variable name in the top listbox
334and press the \code{Edit} button next to the \code{New} button:
335\begin{figure}[ht]
336  \centerline{\includegraphics[scale=0.5]{installgraphics/winsetpath5.png}}
337%  \caption{Press the New button}
338  \label{fig:winsetpath5}
339\end{figure}
340
341%\pagebreak
342
343You will be shown the editor window whichever button you pressed in the above step. If the \code{Variable name} box is empty
344type in the name \code{PATH}.  In the \code{Variable value} box type the value you want the \code{PATH} variable to have.  If there
345is already some text in the box, place your additional value at the front of the existing value, not forgetting to terminate your additional
346string with the ';' character. The final value string must be a series of directory names seperated by ';' characters:
347\begin{figure}[ht]
348  \centerline{\includegraphics[scale=0.75]{installgraphics/winsetpath6.png}}
349%  \caption{Modifying the PATH value}
350  \label{fig:winsetpath6}
351\end{figure}
352
353When you are finished, press the \code{OK} button and exit from the applet.
354
355\pagebreak
356
357\section{Associating animate.exe with a .sww file}
358\label{sec:assocanimatesww}
359
360The method of associating \code{animate.exe} with a \code{.sww} file is shown here for Windows XP.
361A similar process should work for Windows Vista.
362
363Double left-click on any \code{.sww} file.  This brings up a dialog because Windows doesn't know how to open the file:
364\begin{figure}[ht]
365  \centerline{\fbox{\includegraphics[scale=0.5]{installgraphics/winassoc1.png}}}
366%  \caption{Try to open the .sww file}
367  \label{fig:winassoc1}
368\end{figure}
369
370Select the "\code{Select the program from a list}" radiobutton and press the \code{OK} button:
371\begin{figure}[ht]
372  \centerline{\includegraphics[scale=0.5]{installgraphics/winassoc2.png}}
373%  \caption{Select the program from a list}
374  \label{fig:winassoc2}
375\end{figure}
376
377\pagebreak
378
379Press the \code{Browse...} button to find the \code{animate.exe} program:
380\begin{figure}[ht]
381  \centerline{\includegraphics[scale=0.5]{installgraphics/winassoc3.png}}
382%  \caption{Find animate.exe program}
383  \label{fig:winassoc3}
384\end{figure}
385
386Navigate to the \code{C:$\backslash$Program Files$\backslash$anuga_viewer} directory:
387\begin{figure}[ht]
388  \centerline{\includegraphics[scale=0.5]{installgraphics/winassoc4.png}}
389%  \caption{Navigate into Program Files|anuga_viewer directory}
390  \label{fig:winassoc4}
391\end{figure}
392
393\pagebreak
394
395Select \code{animate.exe} and press the \code{Open} button:
396\begin{figure}[ht]
397  \centerline{\includegraphics[scale=0.5]{installgraphics/winassoc5.png}}
398%  \caption{Select the animate.exe program press Open}
399  \label{fig:winassoc5}
400\end{figure}
401
402Finally, press the \code{OK} button:
403\begin{figure}[ht]
404  \centerline{\includegraphics[scale=0.5]{installgraphics/winassoc6.png}}
405%  \caption{Press the OK button}
406  \label{fig:winassoc6}
407\end{figure}
408
409
410\end{document}
Note: See TracBrowser for help on using the repository browser.