Broadband Platform Installation 16 5 0

From SCECpedia
Revision as of 21:46, 18 May 2016 by Fsilva (talk | contribs) (Created page with "Please follow the instructions on this page to manually download and install the Broadband Platform Release 16.5.0. == Mac OS X Installation == Mac OS X users should refer t...")
(diff) ← Older revision | Latest revision (diff) | Newer revision → (diff)
Jump to navigationJump to search

Please follow the instructions on this page to manually download and install the Broadband Platform Release 16.5.0.

Mac OS X Installation

Mac OS X users should refer to our BBP on OS X Guide 16 5 for installing the above dependencies to their system. After completing the steps on that guide, please return to this page and continue reading these installation instructions to finalize the Broadband Platform setup.

User Account Setup

For simplicity of installation, we recommend users use a bash shell for the Broadband Platform account. It is possible to get the platform running using other shell's, but we will focus on a bash shell installation. The user environment is a common source of problems since certain environment variables must be defined for the platform to work correctly.

To check your account, make sure you can run basic commands like ls and cd before proceeding.

Downloading the Platform

Download the main Broadband distribution file from the Broadband website. Users should also download the Greens' Functions files for the regions where simulations will be performed. Currently the platform supports the following regions:

  • LABasin (this package is required to run the Unit and Acceptance tests)
  • Mojave
  • NoCal
  • Western Japan
  • Central Japan
  • Eastern North America
  • Eastern Canada

Additionally, users can optionally download validation packages for the following recorded events:

  • Northridge (requires the LABasin GF package, this package is required to run the Acceptance tests)
  • Loma Prieta (requires the NoCal GF package)

The installation instructions given later include a script that will confirm that the BBP files have been copied intact and unchanged onto your computer.

The minimum set up files from the BBP web site required for the Broadband Platform installation are:

  • bbp-dist-16.5.0.tar.gz
  • labasin-velocity-model-16.5.0.tar.gz
  • northridge-validation-16.5.0.tar.gz

If multiple users are planning to use the platform on the same system, you only need one copy of the data files per machine. Each user will still need his or her own copy of the code files.

Alternatively, if you would like access to the latest version of the platform and get frequent but less thoroughly tested improvements, you can check out the platform from SCEC's Subversion repository. Only advanced users should take this approach, outlined in detail in the Advanced Users section.

Broadband Platform Directory Structure Setup

After confirming that all downloaded files are good, it is time to set up the directory structure used by the Broadband Platform. Start by creating a top-level directory for the Broadband Platform installation. In our example, we will use 'bbp' as this top-level directory. Assuming this directory will be installed in for the user "sarah":

$ cd /home/sarah
$ mkdir bbp
$ cd bbp

Now, untar the main Broadband distribution file (assuming all downloaded files are located in /home/sarah/downloads):

$ tar -xzvf /home/sarah/downloads/bbp-dist-16.5.0.tar.gz

This will create the "16.5.0" directory with the main distribution content. Now, create 2 more directories: one for the downloaded Greens' Functions and another for the optional Validation packages:

$ mkdir bbp_gf
$ mkdir bbp_val

Go into the bbp_gf directory and untar each of the downloaded GF packages:

$ cd bbp_gf

For the LABasin package, the command would be:

$ tar -xzvf /home/sarah/downloads/labasin-velocity-model-16.5.0.tar.gz

Please untar any other GF packages that you desire to install.

Now, we need to do the same thing for the validation packages. Switch to the bbp_val directory and install any validation packages that were downloaded. For example, to install the Northridge validation package, users will need to:

$ cd /home/sarah/bbp/bbp_val
$ tar -xzvf /home/sarah/downloads/northridge-validation-16.5.0.tar.gz

We are almost ready now. Users will need to create another directory, which will contain all the simulations that will be generated by the Broadband Platform. In this example, we will use "bbp_data", and will place it along with the other directories that we created above, using the commands:

$ cd /home/sarah/bbp
$ mkdir bbp_data

The last step before we can proceed is to set up environment variables indicating where each of the above directories are located so that the Broadband Platform can find their locations. Using the example above, users will need to set up the following 6 environment variables. Just add the following lines to your .bash_profile file:

export BBP_DIR=/home/sarah/bbp/16.5.0/bbp
export BBP_GF_DIR=/home/sarah/bbp/bbp_gf
export BBP_VAL_DIR=/home/sarah/bbp/bbp_val
export BBP_DATA_DIR=/home/sarah/bbp/bbp_data
export PYTHONPATH=$BBP_DIR/comps:$PYTHONPATH
export PATH=$BBP_DIR/comps:$BBP_DIR/utils/batch:$PATH

Note that users may need to log out and log in again in order for this change to take effect.

Building the Platform

Once users have downloaded and untar'ed the code and supporting packages, the final step is to compile the Broadband Platform. In order to successfully compile the project, you'll need to make sure the required compilers directories are in your PATH variable. Broadband requires the GNU Compilers, gcc, and gfortran to compile the scientific code. Using the example provided in the section above, users will need to go to the 'src' directory and compile the code. Before trying to compile the code, users can use the following command to make sure the needed compilers are present in their path:

$ which gcc

If you get a message like "no gcc in path" you will need to add the GNU compilers to your path. Once that is done, you can compile the code using the following commands:

$ cd /home/sarah/bbp/16.5.0/bbp/src
$ make clean
$ make

This will take a few minutes, and once it is done, you are ready to start using the Broadband Platform!