New URL for NEMO forge!   http://forge.nemo-ocean.eu

Since March 2022 along with NEMO 4.2 release, the code development moved to a self-hosted GitLab.
This present forge is now archived and remained online for history.
BIO_aix.ksh in trunk/VALID/2INSTALL/JOBS – NEMO

source: trunk/VALID/2INSTALL/JOBS/BIO_aix.ksh @ 795

Last change on this file since 795 was 795, checked in by ctlod, 16 years ago

Modifications in NVTK's scripts related to the GYRE_LOBSTER configuration, see ticket:#52

  • Property svn:executable set to *
File size: 1.6 KB
Line 
1#!/bin/ksh
2##############################################################
3# Original : C. Talandier for ESOPA
4# Contact  : opatlod@locean-ipsl.upmc.fr
5#
6# It is called by the assessment.ksh script for a
7# given configuration
8#
9# INPUT ARGS: 2
10#     - zfile1 : first tracer statistic file to output
11#     - zfile2 : second tracer statistic file to output
12#
13# WORK: It aims to :
14#
15#      - Extract tracers statistics from ocean.output
16#        for mon, mpi & omp runs
17#
18##############################################################
19#set -xv
20##############################################################
21
22# Initialization
23zfile1=
24zfile2=
25
26# Get arguments
27while getopts a:b:c: opt
28do
29  case "$opt" in
30    a) zfile1="$OPTARG";;
31    b) zfile2="$OPTARG";;
32    c) zfile3="$OPTARG";;
33  esac
34done
35
36zfile[0]=${zfile1}
37zfile[1]=${zfile2}
38zfilein=${zfile3}
39
40ind=0
41
42while [ ${ind} -le 1 ] ; do
43
44       zpath=$( ( dirname ${zfile[${ind}]} ) )
45
46       awk '/----TRACER STAT----/ { print $0 }' ${zpath}/${zfilein} > ${zfile[${ind}]}
47       awk '/MEAN NO   1  DET/ { print $3, $4, $7, $8, $9, $10 }' ${zpath}/${zfilein} >> ${zfile[${ind}]}
48       awk '/MEAN NO   2  ZOO/ { print $3, $4, $7, $8, $9, $10 }' ${zpath}/${zfilein} >> ${zfile[${ind}]}
49       awk '/MEAN NO   3  PHY/ { print $3, $4, $7, $8, $9, $10 }' ${zpath}/${zfilein} >> ${zfile[${ind}]}
50       awk '/MEAN NO   4  NO3/ { print $3, $4, $7, $8, $9, $10 }' ${zpath}/${zfilein} >> ${zfile[${ind}]}
51       awk '/MEAN NO   5  NH4/ { print $3, $4, $7, $8, $9, $10 }' ${zpath}/${zfilein} >> ${zfile[${ind}]}
52       awk '/MEAN NO   6  DOM/ { print $3, $4, $7, $8, $9, $10 }' ${zpath}/${zfilein} >> ${zfile[${ind}]}
53
54       let ind=${ind}+1
55done
Note: See TracBrowser for help on using the repository browser.