Installation Draft

From cctbx_xfel
Revision as of 01:19, 28 February 2015 by Aaron (Talk | contribs)

Jump to: navigation, search


While these tutorials assume you wish to process XTC streams at SLAC, some users have stills collected from other sources and do not need the full PSDM suite. If this is the case, see the installation directions below for installing on a non PSDM system. Otherwise, it is assumed that the PSDM software distribution has been set up. Note again that several sites already have cctbx.xfel installed, and so regular users not involved in the development of the software will not need the instructions here.

Once cctbx.xfel has been installed it must be set up before it can be used. Developers may additionally want to set up an ssh-agent.

Finally, you must have a user account on in order to proceed, or else you will not be able to download the sources.

Standard installation using PSDM

This step has to be performed on a host with Internet access. Not all hosts at SLAC have that, but the members of e.g. pslogin pool do. Make and change to a working directory to contain the new source code and build (this directory should be accessible from any computing nodes cctbx.xfel will be run. Then download these bootstrap modules:

 svn export svn://


 python hot update --builder=xfel --cciuser=<cciusername> --sfuser=<sourceforgeusername>

This command instructs to download static packages required for cctbx.xfel (hot), and then to checkout the rest of the sources from and (update), using the user accounts specified by the cciuser and sfuser parameters, respectively.

After downloading the sources, you need to be sure you have the appropriate compilers before executing the next command. At SLAC, that means you need to ssh to one of the psana nodes, as the pslogin nodes do not have the requisite compilers. When ready, configure and compile thusly:

 python build --builder=xfel --with-python=`which python`

On SLAC's interactive nodes, this takes just over 6 minutes. To avoid problems with run-time dynamic linking of Python extensions, the Python interpreter required for the above command must be the one provided by the PSDM software distribution. That interpreter can be located using find, e.g.

$ find $SIT_ROOT/sw/external/python -perm /0111 -type f -wholename "*/$SIT_ARCH/*/python" 2> /dev/null

At SLAC this interpreter is located somewhere under /reg/g/psdm/sw/external/python. Here we use `which python` to get this path automatically.

Initialise the running shell using the newly created configuration files. bash-users should

$ . build/

while csh-users will instead need to run

% source build/setpaths.csh

To finalize the installation, see Setup.

Note, you may also follow this procedure if you are on a machine where you have your own python that you want to use, instead of the one provided by PSDM.

Installation on a non-PSDM system

If you find yourself on a machine without PSDM and won't be dealing with XTC directly, for example if you have your own data collected as stills from a non-XFEL source, you can use the below commands in a new directory (again assuming you have a cci user account):

 svn export svn://
 python hot update base build --builder=xfel --cciuser=<cciusername> --sfuser=<sourceforgeusername>

Here, in addition to hot, update and build, there's a command called 'base', which downloads a python and needed packages and compiles it. After this process completes, source the installation, and then add scipy to it:

. build/ libtbx.python -m easy_install scipy

Please contact the authors if with any issues. Some gotchas:

1) On a mac, you will need to make sure you have the latest version of xcode installed. Consider the command xcode-select --install.

2) On linux you will likely need to install some dependencies, including gFortran.

External links