[Dart-dev] [6185] DART/branches/development/models/dynamo: Update the code so this model interface compiles again.
nancy at ucar.edu
nancy at ucar.edu
Wed May 29 10:17:40 MDT 2013
Revision: 6185
Author: nancy
Date: 2013-05-29 10:17:40 -0600 (Wed, 29 May 2013)
Log Message:
-----------
Update the code so this model interface compiles again.
Modified Paths:
--------------
DART/branches/development/models/dynamo/gau_param.f90
DART/branches/development/models/dynamo/model_mod.f90
DART/branches/development/models/dynamo/work/path_names_create_fixed_network_seq
DART/branches/development/models/dynamo/work/path_names_dart_to_model
DART/branches/development/models/dynamo/work/path_names_dobsdx
DART/branches/development/models/dynamo/work/path_names_filter
DART/branches/development/models/dynamo/work/path_names_gau_param
DART/branches/development/models/dynamo/work/path_names_model_to_dart
DART/branches/development/models/dynamo/work/path_names_perfect_model_obs
DART/branches/development/models/dynamo/work/path_names_x_plus_delta
Added Paths:
-----------
DART/branches/development/models/dynamo/work/mkmf_preprocess
DART/branches/development/models/dynamo/work/path_names_preprocess
DART/branches/development/models/dynamo/work/quickbuild.csh
-------------- next part --------------
Modified: DART/branches/development/models/dynamo/gau_param.f90
===================================================================
--- DART/branches/development/models/dynamo/gau_param.f90 2013-05-29 16:12:35 UTC (rev 6184)
+++ DART/branches/development/models/dynamo/gau_param.f90 2013-05-29 16:17:40 UTC (rev 6185)
@@ -1,9 +1,9 @@
! Update vector with a Gaussian noise.
-! x(i) *= (1. + G * gasdev)
+! x(i) *= (1. + G * gaussian)
module gau_param
-use random_nr_mod, only : random_seq_type, init_ran1, gasdev
+use random_seq_mod, only : random_seq_type, init_random_seq, random_gaussian
implicit none
@@ -53,9 +53,10 @@
integer :: i, getpid, tempr
tempr = mod(getpid(),54000)
-call init_ran1(sr, tempr)
+call init_random_seq(sr, tempr)
do i = 1, model_size
- x(i) = x(i)*(1._r8 + G * gasdev(sr)) ! Advance the parameter with a Gaussian noise
+ ! Advance the parameter with a Gaussian noise
+ x(i) = x(i)*(1._r8 + G * random_gaussian(sr, 0.0_r8, 1.0_r8))
end do
end subroutine march_ahead
Modified: DART/branches/development/models/dynamo/model_mod.f90
===================================================================
--- DART/branches/development/models/dynamo/model_mod.f90 2013-05-29 16:12:35 UTC (rev 6184)
+++ DART/branches/development/models/dynamo/model_mod.f90 2013-05-29 16:17:40 UTC (rev 6185)
@@ -21,7 +21,7 @@
use utilities_mod, only : register_module, error_handler, E_ERR, E_MSG, nmlfileunit, &
do_output, find_namelist_in_file, check_namelist_read, &
do_nml_file, do_nml_term
-use random_nr_mod, only : random_seq_type, init_ran1, ran1, gasdev
+use random_seq_mod, only : random_seq_type, init_random_seq, random_uniform, random_gaussian
use mpi_utilities_mod, only : my_task_id
implicit none
@@ -170,7 +170,7 @@
real(r8), intent(out) :: x(:)
tempr = mod(getpid(),54000)
-call init_ran1(sr, tempr)
+call init_random_seq(sr, tempr)
open(99,file='perfect_ics',status='old',iostat=err)
if(err.eq.0)read(99,*)
do i = 1, model_size
@@ -201,7 +201,7 @@
real(r8) :: fract
fract = 1.0_r8
-x(1) = x(1) + 0.01 * gasdev(sr)
+x(1) = x(1) + 0.01 * random_gaussian(sr, 0.0_r8, 1.0_r8)
call get_time(time,sec,days)
our_time = float(days)*deltat
counter = counter + 1
Added: DART/branches/development/models/dynamo/work/mkmf_preprocess
===================================================================
--- DART/branches/development/models/dynamo/work/mkmf_preprocess (rev 0)
+++ DART/branches/development/models/dynamo/work/mkmf_preprocess 2013-05-29 16:17:40 UTC (rev 6185)
@@ -0,0 +1,18 @@
+#!/bin/csh
+#
+# DART software - Copyright 2004 - 2011 UCAR. This open source software is
+# provided by UCAR, "as is", without charge, subject to all terms of use at
+# http://www.image.ucar.edu/DAReS/DART/DART_download
+#
+# $Id$
+
+../../../mkmf/mkmf -p preprocess -t ../../../mkmf/mkmf.template -c"-Duse_netCDF" \
+ -a "../../.." path_names_preprocess
+
+exit $status
+
+# <next few lines under version control, do not edit>
+# $URL$
+# $Revision$
+# $Date$
+
Property changes on: DART/branches/development/models/dynamo/work/mkmf_preprocess
___________________________________________________________________
Added: svn:executable
+ *
Added: svn:mime-type
+ text/plain
Added: svn:keywords
+ Date Rev Author HeadURL Id
Added: svn:eol-style
+ native
Modified: DART/branches/development/models/dynamo/work/path_names_create_fixed_network_seq
===================================================================
--- DART/branches/development/models/dynamo/work/path_names_create_fixed_network_seq 2013-05-29 16:12:35 UTC (rev 6184)
+++ DART/branches/development/models/dynamo/work/path_names_create_fixed_network_seq 2013-05-29 16:17:40 UTC (rev 6185)
@@ -2,13 +2,12 @@
common/types_mod.f90
cov_cutoff/cov_cutoff_mod.f90
location/oned/location_mod.f90
-models/iface/model_mod.f90
+models/dynamo/model_mod.f90
mpi_utilities/null_mpi_utilities_mod.f90
obs_def/obs_def_mod.f90
obs_kind/obs_kind_mod.f90
obs_sequence/create_fixed_network_seq.f90
obs_sequence/obs_sequence_mod.f90
-random_nr/random_nr_mod.f90
random_seq/random_seq_mod.f90
time_manager/time_manager_mod.f90
utilities/utilities_mod.f90
Modified: DART/branches/development/models/dynamo/work/path_names_dart_to_model
===================================================================
--- DART/branches/development/models/dynamo/work/path_names_dart_to_model 2013-05-29 16:12:35 UTC (rev 6184)
+++ DART/branches/development/models/dynamo/work/path_names_dart_to_model 2013-05-29 16:17:40 UTC (rev 6185)
@@ -1,10 +1,9 @@
assim_model/assim_model_mod.f90
common/types_mod.f90
location/oned/location_mod.f90
-models/iface/dart_to_model.f90
-models/iface/model_mod.f90
+models/dynamo/dart_to_model.f90
+models/dynamo/model_mod.f90
mpi_utilities/null_mpi_utilities_mod.f90
-random_nr/random_nr_mod.f90
random_seq/random_seq_mod.f90
time_manager/time_manager_mod.f90
utilities/utilities_mod.f90
Modified: DART/branches/development/models/dynamo/work/path_names_dobsdx
===================================================================
--- DART/branches/development/models/dynamo/work/path_names_dobsdx 2013-05-29 16:12:35 UTC (rev 6184)
+++ DART/branches/development/models/dynamo/work/path_names_dobsdx 2013-05-29 16:17:40 UTC (rev 6185)
@@ -1 +1 @@
-models/iface/dobsdx.f90
+models/dynamo/dobsdx.f90
Modified: DART/branches/development/models/dynamo/work/path_names_filter
===================================================================
--- DART/branches/development/models/dynamo/work/path_names_filter 2013-05-29 16:12:35 UTC (rev 6184)
+++ DART/branches/development/models/dynamo/work/path_names_filter 2013-05-29 16:17:40 UTC (rev 6185)
@@ -6,13 +6,12 @@
ensemble_manager/ensemble_manager_mod.f90
filter/filter.f90
location/oned/location_mod.f90
-models/iface/model_mod.f90
+models/dynamo/model_mod.f90
mpi_utilities/null_mpi_utilities_mod.f90
obs_def/obs_def_mod.f90
obs_kind/obs_kind_mod.f90
obs_model/obs_model_mod.f90
obs_sequence/obs_sequence_mod.f90
-random_nr/random_nr_mod.f90
random_seq/random_seq_mod.f90
reg_factor/reg_factor_mod.f90
smoother/smoother_mod.f90
Modified: DART/branches/development/models/dynamo/work/path_names_gau_param
===================================================================
--- DART/branches/development/models/dynamo/work/path_names_gau_param 2013-05-29 16:12:35 UTC (rev 6184)
+++ DART/branches/development/models/dynamo/work/path_names_gau_param 2013-05-29 16:17:40 UTC (rev 6185)
@@ -1,5 +1,5 @@
-models/iface/gau_param.f90
+models/dynamo/gau_param.f90
mpi_utilities/null_mpi_utilities_mod.f90
-random_nr/random_nr_mod.f90
random_seq/random_seq_mod.f90
+time_manager/time_manager_mod.f90
utilities/utilities_mod.f90
Modified: DART/branches/development/models/dynamo/work/path_names_model_to_dart
===================================================================
--- DART/branches/development/models/dynamo/work/path_names_model_to_dart 2013-05-29 16:12:35 UTC (rev 6184)
+++ DART/branches/development/models/dynamo/work/path_names_model_to_dart 2013-05-29 16:17:40 UTC (rev 6185)
@@ -1,10 +1,9 @@
assim_model/assim_model_mod.f90
common/types_mod.f90
location/oned/location_mod.f90
-models/iface/model_mod.f90
-models/iface/model_to_dart.f90
+models/dynamo/model_mod.f90
+models/dynamo/model_to_dart.f90
mpi_utilities/null_mpi_utilities_mod.f90
-random_nr/random_nr_mod.f90
random_seq/random_seq_mod.f90
time_manager/time_manager_mod.f90
utilities/utilities_mod.f90
Modified: DART/branches/development/models/dynamo/work/path_names_perfect_model_obs
===================================================================
--- DART/branches/development/models/dynamo/work/path_names_perfect_model_obs 2013-05-29 16:12:35 UTC (rev 6184)
+++ DART/branches/development/models/dynamo/work/path_names_perfect_model_obs 2013-05-29 16:17:40 UTC (rev 6185)
@@ -5,14 +5,13 @@
cov_cutoff/cov_cutoff_mod.f90
ensemble_manager/ensemble_manager_mod.f90
location/oned/location_mod.f90
-models/iface/model_mod.f90
+models/dynamo/model_mod.f90
mpi_utilities/null_mpi_utilities_mod.f90
obs_def/obs_def_mod.f90
obs_kind/obs_kind_mod.f90
obs_model/obs_model_mod.f90
obs_sequence/obs_sequence_mod.f90
perfect_model_obs/perfect_model_obs.f90
-random_nr/random_nr_mod.f90
random_seq/random_seq_mod.f90
reg_factor/reg_factor_mod.f90
sort/sort_mod.f90
Added: DART/branches/development/models/dynamo/work/path_names_preprocess
===================================================================
--- DART/branches/development/models/dynamo/work/path_names_preprocess (rev 0)
+++ DART/branches/development/models/dynamo/work/path_names_preprocess 2013-05-29 16:17:40 UTC (rev 6185)
@@ -0,0 +1,5 @@
+common/types_mod.f90
+mpi_utilities/null_mpi_utilities_mod.f90
+preprocess/preprocess.f90
+time_manager/time_manager_mod.f90
+utilities/utilities_mod.f90
Modified: DART/branches/development/models/dynamo/work/path_names_x_plus_delta
===================================================================
--- DART/branches/development/models/dynamo/work/path_names_x_plus_delta 2013-05-29 16:12:35 UTC (rev 6184)
+++ DART/branches/development/models/dynamo/work/path_names_x_plus_delta 2013-05-29 16:17:40 UTC (rev 6185)
@@ -1 +1 @@
-models/iface/x_plus_delta.f90
+models/dynamo/x_plus_delta.f90
Added: DART/branches/development/models/dynamo/work/quickbuild.csh
===================================================================
--- DART/branches/development/models/dynamo/work/quickbuild.csh (rev 0)
+++ DART/branches/development/models/dynamo/work/quickbuild.csh 2013-05-29 16:17:40 UTC (rev 6185)
@@ -0,0 +1,124 @@
+#!/bin/csh
+#
+# DART software - Copyright 2004 - 2011 UCAR. This open source software is
+# provided by UCAR, "as is", without charge, subject to all terms of use at
+# http://www.image.ucar.edu/DAReS/DART/DART_download
+#
+# $Id$
+#
+# Script to manage the compilation of all components for this model.
+
+#----------------------------------------------------------------------
+# 'preprocess' is a program that culls the appropriate sections of the
+# observation module for the observations types in 'input.nml'; the
+# resulting source file is used by all the remaining programs,
+# so this MUST be run first.
+#----------------------------------------------------------------------
+
+\rm -f preprocess *.o *.mod
+\rm -f ../../../obs_def/obs_def_mod.f90
+\rm -f ../../../obs_kind/obs_kind_mod.f90
+
+set MODEL = "dynamo"
+
+@ n = 1
+
+echo
+echo
+echo "---------------------------------------------------------------"
+echo "${MODEL} build number ${n} is preprocess"
+
+csh mkmf_preprocess
+make || exit $n
+
+./preprocess || exit 99
+
+#----------------------------------------------------------------------
+# Build all the single-threaded targets
+#----------------------------------------------------------------------
+
+foreach TARGET ( mkmf_* )
+
+ set PROG = `echo $TARGET | sed -e 's#mkmf_##'`
+
+ switch ( $TARGET )
+ case mkmf_preprocess:
+ breaksw
+ default:
+ @ n = $n + 1
+ echo
+ echo "---------------------------------------------------"
+ echo "${MODEL} build number ${n} is ${PROG}"
+ \rm -f ${PROG}
+ csh $TARGET || exit $n
+ make || exit $n
+ breaksw
+ endsw
+end
+
+\rm -f *.o *.mod input.nml*_default
+
+if ( $#argv == 1 && "$1" == "-mpi" ) then
+ echo "Success: All single task DART programs compiled."
+ echo "Script now compiling MPI parallel versions of the DART programs."
+else if ( $#argv == 1 && "$1" == "-nompi" ) then
+ echo "Success: All single task DART programs compiled."
+ echo "Script is exiting without building the MPI version of the DART programs."
+ exit 0
+else
+ echo ""
+ echo "Success: All DART programs compiled."
+ echo "Script is exiting before building the MPI version of the DART programs."
+ echo "Run the quickbuild.csh script with a -mpi argument or"
+ echo "edit the quickbuild.csh script and remove the exit line"
+ echo "to compile with MPI to run in parallel on multiple cpus."
+ echo ""
+ exit 0
+endif
+
+#----------------------------------------------------------------------
+# to enable an MPI parallel version of filter for this model,
+# call this script with the -mpi argument, or if you are going to build
+# with MPI all the time, remove or comment out the entire section above.
+#----------------------------------------------------------------------
+
+\rm -f filter wakeup_filter
+
+@ n = $n + 1
+echo
+echo "---------------------------------------------------"
+echo "build number $n is mkmf_filter"
+csh mkmf_filter -mpi
+make
+
+if ($status != 0) then
+ echo
+ echo "If this died in mpi_utilities_mod, see code comment"
+ echo "in mpi_utilities_mod.f90 starting with 'BUILD TIP' "
+ echo
+ exit $n
+endif
+
+@ n = $n + 1
+echo
+echo "---------------------------------------------------"
+echo "build number $n is mkmf_wakeup_filter"
+csh mkmf_wakeup_filter -mpi
+make || exit $n
+
+\rm -f *.o *.mod input.nml*_default
+
+echo
+echo 'time to run filter here:'
+echo ' for lsf run "bsub < runme_filter"'
+echo ' for pbs run "qsub runme_filter"'
+echo ' for lam-mpi run "lamboot" once, then "runme_filter"'
+echo ' for mpich run "mpd" once, then "runme_filter"'
+
+exit 0
+
+# <next few lines under version control, do not edit>
+# $URL$
+# $Revision$
+# $Date$
+
Property changes on: DART/branches/development/models/dynamo/work/quickbuild.csh
___________________________________________________________________
Added: svn:executable
+ *
Added: svn:mime-type
+ text/plain
Added: svn:keywords
+ Date Rev Author HeadURL Id
Added: svn:eol-style
+ native
More information about the Dart-dev
mailing list