SynapseML icon indicating copy to clipboard operation
SynapseML copied to clipboard

Text-to-Speech example did not work in the Cognitive Service Overview notebook

Open cynthiajiangatl opened this issue 3 years ago • 0 comments

"{"errorCode":"AuthenticationFailure","errorDetails..." errorCode: ""AuthenticationFailure"" errorDetails: ""HTTPAPI result code = HTTPAPI_OK. HTTP status code = 401. Reason: Unauthorized."" errorReason: ""Error""

"dbfs:/output.mp3" is used as the output file which caused the issue.

I suggest the following bug fix:

Mount a data lake storage with a linked service.

mssparkutils.fs.mount( "abfss://[email protected]", "/lakestore", {"linkedService":"demodatalakels"} )

Get the jobid

jobid = mssparkutils.env.getJobId()

Create a dataframe with text and output the audio file to the mounted data lake storage

df = spark.createDataFrame( [ ( "Reading out lod is fun! Check out aka.ms/spark for more information", "synfs:/" + jobid + "/lakestore/" + "output.mp3", ) ], ["text", "output_file"], )

Thank you, Cynthia

AB#1841977

cynthiajiangatl avatar Jun 22 '22 21:06 cynthiajiangatl