code: def test_audioclip_stereo_max_volume(nchannels, channel_muted):
      def make_frame(t):
          frame = []
          # build channels (one of each pair muted)
          for i in range(int(nchannels / 2)):
              if channel_muted == "left":
                  # if muted channel is left, [0, sound, 0, sound...]
                  frame.append(np.sin(t * 0))
                  frame.append(np.sin(440 * 2 * np.pi * t))
              else:
                  # if muted channel is right, [sound, 0, sound, 0...]
                  frame.append(np.sin(440 * 2 * np.pi * t))
                  frame.append(np.sin(t * 0))
          return np.array(frame).T
  
      clip = AudioClip(make_frame, fps=44100, duration=1)
      max_volume = clip.max_volume(stereo=True)
      # if `stereo == True`, `AudioClip.max_volume` returns a Numpy array`
      assert isinstance(max_volume, np.ndarray)
      assert len(max_volume) == nchannels
  
      # check channels muted and with sound
      for i, channel_max_volume in enumerate(max_volume):
          if i % 2 == 0:
              if channel_muted == "left":
                  assert channel_max_volume == 0
              else:
                  assert channel_max_volume > 0
          else:
              if channel_muted == "right":
                  assert channel_max_volume == 0
              else:
                  assert channel_max_volume > 0
  
file_path: moviepy/tests/test_AudioClips.py
imports: import os
  import numpy
  import pytest
  from moviepy.audio.AudioClip import AudioArrayClip, AudioClip, CompositeAudioClip, concatenate_audioclips
  from moviepy.audio.io.AudioFileClip import AudioFileClip
label_desc: Use image node_id 9 for calling a global function with example usage: test_audioclip_stereo_max_volume(nchannels, channel_muted) and returns: np