Update: 更新板卡examples
This commit is contained in:
9
boards/default/python_mixpy/examples/人工智能Py/02语音合成-1.py
Normal file
9
boards/default/python_mixpy/examples/人工智能Py/02语音合成-1.py
Normal file
@@ -0,0 +1,9 @@
|
||||
import aip
|
||||
|
||||
import os
|
||||
|
||||
|
||||
f = open("audio.mp3", 'wb')
|
||||
client = aip.AipSpeech("Enter Your APP_ID", "Enter Your API_KEY", "Enter Your SECRET_KEY")
|
||||
f.write(client.synthesis("步行导航开始,直行后前方50米右转", options={}))
|
||||
os.startfile("audio.mp3")
|
||||
Reference in New Issue
Block a user