Borrar filtros
Borrar filtros

how to calculate bit depth of signal from its sample?

3 visualizaciones (últimos 30 días)
saf asalah
saf asalah el 6 de En. de 2017
Comentada: Guillaume el 6 de En. de 2017
I have used some compression method to my audio signal. in order for me to calculate the compression ratio, I need to get the bit size of the original and compressed signal? i got the bit depth of original signal by applying the command info.BitsPerSample. but I can't know the bit depth of the compressed signal

Respuestas (1)

Guillaume
Guillaume el 6 de En. de 2017
Hum, usually the compression ratio is the size of the data before compression divided by the size of the data after compression, and has nothing to do with bits per sample of the data. While on most computers, you could reduce the size of the data if you went from for example 16 bits per sample to 8 bits per sample, this is not called compression but just downsampling.
  2 comentarios
saf asalah
saf asalah el 6 de En. de 2017
thanks guillaume for your reply i'm beginner in this field but what did you mean with size of data is it size(signal) command which means the number of sample? I asked one lecturer about compression ratio and he answered is the bit size before compression divided by the bit size after compression. and he said 'bit size= bits per sample * number of samples'
Guillaume
Guillaume el 6 de En. de 2017
Yes, so by that definition:
compression ratio = size before compression in bits / size after compression in bits
The bits per sample of the compressed signal is entirely dependent on the compression algorithm. It's possible it's exactly the same as the original signal.

Iniciar sesión para comentar.

Community Treasure Hunt

Find the treasures in MATLAB Central and discover how the community can help you!

Start Hunting!

Translated by