Difference between revisions of "HowTo:namd"
(→Running NWChem from a command line) |
(→Submitting (parallel) NWChem jobs) |
||
Line 43: | Line 43: | ||
This will run your sample.nw input file on eight processors. Note that you are only allowed to run NWChem this way for small test systems! For any production jobs, you have to submit the task to the scheduler (see next section.). | This will run your sample.nw input file on eight processors. Note that you are only allowed to run NWChem this way for small test systems! For any production jobs, you have to submit the task to the scheduler (see next section.). | ||
− | == Submitting (parallel) | + | == Submitting (parallel) NAMD jobs == |
− | + | Only short test jobs of application software can be run interactively on HPCVL machines. Production jobs must be submitted via the scheduling software Grid Engine. For usage of this software, please consult our [[FAQ:SGE|Grid Engine FAQ]]. | |
+ | |||
+ | In most cases, you will be running NAMD production jobs in parallel mode. This means that you need to specify a number of CPUs that should be reserved to run each independent NAMD thread. This is done in a Grid Engine submission script: | ||
− | |||
<pre> | <pre> | ||
+ | #!/bin/bash | ||
#$ -S /bin/bash | #$ -S /bin/bash | ||
#$ -q abaqus.q | #$ -q abaqus.q | ||
#$ -l qname=abaqus.q | #$ -l qname=abaqus.q | ||
− | |||
− | |||
− | |||
− | |||
#$ -V | #$ -V | ||
#$ -cwd | #$ -cwd | ||
− | #$ -pe | + | #$ -M {email address} |
− | + | #$ -m be | |
− | </pre> | + | #$ -o {screen output file} |
− | + | #$ -e {screen error file} | |
+ | #$ -pe shm.pe {number of threads} | ||
+ | namd2 +p$NSLOTS {namd configuration (input) file} | ||
+ | </pre> | ||
+ | |||
+ | The items in the template that are enclosed in {} be replaced by the appropriate values. Lines that start with "#$" contain information for Grid Engine. The "#$ -V" line tells GE to inherit the shell setup from the calling shell, for instance the $PATH variable. It is important to remember that you need to set up NAMD by issuing the "use namd" command before submitting the above script. | ||
− | + | "#$ -cwd" tells the system to start from the current working directory. "#$ -M" lets the system know you email address, so it can notify you when the job starts and ends. The "#$ -o" and "#$ -e" lines are there to define files that capture output that would go to the screen in an interactive run, coming from the program and the system, repsectively. Finally, the "#$ -pe" line serves to define the number of CPUs to be reserved. The number you insert here will be reused through the environment variable $NSLOTS, so that you do not have to type it again in the namd2 command line. | |
− | + | Note that the name of the configuration file that replaces "configuration file" in the script template, should have file extension .namd, just as in the interactive run. | |
− | + | Once you have a proper script file (let's call it namd.sh) you can submit your production job by typing | |
− | + | <pre>qsub namd.sh</pre> | |
− | + | The Grid Engine will take care of the rest. | |
− | |||
|} | |} | ||
{| style="border-spacing: 8px;" | {| style="border-spacing: 8px;" |
Revision as of 17:48, 14 June 2016
Contents
NAMD
This is a quick introduction to the usage of the free but licensed code NAMD2 that is installed on our clusters. It is meant as an initial pointer to more detailed information and a Getting Started primer. It does not replace study of the manual.
FeaturesNAMD is a parallel code for molecular dynamics simulation of large biomolecular systems, developed by the Theoretical Biophysics Group ("TBG") in the Beckman Institute of the University of Illinois . It is file-compatible with AMBER, CHARMM, and X-PLOR. Location of the program and setupThe binary executable is in /opt/namd on the HPCVL Clusters. The present version of the program is 2.10, and it is available on the Linux platform in its 64 bit version. Therefore, all the relevant executables are in /opt/namd/2.10. Documentation can be found at the main NAMD site and a simple example (Alanin) is in /opt/namd/2.10/example. The setup for NAMD is very simple. It is only necessary type : use namd This will enter the proper directory into your PATH and off you go. |
Running NWChem from a command lineNAMD requires a number of input files to run. These include:
Details about the supported format of these input files can be found in the NAMD User's Guide. NAMD supports several running modes. In the simplest case, it can be run in serial mode by typing: namd2 config_file where config_file is the configuration input file mentioned above. It is recommended to give the configuration file the file extension .namd to enable consistent naming of the output files. These will be generated automatically, and the progress of the program run will be tracked on the screen. NAMD is also able to run in parallel mode. For our shared-memory systems, it is easiest to run it by specifying the number of threads through the +p option: namd2 +pN config_file if N threads are requested. Parallel RunsNWChem is inherently parallelized and designed to scale well on a multi-processor machine or a cluster. The underlying parallel system is MPI (Message Passing Interface) which is a commonly available standard that runs on many platforms. Consult our MPI help file and follow some of the links in there if you want to have more information about MPI. Even if you want to use only one processor for your NWChem run (which sometimes is the best solution, particularly for smaller computations), you have to submit the program to a parallel environment. On our clusters, the relevant command is mpirun: mpirun -np 8 nwchem sample > sample.log This will run your sample.nw input file on eight processors. Note that you are only allowed to run NWChem this way for small test systems! For any production jobs, you have to submit the task to the scheduler (see next section.). Submitting (parallel) NAMD jobsOnly short test jobs of application software can be run interactively on HPCVL machines. Production jobs must be submitted via the scheduling software Grid Engine. For usage of this software, please consult our Grid Engine FAQ. In most cases, you will be running NAMD production jobs in parallel mode. This means that you need to specify a number of CPUs that should be reserved to run each independent NAMD thread. This is done in a Grid Engine submission script: #!/bin/bash #$ -S /bin/bash #$ -q abaqus.q #$ -l qname=abaqus.q #$ -V #$ -cwd #$ -M {email address} #$ -m be #$ -o {screen output file} #$ -e {screen error file} #$ -pe shm.pe {number of threads} namd2 +p$NSLOTS {namd configuration (input) file} The items in the template that are enclosed in {} be replaced by the appropriate values. Lines that start with "#$" contain information for Grid Engine. The "#$ -V" line tells GE to inherit the shell setup from the calling shell, for instance the $PATH variable. It is important to remember that you need to set up NAMD by issuing the "use namd" command before submitting the above script. "#$ -cwd" tells the system to start from the current working directory. "#$ -M" lets the system know you email address, so it can notify you when the job starts and ends. The "#$ -o" and "#$ -e" lines are there to define files that capture output that would go to the screen in an interactive run, coming from the program and the system, repsectively. Finally, the "#$ -pe" line serves to define the number of CPUs to be reserved. The number you insert here will be reused through the environment variable $NSLOTS, so that you do not have to type it again in the namd2 command line. Note that the name of the configuration file that replaces "configuration file" in the script template, should have file extension .namd, just as in the interactive run. Once you have a proper script file (let's call it namd.sh) you can submit your production job by typing qsub namd.sh The Grid Engine will take care of the rest. |
LicensingNWChem is obtainable free of charge from the Pacific Northwest National Laboratory. To obtain your own copy, go here. NWChem is ditributed under an Open Source Educational Community License. Like with other software, HPCVL requires users who want to use NWChem, to read this agreement, and sign a statement that they have done so and will abide by its terms. You can fax the signed statement to (613) 533-2015 or scan/email it to cac.admin@queensu.ca. You will then be included in a Unix user group that has access to the NWChem executables. More InformationNWChem is a very complex software package, and requires practice to be used efficiently. We cannot explain it use in any detail here.
|