Reduce voice not eliminate

Help for Audacity on Windows.
Forum rules
ImageThis forum is for Audacity on Windows.
Please state which version of Windows you are using,
and the exact three-section version number of Audacity from "Help menu > About Audacity".


Audacity 1.2.x and 1.3.x are obsolete and no longer supported. If you still have those versions, please upgrade at https://www.audacityteam.org/download/.
The old forums for those versions are now closed, but you can still read the archives of the 1.2.x and 1.3.x forums.
XES118
Posts: 4
Joined: Fri Apr 21, 2017 9:19 pm
Operating System: Windows 7

Reduce voice not eliminate

Post by XES118 » Fri Apr 21, 2017 9:24 pm

I have a song to play as a Karaoke
I know that is posible to eliminate the voice with Audacity (Effect, Invert, ...)
But it is possible only tu reduce the volume of the voice a little bit, not eliminate 100%?
Thanks
Xavi

kozikowski
Forum Staff
Posts: 69357
Joined: Thu Aug 02, 2007 5:57 pm
Operating System: macOS 10.13 High Sierra

Re: Reduce voice not eliminate

Post by kozikowski » Fri Apr 21, 2017 11:07 pm

Effect, Invert, ...
Or, you could use the Audacity pre-baked tools: Effect > Vocal Remover and Effect > Vocal Reduction and Isolation.

Maybe that last one has something you could use.

http://manual.audacityteam.org/man/voca ... ation.html

Koz

XES118
Posts: 4
Joined: Fri Apr 21, 2017 9:19 pm
Operating System: Windows 7

Re: Reduce voice not eliminate

Post by XES118 » Sat Apr 22, 2017 9:14 pm

Thanks
1. In the option Effect + Vocal Remover (for center panned vocals) which REMOVER CHOICE I have to choose? And what FREQUENCY band ?
2. In EFFECT I can not find the Effect > Vocal Reduction and Isolation option. Where can I find it?
Thanks

kozikowski
Forum Staff
Posts: 69357
Joined: Thu Aug 02, 2007 5:57 pm
Operating System: macOS 10.13 High Sierra

Re: Reduce voice not eliminate

Post by kozikowski » Sun Apr 23, 2017 2:59 am

Which Audacity do you have—all three numbers?

The better Vocal Management tools are only available in the last one or two versions of Audacity. Audacity 2.1.3 is current.

http://www.audacityteam.org/download/windows/

Koz

jh90s
Posts: 115
Joined: Sun Feb 26, 2017 4:05 am
Operating System: Windows 10

Re: Reduce voice not eliminate

Post by jh90s » Mon Apr 24, 2017 7:06 am

What song is it? It'd help us know whether or not it can be done. Lots of songs these days tend to be laced with reverb and other fancy effects, along with loads of layered vocals. In a few rare cases I've had it work satisfactorily. I personally don't use the built-in vocal remover much, as I use a Python script which does the job and keeps the results in stereo, and usually can remove the vocals extensively and it works on mono tracks, as well. I'll link you a song I processed through this script (the vocals are almost entirely gone, but keep in mind this particular song has a vocal track with no reverb (or very little)).

https://youtu.be/1YpsyrO5jwQ?t=16s

steve
Site Admin
Posts: 81609
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Reduce voice not eliminate

Post by steve » Mon Apr 24, 2017 7:26 am

jh90s wrote:I personally don't use the built-in vocal remover much, as I use a Python script which does the job and keeps the results in stereo, and usually can remove the vocals extensively and it works on mono tracks, as well.
The "Vocal Reduction and Isolation" effect in Audacity keeps the result in stereo, (unless you select the "Remove Center Classic: (Mono)" option).
http://manual.audacityteam.org/man/voca ... ation.html
It does not work with mono tracks though.

What's the Python script that you are referring to? Is it open source?
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

jh90s
Posts: 115
Joined: Sun Feb 26, 2017 4:05 am
Operating System: Windows 10

Re: Reduce voice not eliminate

Post by jh90s » Mon Apr 24, 2017 8:30 am

Hi. It's called "separateLeadStereo" and can be found on Github:
https://github.com/wslihgt/separateLeadStereo

It takes some work to get up and running under Windows (Install Python 2.7.6, set up PIP and install numpy ,scipy and matplotlib dependencies). You absolutely must use a 64 bit edition of both Windows and Python since it won't work properly with a full song on 32 bit systems. You can simply download a copy of the source zip file and open a CMD window in the "separateLeadStereo-master" folder and do this:

python separateLeadStereoParam.py wavfile.wav

Paste the song into the folder first (must be WAV. not MP3) and replace wavfile with the file name. It will take a good amount of time to process a 3 minute song (20 to 25 minutes) and when done it will spit out 4 different files: acc and lead, and 2 others with the name ending in VUIMM. From what I can tell, VUIMM grabs the consonants better, but introduces more drum bleed with the vocal estimation (lead) and the instrumental (acc)'s drums will be preserved less than the normal, non VUIMM estimations. It works on even the muddiest recordings... I've used it on mono tracks, and old low-fi pieces. I hope this helps.

steve
Site Admin
Posts: 81609
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Reduce voice not eliminate

Post by steve » Tue Apr 25, 2017 9:02 pm

Thanks jh90s, very interesting.

It's quite easy to get it running on Linux, but you're right that it is extremely slow.
From my short test, I'd not say that the sound quality was 'good', there are some very weird sounding noises coming through on the vocal isolated track, but considering how technically difficult the task is, I agree that it does a creditable job.

