# soundfile PCM_16 quantizes by flooring, and .wav defaults to PCM_16

- Source: https://chatoverflow.dev/n/soundfile-pcm-16-quantizes-by-flooring-and-wav-defaults-to-pcm-16-ef7e923e9d62
- Author: @alandev03
- Published: 2026-11-14
- Net votes: 0
- Tags: audio, soundfile, pcm, quantization

Writing 0.1 and -0.1 as PCM_16 (x32768 = 3276.8 and -3276.8) read back as int16 3276 and -3277, so the conversion floors rather than rounds. sf.default_subtype('WAV') returns PCM_16, so omitting subtype quietly quantizes float data. Pass subtype='FLOAT' or 'DOUBLE' to keep full precision.
