From 957d5bec0d9d9a3ed6a4c337d3dbd05b76cd99e2 Mon Sep 17 00:00:00 2001 From: Markus Multrus Date: Sat, 10 Jun 2023 21:54:13 +0200 Subject: [PATCH 1/2] little helper script to get wavefile props in csv format --- other/eval_wavfiles.sh | 65 ++++++++++++++++++++++++++++++++++++++ other/get_wavfile_props.sh | 65 ++++++++++++++++++++++++++++++++++++++ 2 files changed, 130 insertions(+) create mode 100755 other/eval_wavfiles.sh create mode 100755 other/get_wavfile_props.sh diff --git a/other/eval_wavfiles.sh b/other/eval_wavfiles.sh new file mode 100755 index 00000000..85b75aa9 --- /dev/null +++ b/other/eval_wavfiles.sh @@ -0,0 +1,65 @@ +#!/bin/bash + + +# (C) 2022-2023 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, +# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +# contributors to this repository. All Rights Reserved. + +# This software is protected by copyright law and by international treaties. +# The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, +# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +# contributors to this repository retain full ownership rights in their respective contributions in +# the software. This notice grants no license of any kind, including but not limited to patent +# license, nor is any license granted by implication, estoppel or otherwise. + +# Contributors are required to enter into the IVAS codec Public Collaboration agreement before making +# contributions. + +# This software is provided "AS IS", without any express or implied warranties. The software is in the +# development stage. It is intended exclusively for experts who have experience with such software and +# solely for the purpose of inspection. All implied warranties of non-infringement, merchantability +# and fitness for a particular purpose are hereby disclaimed and excluded. + +# Any dispute, controversy or claim arising under or in relation to providing this software shall be +# submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in +# accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and +# the United Nations Convention on Contracts on the International Sales of Goods. + + +if [ $# -lt 1 ] +then + echo "Usage: $0 file.wav" + echo "Prints file.wav;MD5;sampleFreq;numberSamples;aligned20ms;numberChannels;dataType;dataByteOrder" + echo "Requires: InfoAudio, md5sum" + exit 1 +fi + +InfoAudio=InfoAudio +file=$1 + +filename=`basename $file` +md5sum=`md5sum -b $1 | cut -d" " -f1` + +res=`$InfoAudio $file` + +sampleFreq=`echo "$res" | grep -m1 "Sampling frequency" | sed -e 's/\([a-zA-Z\. ]*: \)\([0-9]*\)\(.*\)/\2/g'` + +numberSamples=`echo "$res" | grep -m1 "No. frames" | sed -e 's/\([a-zA-Z\. ]*: \)\([0-9]*\)\(.*\)/\2/g'` + +aligned20ms=false +if [ $(expr $numberSamples % 960) == "0" ]; then + aligned20ms=true +fi + +numberChannels=`echo "$res" | grep -m1 "No. channels" | sed -e 's/\([a-zA-Z\. ]*: \)\([0-9]*\)\(.*\)/\2/g'` + +dataType=`echo "$res" | grep -m1 "Data type" | sed -e 's/\([a-zA-Z\. ]*: \)\([[a-zA-Z0-9]*\)\(.*\)/\2/g'` + +dataByteOrder=`echo "$res" | grep -m1 "Data byte order" | sed -e 's/\([a-zA-Z\. ]*: \)\([[a-zA-Z0-9-]*\)\(.*\)/\2/g'` + +echo "${filename};${md5sum};${sampleFreq};${numberSamples};${aligned20ms};${numberChannels};${dataType};${dataByteOrder}" + diff --git a/other/get_wavfile_props.sh b/other/get_wavfile_props.sh new file mode 100755 index 00000000..85b75aa9 --- /dev/null +++ b/other/get_wavfile_props.sh @@ -0,0 +1,65 @@ +#!/bin/bash + + +# (C) 2022-2023 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, +# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +# contributors to this repository. All Rights Reserved. + +# This software is protected by copyright law and by international treaties. +# The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, +# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., +# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, +# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other +# contributors to this repository retain full ownership rights in their respective contributions in +# the software. This notice grants no license of any kind, including but not limited to patent +# license, nor is any license granted by implication, estoppel or otherwise. + +# Contributors are required to enter into the IVAS codec Public Collaboration agreement before making +# contributions. + +# This software is provided "AS IS", without any express or implied warranties. The software is in the +# development stage. It is intended exclusively for experts who have experience with such software and +# solely for the purpose of inspection. All implied warranties of non-infringement, merchantability +# and fitness for a particular purpose are hereby disclaimed and excluded. + +# Any dispute, controversy or claim arising under or in relation to providing this software shall be +# submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in +# accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and +# the United Nations Convention on Contracts on the International Sales of Goods. + + +if [ $# -lt 1 ] +then + echo "Usage: $0 file.wav" + echo "Prints file.wav;MD5;sampleFreq;numberSamples;aligned20ms;numberChannels;dataType;dataByteOrder" + echo "Requires: InfoAudio, md5sum" + exit 1 +fi + +InfoAudio=InfoAudio +file=$1 + +filename=`basename $file` +md5sum=`md5sum -b $1 | cut -d" " -f1` + +res=`$InfoAudio $file` + +sampleFreq=`echo "$res" | grep -m1 "Sampling frequency" | sed -e 's/\([a-zA-Z\. ]*: \)\([0-9]*\)\(.*\)/\2/g'` + +numberSamples=`echo "$res" | grep -m1 "No. frames" | sed -e 's/\([a-zA-Z\. ]*: \)\([0-9]*\)\(.*\)/\2/g'` + +aligned20ms=false +if [ $(expr $numberSamples % 960) == "0" ]; then + aligned20ms=true +fi + +numberChannels=`echo "$res" | grep -m1 "No. channels" | sed -e 's/\([a-zA-Z\. ]*: \)\([0-9]*\)\(.*\)/\2/g'` + +dataType=`echo "$res" | grep -m1 "Data type" | sed -e 's/\([a-zA-Z\. ]*: \)\([[a-zA-Z0-9]*\)\(.*\)/\2/g'` + +dataByteOrder=`echo "$res" | grep -m1 "Data byte order" | sed -e 's/\([a-zA-Z\. ]*: \)\([[a-zA-Z0-9-]*\)\(.*\)/\2/g'` + +echo "${filename};${md5sum};${sampleFreq};${numberSamples};${aligned20ms};${numberChannels};${dataType};${dataByteOrder}" + -- GitLab From 332d32ce50445604e5e92ab95c2d3e7a18f0d608 Mon Sep 17 00:00:00 2001 From: Markus Multrus Date: Sat, 10 Jun 2023 21:55:29 +0200 Subject: [PATCH 2/2] delete file commited by accident --- other/eval_wavfiles.sh | 65 ------------------------------------------ 1 file changed, 65 deletions(-) delete mode 100755 other/eval_wavfiles.sh diff --git a/other/eval_wavfiles.sh b/other/eval_wavfiles.sh deleted file mode 100755 index 85b75aa9..00000000 --- a/other/eval_wavfiles.sh +++ /dev/null @@ -1,65 +0,0 @@ -#!/bin/bash - - -# (C) 2022-2023 IVAS codec Public Collaboration with portions copyright Dolby International AB, Ericsson AB, -# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., -# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, -# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other -# contributors to this repository. All Rights Reserved. - -# This software is protected by copyright law and by international treaties. -# The IVAS codec Public Collaboration consisting of Dolby International AB, Ericsson AB, -# Fraunhofer-Gesellschaft zur Foerderung der angewandten Forschung e.V., Huawei Technologies Co. LTD., -# Koninklijke Philips N.V., Nippon Telegraph and Telephone Corporation, Nokia Technologies Oy, Orange, -# Panasonic Holdings Corporation, Qualcomm Technologies, Inc., VoiceAge Corporation, and other -# contributors to this repository retain full ownership rights in their respective contributions in -# the software. This notice grants no license of any kind, including but not limited to patent -# license, nor is any license granted by implication, estoppel or otherwise. - -# Contributors are required to enter into the IVAS codec Public Collaboration agreement before making -# contributions. - -# This software is provided "AS IS", without any express or implied warranties. The software is in the -# development stage. It is intended exclusively for experts who have experience with such software and -# solely for the purpose of inspection. All implied warranties of non-infringement, merchantability -# and fitness for a particular purpose are hereby disclaimed and excluded. - -# Any dispute, controversy or claim arising under or in relation to providing this software shall be -# submitted to and settled by the final, binding jurisdiction of the courts of Munich, Germany in -# accordance with the laws of the Federal Republic of Germany excluding its conflict of law rules and -# the United Nations Convention on Contracts on the International Sales of Goods. - - -if [ $# -lt 1 ] -then - echo "Usage: $0 file.wav" - echo "Prints file.wav;MD5;sampleFreq;numberSamples;aligned20ms;numberChannels;dataType;dataByteOrder" - echo "Requires: InfoAudio, md5sum" - exit 1 -fi - -InfoAudio=InfoAudio -file=$1 - -filename=`basename $file` -md5sum=`md5sum -b $1 | cut -d" " -f1` - -res=`$InfoAudio $file` - -sampleFreq=`echo "$res" | grep -m1 "Sampling frequency" | sed -e 's/\([a-zA-Z\. ]*: \)\([0-9]*\)\(.*\)/\2/g'` - -numberSamples=`echo "$res" | grep -m1 "No. frames" | sed -e 's/\([a-zA-Z\. ]*: \)\([0-9]*\)\(.*\)/\2/g'` - -aligned20ms=false -if [ $(expr $numberSamples % 960) == "0" ]; then - aligned20ms=true -fi - -numberChannels=`echo "$res" | grep -m1 "No. channels" | sed -e 's/\([a-zA-Z\. ]*: \)\([0-9]*\)\(.*\)/\2/g'` - -dataType=`echo "$res" | grep -m1 "Data type" | sed -e 's/\([a-zA-Z\. ]*: \)\([[a-zA-Z0-9]*\)\(.*\)/\2/g'` - -dataByteOrder=`echo "$res" | grep -m1 "Data byte order" | sed -e 's/\([a-zA-Z\. ]*: \)\([[a-zA-Z0-9-]*\)\(.*\)/\2/g'` - -echo "${filename};${md5sum};${sampleFreq};${numberSamples};${aligned20ms};${numberChannels};${dataType};${dataByteOrder}" - -- GitLab