t1.py 文件源码

python
阅读 23 收藏 0 点赞 0 评论 0

项目:Opencv_learning 作者: wjb711 项目源码 文件源码
def record_wave():
  #open the input of wave
  pa = PyAudio()
  stream = pa.open(format = paInt16, channels = 1,
          rate = framerate, input = True,
          frames_per_buffer = NUM_SAMPLES)
  save_buffer = []
  count = 0
  while count < TIME*4:
    #read NUM_SAMPLES sampling data
    string_audio_data = stream.read(NUM_SAMPLES)
    save_buffer.append(string_audio_data)
    count += 1
    print '.'
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号