Difference between revisions of "Ha14 installation"

From cctbx_xfel
Jump to: navigation, search
(Unified prerequisites for regular users and developers.i)
(Cleanup.)
Line 15: Line 15:
 
  $ tar -xpvzf cctbx_bundle.tar.gz -C cctbx_project --strip-components=1
 
  $ tar -xpvzf cctbx_bundle.tar.gz -C cctbx_project --strip-components=1
 
  $ tar -xpvzf labelit_bundle_20130814.tar.gz
 
  $ tar -xpvzf labelit_bundle_20130814.tar.gz
 
<!-- XXX Nightly bundles are stored in /net/cci/auto_build/cctbx/results -->
 
  
 
{{ mbox
 
{{ mbox
Line 22: Line 20:
 
| text = New bundles are automatically prepared nightly. It is, however, not advisable to automatically update from the latest bundle. Please check with the program authors before upgrading a critical installation.  Also note that the labelit_bundle cannot currently be downloaded.
 
| text = New bundles are automatically prepared nightly. It is, however, not advisable to automatically update from the latest bundle. Please check with the program authors before upgrading a critical installation.  Also note that the labelit_bundle cannot currently be downloaded.
 
}}
 
}}
 +
 +
<!-- Nightly bundles are stored in /net/cci/auto_build/cctbx/results.  The script to generate the labelit bundles is at ~/projects/doc/make_labelit_source_bundle.sh. -->
  
 
=== Developers ===
 
=== Developers ===
<!-- XXX Why is this PHENIX when we really want cctbx.xfel -->
 
 
A user account on cci.lbl.gov is required, the name of which is to be substituted for <code><b><i>user</i></b></code> below.  
 
A user account on cci.lbl.gov is required, the name of which is to be substituted for <code><b><i>user</i></b></code> below.  
 
  $ mkdir -p <b><i>/path/to/cctbx/sources</i></b>
 
  $ mkdir -p <b><i>/path/to/cctbx/sources</i></b>
Line 71: Line 70:
 
On SLAC's interactive nodes, this takes just over 6 minutes.  To finalize the installation, see [[Setup]].
 
On SLAC's interactive nodes, this takes just over 6 minutes.  To finalize the installation, see [[Setup]].
  
<!-- It used to be necessary to run make twice, but that seems to no longer be the case. XXX Maybe should include a bit on running the regression tests here? -->
+
<!-- XXX Long-standing gremlin: it appears that for initial installs, it is necessary to run make twice! XXX Maybe should include a bit on running the regression tests here? -->
  
  
Line 80: Line 79:
  
 
<!-- POSSBILE ADDITIONS:
 
<!-- POSSBILE ADDITIONS:
 
HOW TO KEEP UP TO DATE (links to psdm page, links to developers page: these pages assemble all the information in one place).
 
  
 
COMMON PITFALLS:
 
COMMON PITFALLS:

Revision as of 11:02, 7 February 2014

Prerequisite: install and set up the PSDM suite

It is assumed that the PSDM software distribution has been set up. Developers may additionally want to set up an ssh-agent. Note again that several sites already have cctbx.xfel installed, and that this step can be skipped for regular users not involved in the development of the software. Once cctbx.xfel has been installed it must be set up before it can be used.

Download and extract a source tree

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. psexport pool do. In what follows, the absolute path /path/to/cctbx/sources should be replaced with something more appropriate (a site-wide install will benefit from a location on a shared disk, whereas ~/projects/phenix-src is a common choice among developers). The directory must accessible everywhere cctbx.xfel is to be run.

Regular users

$ mkdir -p /path/to/cctbx/sources
$ cd /path/to/cctbx/sources
$ wget http://cci.lbl.gov/cctbx_build/results/2013_08_13_0005/cctbx_bundle.tar.gz
$ wget http://cci.lbl.gov/~hattne/labelit/labelit_bundle_20130814.tar.gz
$ mkdir cctbx_project
$ tar -xpvzf cctbx_bundle.tar.gz -C cctbx_project --strip-components=1
$ tar -xpvzf labelit_bundle_20130814.tar.gz

{{#invoke:Message box|mbox}}


Developers

A user account on cci.lbl.gov is required, the name of which is to be substituted for user below.

$ mkdir -p /path/to/cctbx/sources
$ cd /path/to/cctbx/sources
$ svn export svn+ssh://user@cci.lbl.gov/phenix_regression/trunk/phenix_svn_getting_started.csh
$ ./phenix_svn_getting_started.csh user
$ rm phenix_svn_getting_started.csh


Create the cxi_user directory

Add the cxi_user directory and its __init__.py module. This defines the default integration algorithm used by cctbx.xfel.

$ mkdir cxi_user
$ cat > cxi_user/__init__.py << EOF
from xfel.mono_simulation.mono_treatment import post_outlier_rejection
from xfel.mono_simulation.mono_treatment import pre_get_predictions
EOF

Configure the source tree

To avoid problems with run-time dynamic linking of Python extensions, the Python interpreter required for the next step 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. Then create and initialize the build directory, /path/to/cctbx/build below, using the Python interpreter located using the above find command. The build directory is often located next to the source directory (~/projects/phenix-build is a common developer choice).

Regular users

$ mkdir -p /path/to/cctbx/build
$ cd /path/to/cctbx/build
$ python /path/to/cctbx/sources/cctbx_project/libtbx/configure.py xfel

Developers

$ mkdir -p /path/to/cctbx/build
$ cd /path/to/cctbx/build
$ python /path/to/cctbx/sources/cctbx_project/libtbx/configure.py cxi_xdr_xes labelit_regression phenix xfel


Compile the sources

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

$ . setpaths.sh

while csh-users will instead need to run

% source setpaths.csh

The next step requires a C++ compiler. At SLAC, the members of the psexport pool do not have any compilers installed, but the interactive nodes, reachable via psanacs, do.

$ cd /path/to/cctbx/build
$ make

On SLAC's interactive nodes, this takes just over 6 minutes. To finalize the installation, see Setup.


External links