diff --git a/.gitignore b/.gitignore index f6e84233a391d14ec54c2bc19bcb0d61f53cb791..1559e986d01fb016e518648d86e6a06b1dc4a123 100644 --- a/.gitignore +++ b/.gitignore @@ -37,8 +37,9 @@ xcuserdata/ *.nc Weights/ __pycache__/ +run.def # # Test configurations and directories # DomainDecompTests/Output/ -DomainDecompTests/run.def \ No newline at end of file +DomainDecompTests/run.def diff --git a/RoutingPreProc.py b/RoutingPreProc.py index 5b794890fe16223c27e44c323b0f1b27237e7fed..7128b0413567b04751a06a2ff3d6904ebd193eaf 100644 --- a/RoutingPreProc.py +++ b/RoutingPreProc.py @@ -37,12 +37,6 @@ log_master, log_world = getargs.getLogger() INFO, DEBUG, ERROR = log_master.info, log_master.debug, log_world.error INFO_ALL, DEBUG_ALL = log_world.info, log_world.debug # -# Verify directories -# -wdir="Weights" -if not os.path.exists(wdir) : - os.mkdir(wdir) -# # Read full grid and partition the domain. # gg = MG.GlobalGrid() @@ -52,6 +46,14 @@ szhalo=1 nbc=comm.Get_size() rank=comm.Get_rank() # +# Verify directories +# +wdir="Weights" +if rank == 0 : + if not os.path.exists(wdir) : + os.mkdir(wdir) +comm.Barrier() +# # Region of grid to be treated # part = PA.partition(gg.ni, gg.nj, gg.land, comm, nbc, szhalo, rank) diff --git a/SampleScripts/BuildHTUs_Mallorca.sh b/SampleScripts/BuildHTUs_Mallorca.sh new file mode 100755 index 0000000000000000000000000000000000000000..a4a4d190762f7c47a544a6080ca738624e66ea9d --- /dev/null +++ b/SampleScripts/BuildHTUs_Mallorca.sh @@ -0,0 +1,9 @@ +#/bin/bash +# +# A small test case which can run on a laptop. +# The MEDCORDEX grid is used over the Mallorca island. +# +cd ./.. +cp TestConfigs/run.def.WRF_local ./run.def +# +mpirun -n 4 python RoutingPreProc.py diff --git a/TestConfigs/run.def.WRF_local b/TestConfigs/run.def.WRF_local index eec206e3720a91ffae7f57a393a214cac23c5869..f65aa6e33d690a87e369645e3de1558159c1ade3 100644 --- a/TestConfigs/run.def.WRF_local +++ b/TestConfigs/run.def.WRF_local @@ -24,5 +24,5 @@ GraphFile = test_graph.nc # Diagnostics # You need to provide an interval in longitude and Latitude. # -DiagLon = 2.9, 3.9 -DiagLat = 38.8, 40.0 +DiagLon = 3.9, 3.9 +DiagLat = 40.0, 40.0 diff --git a/run.def b/run.def index da6ccc48b6a3f0c2fea9342797f37a39f9186373..f65aa6e33d690a87e369645e3de1558159c1ade3 100644 --- a/run.def +++ b/run.def @@ -3,10 +3,11 @@ # EarthRadius = 6370000. # -ModelGridFile = /bdd/MEDI/workspaces/polcher/NewRouting/EM_WFDEI_CRU_2000.nc -##WEST_EAST = -9.75, 5.25 -##SOUTH_NORTH = 36.1, 44.2 -HydroFile = /bdd/MEDI/workspaces/polcher/NewRouting/routing_MED.nc +ModelGridFile = /home/polcher/WORK/Data/NewRouting/geo_em.d01.nc +# Mallorca +WEST_EAST = 2.3, 3.5 +SOUTH_NORTH = 39.00, 40.1 +HydroFile = /home/polcher/WORK/Data/NewRouting/routing_MED.nc # # FORTRAN interface parameters # @@ -18,10 +19,10 @@ nbasmax = 35 # # Output # -GraphFile = EM_WFDEI_test_graph.nc +GraphFile = test_graph.nc # # Diagnostics # You need to provide an interval in longitude and Latitude. # -DiagLon = 39.9, 39.9 +DiagLon = 3.9, 3.9 DiagLat = 40.0, 40.0