Blame view

tools/scripts/CheckConfPass.sh 889 Bytes
e6be5137b   Jean-François Rey   reinitialized pro...
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
  #!/bin/bash
   
  #################################################
  # File :    CheckConfPass.sh                    #
  # Brief :   Check Conf Pass                     #
  # Author :  Jean-François Rey                   #
  # Version : 1.0                                 #
  # Date :    17/06/13                            #
  #################################################
   
  # configuration file
  . "$OTMEDIA_HOME/cfg/ConfPass.cfg"
  
  # check_conf_pass_usf(usffilenamefullpath)
  # -usffilenamefullpath : full path to usf file
  # return 0 if ok, otherwise return 1
  function check_conf_pass_usf()
  {
      if [ $# -ne 1 ]
      then 
          if [ -e "$1" ] && [ -s "$1" ]
          then
              temp=`grep -c -E 'confidence="0.600"' "$1"`
              if [ $temp -gt 200 ]
              then
                  return 1
              fi
          else
              return 1
          fi
      fi
      
      return 0
  }