convert bytes to samples