#!/bin/bashFILENAME=$1# MODE be one of ['lite_train_infer' 'whole_infer' 'whole_train_infer', 'infer', 'cpp_infer', 'serving_infer']MODE=$2if[${MODE}="cpp_infer"];thendataline=$(awk'NR==52, NR==66{print}'$FILENAME)elif[${MODE}="serving_infer"];thendataline=$(awk'NR==67, NR==81{print}'$FILENAME)elsedataline=$(awk'NR==1, NR==51{print}'$FILENAME)ficount=0for line in${dataline[*]};dolet count++echo$count$linedone