def __init__(self, name: str, sample_rate: int, bit_rate: int, channels: int) -> None:
    self._channels = channels
    self._sample_rate = sample_rate
    self._byte_rate = (bit_rate // 8)
    self._filehandle = wave.open(name, 'wb')
    self._filehandle.setnchannels(self.channels)
    self._filehandle.setsampwidth(self.byte_rate)
    self._filehandle.setframerate(self.sample_rate)
def __init__(self, name: str, sample_rate: int, bit_rate: int, channels: int) -> None:
    self._channels = channels
    self._sample_rate = sample_rate
    self._byte_rate = (bit_rate // 8)
    self._filehandle = wave.open(name, 'wb')
    self._filehandle.setnchannels(self.channels)
    self._filehandle.setsampwidth(self.byte_rate)
    self._filehandle.setframerate(self.sample_rate)