class_docstr: A class to write an AudioClip into an audio file.
  
  Parameters
  ----------
  
  filename
    Name of any video or audio file, like ``video.mp4`` or ``sound.wav`` etc.
  
  size
    Size (width,height) in pixels of the output video.
  
  fps_input
    Frames per second of the input audio (given by the AUdioClip being
    written down).
  
  codec
    Name of the ffmpeg codec to use for the output.
  
  bitrate:
    A string indicating the bitrate of the final video. Only
    relevant for codecs which accept a bitrate.
class_docstr_tok: ["A","class","to","write","an","AudioClip","into","an","audio","file",".","Parameters","--","--","--","--","--","filename","Name","of","any","video","or","audio","file",",","like","``","video.mp4","``","or","``","sound.wav","``","etc",".","size","Size","(","width",",","height",")","in","pixels","of","the","output","video",".","fps_input","Frames","per","second","of","the","input","audio","(","given","by","the","AUdioClip","being","written","down",")",".","codec","Name","of","the","ffmpeg","codec","to","use","for","the","output",".","bitrate",":","A","string","indicating","the","bitrate","of","the","final","video",".","Only","relevant","for","codecs","which","accept","a","bitrate","."]
code: def __init__(
      self,
      filename,
      fps_input,
      nbytes=2,
      nchannels=2,
      codec="libfdk_aac",
      bitrate=None,
      input_video=None,
      logfile=None,
      ffmpeg_params=None,
  ):
      if logfile is None:
          logfile = sp.PIPE
      self.logfile = logfile
      self.filename = filename
      self.codec = codec
      self.ext = self.filename.split(".")[-1]
  
      # order is important
      cmd = [
          FFMPEG_BINARY,
          "-y",
          "-loglevel",
          "error" if logfile == sp.PIPE else "info",
          "-f",
          "s%dle" % (8 * nbytes),
          "-acodec",
          "pcm_s%dle" % (8 * nbytes),
          "-ar",
          "%d" % fps_input,
          "-ac",
          "%d" % nchannels,
          "-i",
          "-",
      ]
      if input_video is None:
          cmd.extend(["-vn"])
      else:
          cmd.extend(["-i", input_video, "-vcodec", "copy"])
  
      cmd.extend(["-acodec", codec] + ["-ar", "%d" % fps_input])
      cmd.extend(["-strict", "-2"])  # needed to support codec 'aac'
      if bitrate is not None:
          cmd.extend(["-ab", bitrate])
      if ffmpeg_params is not None:
          cmd.extend(ffmpeg_params)
      cmd.extend([filename])
  
      popen_params = cross_platform_popen_params(
          {"stdout": sp.DEVNULL, "stderr": logfile, "stdin": sp.PIPE}
      )
  
      self.proc = sp.Popen(cmd, **popen_params)
  
file_path: moviepy/moviepy/audio/io/ffmpeg_audiowriter.py
imports: import subprocess
  import proglog
  from moviepy.config import FFMPEG_BINARY
  from moviepy.decorators import requires_duration
  from moviepy.tools import cross_platform_popen_params
label_desc: Use image node_id 1 to create a new FFMPEG_AudioWriter object  with example: obj = FFMPEG_AudioWriter(filename, fps_input, nbytes, nchannels, codec, bitrate, input_video, logfile, ffmpeg_params)