If audio data of one of two files, A.flac and B.flac, loaded as two tracks, be subtracted from the other, for every sampling time period?

Suppose I have an audio file A.flac.
I use the following modified version of the popmute.py to filter out only the noises, clicks and such, and save the output to create another audio file B.flac.

;control help “View Help” choice “No,Yes” 0
“Values as middle min max”
;control thresh “Threshold” real “dB” -75 -100 0
;control floor “Mute Level” real “dB” -120 -120 0
;control look “Look ahead” real “milliseconds” 0 0 20
;control rel “Release time” real “milliseconds” 0 0 20

I make the “Look ahead” and the “Release time” instantaneous. I choose the thres at -50 and the floor at -120. I get a nice noise sample for the entire audio, the said A.flac, and I save it as B.flac.

Now can audacity help me directly subtract two audio files A.flac and B.flac when the either is loaded as two tracks?

Simple addition of two tracks is trivial. But simple subtraction?

Just invert one track and add both tracks after that. Inverting being the same as multiplying with -1.

See also Inverting audio using Nyquit? - #2 by steve

Yes, absolutely works. I tried first with a track of an audio file and its inverted track. Absolute silence. So, Good!
Then I tried with popmute.py. Noise is perfectly eliminated.
My next objective would be to find an appropriate threshold level that neutralises all strays effectively.
So thank you Mr Winterberg. While I treat your input as a solution, I must say that I have been enticed for even more input.

This topic was automatically closed after 30 days. New replies are no longer allowed.