andabi / music-source-separation

Deep neural networks for separating singing voice from music written in TensorFlow
795 stars 150 forks source link

Small tricks in 'to_wav' function #10

Closed ShengleiH closed 6 years ago

ShengleiH commented 6 years ago

to_wav function call the get_stft_matrix function, in which the magnitude is multiplied by np.exp(1.j phases) - `magnitudes np.exp(1.j * phases)`. Why you do this?

andabi commented 6 years ago

@ShengleiH The whole process to waveforms is (magnitude, phase) -> stft_matrix (spectrogram) -> waveforms. In the first conversion, we need that formula theoretically.