run_all_sdr_metrics.sh (1012B)
1 #!/usr/bin/env bash 2 # Copyright (c) the JPEG XL Project Authors. All rights reserved. 3 # 4 # Use of this source code is governed by a BSD-style 5 # license that can be found in the LICENSE file. 6 7 set -eu 8 dir="$(dirname "$0")" 9 10 main() { 11 local metrics=( 12 FSIM-Y:"${dir}"/fsim-y.sh 13 FSIM-RGB:"${dir}"/fsim-rgb.sh 14 LPIPS:"${dir}"/lpips-rgb.sh 15 MS-SSIM-Y:"${dir}"/msssim-y.sh 16 NLPD:"${dir}"/nlpd-y.sh 17 SSIMULACRA:"${dir}"/ssimulacra.sh 18 VIF:"${dir}"/vif-rgb.sh 19 VMAF:"${dir}"/vmaf.sh 20 ) 21 # other metrics, not in core experiments: 22 # VSI:"${dir}"/vsi-rgb.sh 23 # SSIM-RGB:"${dir}"/ssim-rgb.sh 24 # SSIM-Y:"${dir}"/ssim-y.sh 25 # GMSD:"${dir}"/gmsd.sh 26 # DISTS:"${dir}"/dists-rgb.sh 27 # MS-SSIM-RGB:"${dir}"/msssim-rgb.sh 28 29 local metrics_args=$(printf '%s' "${metrics[@]/#/,}") 30 metrics_args=${metrics_args:1} 31 32 33 "${dir}/../../../build/tools/benchmark_xl" \ 34 --print_details_csv \ 35 --num_threads=1 \ 36 --error_pnorm=6 \ 37 --extra_metrics ${metrics_args} \ 38 "$@" 39 } 40 41 main "$@"