From b89fb04b97ee698f13a61160b87d832cb5b8be99 Mon Sep 17 00:00:00 2001 From: Bernardo Date: Fri, 2 Aug 2019 10:24:58 -0300 Subject: [PATCH] space after comma --- util/spectrogram_augmentations.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/util/spectrogram_augmentations.py b/util/spectrogram_augmentations.py index fb47f713..98159826 100644 --- a/util/spectrogram_augmentations.py +++ b/util/spectrogram_augmentations.py @@ -72,7 +72,7 @@ def augment_pitch_and_tempo(spectrogram, new_height = tf.cast(tf.cast(original_shape[1], tf.float32)*choosen_pitch, tf.int32) new_width = tf.cast(tf.cast(original_shape[2], tf.float32)/(choosen_tempo), tf.int32) spectrogram_aug = tf.image.resize_bilinear(tf.expand_dims(spectrogram, -1), [new_height, new_width]) - spectrogram_aug = tf.image.crop_to_bounding_box(spectrogram_aug, offset_height=0, offset_width=0, target_height=tf.minimum(original_shape[1],new_height), target_width=tf.shape(spectrogram_aug)[2]) + spectrogram_aug = tf.image.crop_to_bounding_box(spectrogram_aug, offset_height=0, offset_width=0, target_height=tf.minimum(original_shape[1], new_height), target_width=tf.shape(spectrogram_aug)[2]) spectrogram_aug = tf.cond(choosen_pitch < 1, lambda: tf.image.pad_to_bounding_box(spectrogram_aug, offset_height=0, offset_width=0, target_height=original_shape[1], target_width=tf.shape(spectrogram_aug)[2]),