def add_audio(self, tag, snd_tensor, global_step=None, sample_rate=44100, walltime=None): torch._C._log_api_usage_once("tensorboard.logging.add_audio") if self._check_caffe2_blob(snd_tensor): snd_tensor = workspace.FetchBlob(snd_tensor) self._get_file_writer().add_summary( audio(tag, snd_tensor, sample_rate=sample_rate), global_step, walltime)
def test_audio(self): self.assertTrue( compare_proto(summary.audio('dummy', tensor_N(shape=(42, ))), self))
def test_audio(self): self.assertTrue( compare_proto(summary.audio('dummy', np.random.rand(42)), self))