Changes between Version 1 and Version 2 of BuildingRoms


Ignore:
Timestamp:
05/30/07 14:42:46 (17 years ago)
Author:
csherwood
Comment:

--

Legend:

Unmodified
Added
Removed
Modified
  • BuildingRoms

    v1 v2  
    771. Make a project directory
    88On our Opteron cluster, I have one directory where I keep the source code
    9 
    10 /home/rsignell/models/roms_rutgers/trunk
    11 
     9{{{/home/rsignell/models/roms_rutgers/trunk}}}
    1210and another where I actually do model runs
    13 
    14 /home/rsignell/projects/
     11{{{/home/rsignell/projects/}}}
    1512
    1613So on my system, for a new test, I make a directory called
    17 
    18 /home/rsignell/projects/test1
     14{{{/home/rsignell/projects/test1}}}
    1915
    20162. Checkout the source code using SVN (or unpack the source code if
    21 you grabbed my tarfile) and copy the "build.sh" script (which you will
    22 find in ./ROMS/Bin subdirectory) to your project directory.
     17you grabbed my tarfile) and copy the {{{build.sh}}} script (which you will
     18find in {{{./ROMS/Bin}}} subdirectory) to your project directory.
    2319
    24 3. Edit "build.sh"
     203. Edit {{{build.sh}}}
    2521
    26 I  edit "build.sh" to specify:
     22I  edit {{{build.sh}}} to specify:
     23{{{
    2724MY_ROMS_APPLICATION=LAKE_SIGNELL
    2825MY_ROMS_SRC=/home/rsignell/models/roms_rutgers/trunk
    2926MY_PROJECT_DIR=/home/rsignell/projects/test1
    30 
    31 and set which compiler I want to use (e.g. pgi, ifort) and what type
     27}}}
     28and set which compiler I want to use (e.g. {{{pgi}}}, {{{ifort}}}) and what type
    3229of executable I want (MPI, OpenMP, or Serial)
    3330
    3431Even though I use the pgi compiler on our cluster, I actually build
    35 MPI code using the "mpif90" script, so I set USE_MPIF90 on as well as
    36 pgi.
     32MPI code using the {{{mpif90}}} script, so I set {{{USE_MPIF90}}} on as well as
     33{{{pgi}}}.
    3734
    38354. Compile.
    39 Run the build.sh script.  If you have more than one processor on the
    40 machine you are compiling on you can use the -j option to build
     36Run the {{{build.sh}}} script.  If you have more than one processor on the
     37machine you are compiling on you can use the {{{-j}}} option to build
    4138faster.  For example, to use 2 cpus:
    42 
     39{{{
    4340./build.sh -j2
    44 
     41}}}
    45425. Set up the input files for the run
    4643ROMS uses an ASCII input file to specify some of the run parameters,
    47 and we use the ".in" extension by convention to indicate these files.
    48  For the test cases, these are found in the ~/ROMS/External directory.
    49  So to run ROMS from our project directory, we need to copy over the
    50 right input file for the LAKE_SIGNELL case.  We also want a copy of
    51 varinfo.dat, which defines NetCDF parameters.
    52 
     44and we use the {{{.in}}} extension by convention to indicate these files.
     45For the test cases, these are found in the {{{~/ROMS/External directory}}}.
     46So to run ROMS from our project directory, we need to copy over the
     47right input file for the {{{LAKE_SIGNELL}}} case.  We also want a copy of
     48{{{varinfo.dat}}}, which defines NetCDF parameters.
     49{{{
    5350cp ~/models/ROMS/External/{ocean_lake_signell.in,varinfo.dat} ~/projects/test1
    54 
    55 6. Run
    56 ./oceanS < ocean_lake_signell.in  (Serial)
    57 ./oceanO < ocean_lake_signell.in  (OpenMP)
    58 mpirun -n 16 -hostfile node_file ./oceanM lake_signell.in   (MPI)
     51}}}
     526. Run.
     53{{{./oceanS < ocean_lake_signell.in}}}  (Serial)
     54{{{./oceanO < ocean_lake_signell.in}}}  (OpenMP)
     55{{{mpirun -n 16 -hostfile node_file ./oceanM lake_signell.in}}}   (MPI)