Tools for sharing audio
- audiotools.post.audio_table(audio_dict: dict, first_column: Optional[str] = None, format_fn: Optional[Callable] = None, **kwargs)[source]
Embeds an audio table into HTML, or as the output cell in a notebook.
- Parameters
audio_dict (dict) – Dictionary of data to embed.
first_column (str, optional) – The label for the first column of the table, by default None
format_fn (Callable, optional) – How to format the data, by default None
- Returns
Table as a string
- Return type
str
Examples
>>> audio_dict = {} >>> for i in range(signal_batch.batch_size): >>> audio_dict[i] = { >>> "input": signal_batch[i], >>> "output": output_batch[i] >>> } >>> audiotools.post.audio_zip(audio_dict)