0e12fe12ea2f001ea3e4bf4d6cb5d6c6cab2a8cb,open_seq2seq/models/text2speech.py,Text2Speech,finalize_inference,#Text2Speech#Any#Any#,365
Before Change
// print(predicted_final_spectrogram_sample.shape)
if audio_length > 2:
predicted_final_spectrogram_sample = predicted_final_spectrogram_sample[:audio_length-1,:]
if "magnitude" in self.get_data_layer().params["output_type"]:
predicted_final_spectrogram_sample = self.get_data_layer().denormalize(predicted_final_spectrogram_sample)
predicted_final_spectrogram_sample = np.exp(predicted_final_spectrogram_sample)
save_audio(predicted_final_spectrogram_sample, self.params["logdir"], 0, mode="infer",number= i*batch_size+j)
elif "mel" in self.get_data_layer().params["output_type"]:
save_audio(predicted_final_spectrogram_sample, self.params["logdir"], 0, mode="infer",number= i*batch_size+j)
// if "spectrogram" in self.get_data_layer().params["output_type"]:
// save_audio(predicted_final_spectrogram_sample, self.params["logdir"], 0, mode="infer", number=i*batch_size+j)
return {}
After Change
def finalize_inference(self, results_per_batch, output_file):
print("output_file is ignored for ts2")
print("results are logged to the logdir")
batch_size = len(results_per_batch[0][0]["source_tensors"][0])
for i, sample in enumerate(results_per_batch):
input_values = sample[0]
output_values = sample[1]
In pattern: SUPERPATTERN
Frequency: 3
Non-data size: 4
Instances Project Name: NVIDIA/OpenSeq2Seq
Commit Name: 0e12fe12ea2f001ea3e4bf4d6cb5d6c6cab2a8cb
Time: 2018-06-28
Author: jasoli@nvidia.com
File Name: open_seq2seq/models/text2speech.py
Class Name: Text2Speech
Method Name: finalize_inference
Project Name: tensorflow/models
Commit Name: b152ed9c3252c386f43ff2c01ceb29f11bbcd105
Time: 2020-08-14
Author: kaushikshiv@google.com
File Name: research/object_detection/dataset_tools/create_ava_actions_tf_record.py
Class Name: Ava
Method Name: get_label_map
Project Name: HendrikStrobelt/Seq2Seq-Vis
Commit Name: 378301ea6e3541fdd5ae61a7fb52ccbeeecce405
Time: 2018-04-25
Author: hendrik@strobelt.com
File Name: s2s/project.py
Class Name: S2SProject
Method Name: get_index