Commit d3026175 authored by Jan Kiene's avatar Jan Kiene
Browse files

Merge branch 'ci/compelxity-log-naming' into 'main'

[CI] Make GetWmops.sh work for basop repo + add proper naming to complexity logfiles

See merge request !1845
parents 300a2d13 6e74c84d
Loading
Loading
Loading
Loading
Loading
+33 −25
Original line number Diff line number Diff line
@@ -29,11 +29,11 @@
# the United Nations Convention on Contracts on the International Sales of Goods.

function usage {
    echo "Usage: $0 \"ivas-format(s)\" \"output-format(s)\" \"mode{full(default)|mem_only}\""
  echo "Usage: $0 \"ivas-format(s)\" \"output-format(s)\" \"mode{full(default)|mem_only}\" \"repo{float(default)|basop}\" "
  exit 1
}

if [ $# -ne 2 ] && [ $# -ne 3 ]; then
if [ $# -ne 2 ] && [ $# -ne 3 ] && [ $# -ne 4 ]; then
  usage
fi

@@ -41,7 +41,7 @@ ivas_format=$1
output_format="$2"

mode_arg_script=""
if [ $# -eq 3 ]; then
if [ $# -ge 3 ]; then
  if [ "$3" = "mem_only" ]; then
    mode_arg_script="--wmc_tool_mem_only"
  elif [ "$3" != "full" ]; then
@@ -49,11 +49,20 @@ if [ $# -eq 3 ]; then
  fi
fi

date=`date +%Y%m%d`                         # used for log-file file ending
shortDate=`date "+%b %d" | sed -e "s/\ /_/g"`    # stored in the log-file
fullDate=`date "+%c" | sed -e "s/\ /_/g"`       # stored in the log-file
repo_arg_script=""
if [ $# -eq 4 ]; then
  if [ "$4" = "basop" ]; then
    repo_arg_script="--basop"
  elif [ "$4" != "float"]; then
    usage
  fi
fi

commit_sha=`git rev-parse --short HEAD`
date=$(date +%Y%m%d)                           # used for log-file file ending
shortDate=$(date "+%b %d" | sed -e "s/\ /_/g") # stored in the log-file
fullDate=$(date "+%c" | sed -e "s/\ /_/g")     # stored in the log-file

commit_sha=$(git rev-parse --short HEAD)

destDir="."
scriptDir="ci/complexity_measurements"
@@ -62,7 +71,7 @@ ep="${scriptDir}/ep_10pct_fer.g192"
config_file="scripts/config/ci_linux_ltv.json"

# get wmops newsletter
wmopsFilenameFlcLast=wmops_newsletter_stereo__${commit_sha}_${date}
wmopsFilenameFlcLast=wmops_newsletter_${ivas_format}_to_${output_format}__${commit_sha}_${date}
wmopsFilenameFlc=${destDir}/wmops/logs/${wmopsFilenameFlcLast}

ret_val=0
@@ -75,7 +84,7 @@ if [ "$ivas_format" == "OSBA" ]; then
fi

# instrument and build
./scripts/IvasBuildAndRunChecks.py $mode_arg_script -p $config_file --checks COMPLEXITY --create_complexity_tables ${wmopsFilenameFlc} -C $ivas_format $mode_arg -f ${ep} --oc $output_format
./scripts/IvasBuildAndRunChecks.py $mode_arg_script $repo_arg_script -p $config_file --checks COMPLEXITY --create_complexity_tables ${wmopsFilenameFlc} -C $ivas_format $mode_arg -f ${ep} --oc $output_format
ret_val=$?

# get the info on worst-case operating point: WMOPS number, enc-operating mode, dec-operating mode
@@ -88,7 +97,6 @@ tcsh ${scriptDir}/genWebpageData_WMOPS.csh ${destDir}/wmops/log_wmops_all.txt ${
# per mode graph
tcsh ${scriptDir}/genWebpageData_WmopPerOperatingpoint.csh ${wmopsFilenameFlc}_WMOPS.csv ${destDir}/wmops/graphs_wmops_flc_perOP.js Graphs_WMOPS_perOP


# get memory info for webpage
### RAM
${scriptDir}/mergeNewsletterRam.py ${wmopsFilenameFlc}_HEAP.csv ${wmopsFilenameFlc}_STACK.csv >${wmopsFilenameFlc}_RAM.csv