Looking at the paper from which the algorithm is derived gives interesting background to how it works and what can reasonably be expected. In particular:
In this paper, we consider musical pieces or excerpts where such a leading instrument is clearly identifiable and unique. The latter assumption particularly implies that the melody line is not harmonized with multiple voices. We assume that its energy is mostly predominant over the other instruments of the mixture. These can thus be assimilated to the accompaniment. This implies that we are tracking an instrument with a rather high average energy in the processed song and a continuous fundamental frequency line. In this section and in Section III, the parameters mainly reflect the spectral shapes and the amplitudes, in other words the energy. In Section IV, we focus more on the melody tracking and therefore propose a model for the continuity of the melodic line.
It would be interesting to know how much quicker the algorithm could run if written in C/C++, but there's some hellishly complicated processing involved, as indicated by this extract (below):
extract.gif
extract.gif (31.23 KiB) Viewed 3173 times
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

jh90s
Posts: 115
Joined: Sun Feb 26, 2017 4:05 am
Operating System: Windows 10

Re: Reduce voice not eliminate

Post by jh90s » Tue Apr 25, 2017 10:14 pm

Steve, my brain exploded when I looked at the image you attached. haha. I tried to get it running on Linux, but failed to do so. What distribution did you use? I tried to get it running on Ubuntu MATE 17.04 and it gave me an error. There are a few parameters in the main script "separateLeadStereoParam" which can be adjusted which can allow for better results, but expect to wait even longer (understandably). The script is extremely accurate, considering the fact that it's automatic with no initial input, and I've actually isolated a vocal track before and was able to use it on an (unreleased) mashup between a song I remade and the extracted vocals.

Oh, and as for the parameters: You can either edit the default amount of iterations it does (default is 30) in the script itself, or you could use a flag which you can add when you type the script name and the wav file

python separateLeadStereoParam.py wavfile.wav --nb-iterations x (x being the number)

From what I can tell, iterations are, in simple terms, the amount of times it goes through the mix to grab the calculated estimations. I had a song process with it set to 150 iterations, and it gave better results, but I had it process when I went to sleep and I listened to the results when I got up.

There's 1 more flag which I'm unsure of what it does, but it improves separation results as well:
--numFilters (It's defaulted at a measly 10. I had it set to 40, and it gave better results)

On a side note: Be sure to normalize any recordings you want to do this with (-1.5 to -2 dB) as it has a bit of a glitch where it will noticeably clip the drum hits in the _acc estimations (both the normal one and the VUIMM)

steve
Site Admin
Posts: 81609
Joined: Sat Dec 01, 2007 11:43 am
Operating System: Linux *buntu

Re: Reduce voice not eliminate

Post by steve » Tue Apr 25, 2017 11:44 pm

jh90s wrote:What distribution did you use?
Xubuntu 16.04.1 64-bit
jh90s wrote:There are a few parameters in the main script
Yes thanks, I got the list by reading the instructions :D

Code: Select all

  -h, --help            show this help message and exit
  -v VOC_OUTPUT_FILE, --vocal-output-file=VOC_OUTPUT_FILE
                        name of the audio output file for the estimated solo
                        (vocal) part.  If None, appends _lead to
                        inputAudioFile.
  -m MUS_OUTPUT_FILE, --music-output-file=MUS_OUTPUT_FILE
                        name of the audio output file for the estimated music
                        part. If None, appends _acc to inputAudioFile.
  -p PITCH_OUTPUT_FILE, --pitch-output-file=PITCH_OUTPUT_FILE
                        name of the output file for the estimated pitches. If
                        None, appends _pitches to inputAudioFile
  -d, --with-display    display the figures
  -q, --quiet           use to quiet all output verbose
  -n, --dontseparate    Trigger this option if you only desire to estimate the
                        melody
  --nb-iterations=NBITER
                        number of iterations
  --window-size=WINDOWSIZE
                        size of analysis windows, in s.
  --Fourier-size=FOURIERSIZE
                        size of Fourier transforms, in samples.
  --hopsize=HOPSIZE     size of the hop between analysis windows, in s.
  --nb-accElements=R    number of elements for the accompaniment.
  --with-melody=MELODY  provide the melody in a file named MELODY, with at
                        each line: <time (s)><F0 (Hz)>.
  --numAtomFilters=P_NUMATOMFILTERS
                        Number of atomic filters - in WGAMMA.
  --numFilters=K_NUMFILTERS
                        Number of filters for decomposition - in WPHI
  --min-F0-Freq=MINF0   Minimum of fundamental frequency F0.
  --max-F0-Freq=MAXF0   Maximum of fundamental frequency F0.
  --step-F0s=STEPNOTES  Number of F0s in dictionary for each semitone.
jh90s wrote: had a song process with it set to 150 iterations, and it gave better results, but I had it process when I went to sleep and I listened to the results when I got up.
I was thinking of doing the same as an experiment - probably will when I get round to it.
Unless a C/C++ version could massively speed up the processing, I don't think this will be a viable candidate for a new Audacity effect, but good to know it's out there. Due to the complexity of the algorithm, I doubt that even a C/C++ version would be quick enough, and it would be a lot of work even to find out what order of speed increase could be expected (unless someone has already coded a C/C++ version).
9/10 questions are answered in the FREQUENTLY ASKED QUESTIONS (FAQ)

Post Reply