Next: Running wcd, Previous: Description, Up: Top
wcdwcdThe latest version of wcd can be found at:
http://code.google.com/p/wcdest
You should also be able to find it at: ftp://ftp.cs.wits.ac.za/pub/research/software/
Please let me know if you would like to be told about new versions of
wcd.
There are a number of changes from 0.3 to 0.4 in memory organisation and algorithm. The first two are important to note if you used the options as the appropriate default values have changed.
The distribution comes as a gzipped, tarred file. The following commands should create a directory called ‘wcd_distrib’ with all the necessary files.
gunzip wcd_distrib.tar.gz tar -xf wcd_distrib.tar
There are two possible ways to compile and install wcd
configureThe INSTALL file gives a more detailed explanation and description. The following should work if you don't want anything fancy. If you do, or if you want to ensure that some compile flags are different, then read the INSTALL file.
./configure make make install
Note that the last instruction will attempt to install the executable and
documentation in the appropriate places on your system and will
probably require you to have root privilege or write permission for
those standard directorites. If you don't have these, you can find
the executable wcd in the src directory and the
texinfo documentation wcd.info in the doc
directory. Manually copy these to the correct place.
If you are using FreeBSD, you may have to make a small change to the
common.h file.
If you want a manual you can print out, say make pdf. Otherwise
you can read the on-line version using the info system. If the
documentation is installed in the right place on your system you can
just say info wcd, otherwise you will have to say info -f wcd.info.
wcd should work on 64-bit, little-endian and big-endian machines.
From version 0.3.0, wcd has an MPI version that allows parallelisation of the clustering on a cluster of workstations.
./configure --enable-MPI make make install
Initial experimentation has shown that using the MPI option when not
necessary leads to a 2\% degradation in performance, so the main benefit
of not using the enable-MPI option is that wcd will
compile without the MPI libraries.
From version 0.3.0, wcd has an MPI version that allows parallelisation on SMP architectures
./configure --enable-PTHREADS make make install
In version 0.4, the two parallelisation techniques complement each other. You can run on a cluster of SMP machines. However, an assumption is made that each of the SMP machines has the same number of processors. In version 0.3, binaries supporting both techniques could be used but only one used in a particular run; this no longer holds in 0.4.
makeThe wcd program is written in reasonably standard C.
If you don't want to or can't use the autoconf method described above,
try the following. Change directory to the src directory.
make -f WcdMake wcd
This was tested on different versions of RedHat and Suse and worked
without problem. wcd is written in reasonably standard C, and so
should work on most systems, but unfortunately the vagaries of different
libraries and compilers might make the standard compilation fail. See
the troubleshooting section below for some suggestions.
To get documentation, running make -f WcdMake pdf in the
src directory will produce a pdf version of the manual
(placing output in the doc directory). make -f WcdMake
info will produce texinfo version.
If you know something about your system and are happy mucking about
with make files, please read the technical note below and make the
necessary changes. If not, try the following suggestions. There are
three likely causes of problems: (1) wcd supports long options
(e.g. you can say --cluster_compare rather than -D); (2)
your compiler is cc rather than gcc; and (3) your
compiler does not support procedure inlining (inlining may make some
performance benefit, but does not change functionality or use).
The makefile WcdMake is the one to look at.
make -f WcdMake simple to see whether the problem is that you
don't have the libraries that support long options. If this works,
wcd will run as is, except that you cannot use the long options
form for wcd, only the short-form options.
cc rather than gcc, try
saying make -f WcdMake ccsimple.
make reallysimple. In this case neither long options or inlining
is used. If your compiler is cc then try make -f WcdMake
ccreallysimple.
wcd was tested on a number of different systems. The table below
shows what worked on those systems. With a little tweaking of the
makefile to specify where gcc libraries on your machine are, you
might get the standard make wcd to work too.
With the FreeBSD machine I managed to get the full version to work by finding the appropriate libraries and includes. The same thing probably applies to the others.
This section only need be read if make wcd did not work
and you would like to have long options working.
The non-standard options of wcd are to use inlining and the long
options library. If your system does not support inlining then the
compiler must be given the -DNOINLINE flag when run. If your
system does not provide a library for getting long options then the
compiler must be given the -DNOLONGOPT flag.
If, however, your system does provide a long options library and you
would like to use long options, then you must say where the include file
(‘getopt.h’) and where the library will be. You may also have to
explicitly tell the compiler to use the ‘libtextlib’
library. Find out where these things are, and change the variables in
the WcdMake to the appropriate values and then run
make try. For example, if the include file is in
/usr/share/contrib/gcc and the library is in
/usr/local/lib you might have
INCLUDES = /usr/share/contrib/gcc LIBS = /usr/lib EXTRAFLAGS = gettextlib
You might or might not have the EXTRAFLAGS variable defined.
The makefile assumes that the compiler available is gcc. If it's
not or if you wish to use a different compiler, then edit the file
Makefile and change the definition of the variable CC to
the appropriate compiler.
If this doesn't work, then it may be that your libraries are in non-standard places. Look at the Makefile and try the following things
-g rather
than --histogram)
wcd's MPI and PTHREADS code are optional. In the code there are
macros that protect all references to MPI and PTHREADS. Unless these
macros are defined the compilier won't know about them. This enables
wcd to be compiled without having either libraries.
If you are making manually rather than through configure, and you want
to use MPI or PTHREADS (either or both), then you must make sure that
either (or both) the MPI are PTHREADS macros are defined. You could
either put the relevant defines in the wcd.h file, or pass it to
gcc with something like -D MPI.
EMBOSS wrappers are available from the same source as the wcd
code itself.
A number of auxiliary programs are included. They may be useful but are
not essential. They are either Perl or Python
See Auxiliary Programs, for more details. They should run as is, but if your version
of perl or python is not in a standard place, edit the files and change
their first lines to replace the line that says
#!/usr/bin/perlwith
#!/usr/local/bin/perlor whatever.
In addition to these programs, there is a shell script
wcd_wrapper.sh that allows wcd to be used as a replacement
for d2_cluster in the stackPACK analysis pipeline.
This info file can be read by saying
info -f wcd.info
To create the documentation say ‘make pdf, make html’, etc depending on what sort of document you want. This creates the following:
info system. If the documentation
is installed in the right place on your system you can just say
info wcd, otherwise you will have to say ‘info -f wcd.info’,
or give the full path.
You can play around with ‘makeinfo’ etc. if you want different versions.