Broadband Platform Manual Installation 16 5 0

From SCECpedia
Revision as of 03:17, 25 May 2016 by Maechlin (talk | contribs)
Jump to navigationJump to search

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

Broadband Platform Easy Installation

This section provides a brief overview of how the Broadband Platform can be installed on your local Linux or Mac OS X computer. It covers the Easy Installation method, where users download and run a shell script that downloads the other components based on user responses. Users are welcome to set up the Broadband Platform manually on their systems using the old installation instructions described in the Broadband_Platform_Manual_Installation_16_5_0 page.

Starting with this version of the Broadband Platform, we provide an easy installation script that can guide users through downloading and installing the Broadband Platform on a Linux or Mac OS X computer that meets the system requirements for the Broadband Platform. For this method, users need to download the BBP 16.5.0 Easy Install Script. Once that script is downloaded, users should:

$ chmod +x easy_install_bbp_16.5.0.sh
$ ./easy_install_bbp_16.5.0.sh <directory>

The script will automatically create a "bbp" subdirectory, where it will install the Broadband Platform. To install the Broadband Platform in the current directory, users can simply type:

$ ./easy_install_bbp_16.5.0.sh .
====== Welcome to Broadband Platform 16.5.0 installation script =====

 Using destination directory: /home/sarah

=> Main Broadband Platform Source Distribution
==> Downloading...
==> Compiling...
==> Installed!

The easy installation script will automatically download and compile the main source distribution. Following that, it will ask users to select which regions should be installed along with the Platform. Please note that saying "Yes" to a region, will automatically install any validation events available for that region. At a minimum, and in order to run Unit and Acceptance tests, users should say "Yes" to the "LA Basin" region.

Please select what velocity models (regions) you would like to install:

==> Would you like to install the Northern California region?
1) Yes
2) No
#?2

==> Would you like to install the LA Basin region?
1) Yes
2) No
#? 1

...
...
...

=> Installing Broadband Platform Velocity Model Packages
==> LA Basin
==> Completed!
=> Installing Broadband Platform Validation Packages
==> Northridge
==> GMPEs
==> Completed!

=> All Done!

Please add the following lines to your bash_profile:

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 PYTHONPATH=/home/sarah/bbp/16.5.0/bbp/comps
export BBP_DATA_DIR=/home/sarah/bbp/bbp_data
export PATH=/home/sarah/bbp/16.5.0/bbp/comps:/home/sarah/bbp/16.5.0/bbp/utils/batch:$PATH

After installing the Broadband Platform on their systems, users should confirm the code is built correctly by running Unit tests and then Acceptance tests before starting to use the code for research purposes. For detailed information, please refer to the Broadband User Guide v16.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 using the links below:

To install and use the Broadband platform, you need the source code, one or more Green's Functions packages, and optionally one or more Validation packages. The Broadband Platform contains cumulative improvements to the geoscientific codes and software infrastructure. We recommend use of the most recent version of the Broadband Platform, unless you are trying to reproduce results generated with an earlier version of the platform.

Users that are upgrading from previous version of the Broadband Platform will need to retrieve new versions of all the Broadband Platform packages as there have been significant changes in all the packages since the previous 15.3.0 release.

Required Files

The following packages are the minimum set of files required to run the Broadband Platform. This set includes files needed for running the Unit and Acceptance tests.

  • Source Distribution (59MB): BBP 16.5.0
  • LA Basin Model (5.8GB): LA Basin (Needed for Unit and Acceptance Tests)
  • Northridge Validation Event (17MB): Northridge (Needed for Acceptance Tests)

Additional Regions/Velocity Models

The following packages are optional downloads. Users should download packages for the regions they are interested in.

GMPE Verification Pacakges

Additional Validation Events

Please log into the private wiki to download additional validation events.

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!