Ingreso rápido:  

Forum: Wishes and new features

Tema: Stems custom export
Hi,

CDJ Stems export is great, but it would be nice to have a custom STEMS export for other Software, with full name for file and just add in tag (tag preserved in stems files), accapella, instruments, bass.... to choose the codec, the name of stems, and tags options, one .mp4 files or several files.
With a batch option like CDJ stems export

Regards,

Olivier
 

Mensajes Sun 27 Nov 22 @ 10:17 am
AdionPRO InfinityCTOMember since 2006
The .vdjstems file when preparing stems is already a regular mp4 file, so you can easily create a ffmpeg script to extract a specific stem in the format that you like.
 

Mensajes Sun 27 Nov 22 @ 10:28 am
very nice idea. But i want to export in .flac not in .aac, and not cobnvert .aac to .flac :)
 

Mensajes Sun 27 Nov 22 @ 1:15 pm
olivier REMUX wrote :
very nice idea. But i want to export in .flac or .aiff not in .aac, and not convert .aac to .flac :)


 

Mensajes Sun 27 Nov 22 @ 1:15 pm
Adion wrote :
The .vdjstems file when preparing stems is already a regular mp4 file, so you can easily create a ffmpeg script to extract a specific stem in the format that you like.


Thanks Adion,

good video, here , i will adapt the code :

https://www.youtube.com/watch?v=I0buEOp3l1k
 

Mensajes Sun 27 Nov 22 @ 1:48 pm
Adion wrote :
The .vdjstems file when preparing stems is already a regular mp4 file, so you can easily create a ffmpeg script to extract a specific stem in the format that you like.


Hi,

my mac .sh script (for terminal)

#!/bin/bash

echo "Glisser le dossier qui contient le fichiers originaux et les .vdjstems à traiter ici : "
read chemin
for i in $chemin/*.vdjstems;
do
[ -f "$i" ] || break

echo "DOSSIER traité : " $chemin
echo "nom original traité : " $i


ffmpeg -i "$i" -map 0:a:0 -c copy "$i-VOCAL.m4a" -map 0:a:1 -c copy "$i-HITHAT.m4a" -map 0:a:2 -c copy "$i-Bass.m4a" -map 0:a:3 -c copy "$i-instruments.m4a" -map 0:a:4 -c copy "$i-kick.m4a"

done


but how i make Kick + Hithat with ffmpef ? or other combination ?
how i transfer tags from original files ?

 

Mensajes Sun 27 Nov 22 @ 3:28 pm
AdionPRO InfinityCTOMember since 2006
 

Mensajes Mon 28 Nov 22 @ 5:17 am


Hello Adion,

ffmpeg -i "$i" -i "$i" -i "$i" -i "$i" -filter_complex [0:1][0:2][0:3][0:4]amix=inputs=4 "$new_i-INSTRUMENTAL.aif"

-> this works to maje full instrumental without vocal

many thanks, i've improved my script for my .aif files with .vdjstems on my SSD :
new .sh script
-------------------------------------
#!/bin/sh

export PATH=/opt/homebrew/bin:$PATH #patch where home-brew and FFmpeg are installed on my MAC M1


echo "Glisser le dossier qui contient les .vdjstems à traiter ici : "
read chemin
for i in $chemin/*.vdjstems; do
[ -f "$i" ] || break

echo "DOSSIER traité : " $chemin


new_i=$(echo "${i:0:${#i}-13}") #delete .aif.vdjstems extensions


ffmpeg -i "$i" -map 0:0 "$new_i-VOCAL.aif"

ffmpeg -i "$i" -i "$i" -i "$i" -i "$i" -filter_complex [0:1][0:2][0:3][0:4]amix=inputs=4 "$new_i-INSTRUMENTAL.aif"


done
--------------

now i search to copy original tags of my original + new mention of VOCAL and INS - in title tag .aif files to created vocal/instrumental STEMS
 

Mensajes Mon 28 Nov 22 @ 7:29 pm
Final script .sh (for MAC Ventura) need ffmpeg and exiftool :) :

olivier REMUX wrote :

#!/bin/sh

# you need ffmpeg and exiftool installed on your MAC to run this .sh script

export PATH=/opt/homebrew/bin:$PATH #patch where home-brew and FFmpeg are installed on my MAC M1


echo "Glisser le dossier qui contient les .vdjstems à traiter ici : "
read chemin
for i in $chemin/*.vdjstems; do
[ -f "$i" ] || break

echo "DOSSIER traité : " $chemin

original_i=$(echo "${i:0:${#i}-9}") #delete .vdjstems extensions to find original file in same directory

instrumental="$original_i"".instrumental.m4a"
echo "fichier instrumental traité : " $instrumental

vocal="$original_i"".vocal.m4a"
echo "fichier vocal traité : " $vocal

ffmpeg -i "$i" -map 0:0 -c copy "$vocal" # -c copy to preserve AAC STREAM original vocal

ffmpeg -i "$i" -i "$i" -i "$i" -i "$i" -filter_complex [0:1][0:2][0:3][0:4]amix=inputs=4 "$instrumental"

exiftool -addTagsFromFile "$original_i" "$instrumental"
exiftool -addTagsFromFile "$original_i" "$vocal"

exiftool -genre="STEM-INSTRU" "$instrumental"
exiftool -genre="STEM-ACAPELLA" "$vocal"

rm "$instrumental""_original" #delete temp file created from exiftool
rm "$vocal""_original" #delete temp file created from exiftool


done



 

Mensajes Mon 28 Nov 22 @ 9:31 pm



olivier REMUX wrote :
Final script .sh (for MAC Ventura) need ffmpeg and exiftool :) :

#!/bin/sh

# you need ffmpeg and exiftool installed on your MAC to run this .sh script

export PATH=/opt/homebrew/bin:$PATH #patch where home-brew and FFmpeg are installed on my MAC M1


echo "Glisser le dossier qui contient les .vdjstems à traiter ici : "
read chemin
for i in "$chemin"/*.vdjstems; do
[ -f "$i" ] || break

echo "DOSSIER traité : " $chemin

original_i=$(echo "${i:0:${#i}-9}") #delete .vdjstems extensions to find original file in same directory

instrumental="$original_i"".instrumental.m4a"
echo "fichier instrumental traité : " $instrumental

vocal="$original_i"".vocal.m4a"
echo "fichier vocal traité : " $vocal

vocal_BD="$original_i"".vocal_BD.m4a"
echo "fichier vocal traité : " $vocal_BD

ffmpeg -i "$i" -map 0:0 -c copy "$vocal" # -c copy to preserve AAC STREAM original vocal

ffmpeg -i "$i" -i "$i" -i "$i" -i "$i" -filter_complex "[0:1][0:2][0:3][0:4]amerge=inputs=4" -ac 2 -c:a aac -b:a 320k "$instrumental"

ffmpeg -i "$i" -i "$i" -i "$i" -i "$i" -filter_complex "[0:0][0:1][0:2][0:4]amerge=inputs=4" -ac 2 -c:a aac -b:a 320k "$vocal_BD"




exiftool -addTagsFromFile "$original_i" "$instrumental"
exiftool -addTagsFromFile "$original_i" "$vocal"
exiftool -addTagsFromFile "$original_i" "$vocal_BD"


exiftool -genre="STEM-INSTRU" "$instrumental"
exiftool -genre="STEM-ACAPELLA" "$vocal"
exiftool -genre="STEM-VOC+BASS+DRUMS" "$vocal_BD"



rm "$instrumental""_original" #delete temp file created from exiftool
rm "$vocal""_original" #delete temp file created from exiftool
rm "$vocal_BD""_original" #delete temp file created from exiftool



done





Amix is buggy (normalize at -10 db... bad) i use amerge instead in this new script :)
 

Mensajes Sun 11 Dec 22 @ 11:37 pm
Another example, better with ffmpeg and sox (sox used with v - 1 to avoid normalization with combined audio - ffmpeg change volume with amix and amerge so i use in last steps sox instead)

#!/bin/sh


# Extract VirtualDJ .flac + his .vdjstems to 3 files STEMS .flac with tags
# need ffmpeg/Sox/exiftool (install Before from Macport for example)
# sox is used to keep right original volume for each STEMS - ffmpeg have normalize bugs when convert


echo "Glisser le dossier qui contient les .vdjstems à traiter ici : "
read chemin

echo "DOSSIER traité : " $chemin


for i in "$chemin"/*.vdjstems; do
[ -f "$i" ] || break



original_i=$(echo "${i:0:${#i}-14}") #delete .mp3 .aif .Wav .flac .vdjstems extensions to find original file in same directory

original_i2=$(echo "${i:0:${#i}-9}") #delete only .vdjstems


vdjvocal="$original_i""_vdjvocal.wav"
echo "fichier instrumental traité : " $vdjvocal #0 Vocal

vdjdrum1="$original_i""_vdjdrum1.wav"
echo "fichier instrumental traité : " $vdjdrum1 #1 hithat

vdjdrum2="$original_i""_vdjdrum2.wav"
echo "fichier instrumental traité : " $vdjdrum2 #4 kick

vdjbass="$original_i""_vdjbass.wav"
echo "fichier instrumental traité : " $vdjbass #2 Bass

vdjother="$original_i""_vdjother.wav"
echo "fichier instrumental traité : " $vdjother #3 other



other="$original_i""_other.flac"
echo "fichier instrumental traité : " $other

drum="$original_i""_drum.flac"
echo "fichier vocal traité : " $drum

vocal="$original_i""_vocal.flac"
echo "fichier vocal traité : " $vocal

ffmpeg -i "$i" -map 0:0 "$vdjvocal"
ffmpeg -i "$i" -map 0:1 "$vdjdrum1"
ffmpeg -i "$i" -map 0:2 "$vdjbass"
ffmpeg -i "$i" -map 0:3 "$vdjother"
ffmpeg -i "$i" -map 0:4 "$vdjdrum2"


Sox -v 1 "$vdjvocal" "$vocal"

Sox -m -v 1 "$vdjdrum1" -v 1 "$vdjdrum2" "$drum"

Sox -m -v 1 "$vdjbass" -v 1 "$vdjother" "$other"


metaflac --remove-tag=genre "$other"
metaflac --set-tag=genre="stem-other" "$other"

metaflac --remove-tag=genre "$drum"
metaflac --set-tag=genre="stem-drum" "$drum"

metaflac --remove-tag=genre "$vocal"
metaflac --set-tag=genre="stem-vocal" "$vocal"


rm "$vdjvocal"
rm "$vdjdrum1"
rm "$vdjbass"
rm "$vdjother"
rm "$vdjdrum2"

done
 

Mensajes Sun 02 Apr 23 @ 12:37 am
Better Example with export .flac with gis .vdjstems :
DRUM/VOCAL/OTHER 3 STEMS -> if you play 3X in audacity -> bit perfect like original .flac
( it use other stem = Original flac - vocal aac - drum aac to create in other stems all bits)


#!/bin/sh

# need FFMPEG - SOX and MAC terminal (file.sh)
# Extract .flac and his saved .vdjstems in same directory
# VirtualDJ to 32 bits to 3 files OTHER/DRUM/VOCAL .wav and 32 bits .raw
# if you play Play the 3 .wav in Audacity minor phase inversed original .flac : silence
# so other part is used for bit perfect (other = Original - VOCAL - DRUM
# OTHER+DRUM+VOCAL -> BIT PERFECT of original .flac

export PATH=/opt/homebrew/bin:$PATH #patch where home-brew and FFmpeg are installed on my MAC M1


echo "Glisser le dossier qui contient les .vdjstems à traiter ici : "
read chemin

echo "DOSSIER traité : " $chemin


for i in "$chemin"/*.vdjstems; do
[ -f "$i" ] || break



original_i=$(echo "${i:0:${#i}-14}") #delete .flac .vdjstems extensions to find original file in same directory


vdjvocal="$original_i""_vocal.wav"
echo "fichier instrumental traité : " $vdjvocal #0 Vocal

vdjdrum1="$original_i""_vdjdrum1.wav"
echo "fichier instrumental traité : " $vdjdrum1 #1 hithat

vdjdrum2="$original_i""_vdjdrum2.wav"
echo "fichier instrumental traité : " $vdjdrum2 #4 kick

vdjbass="$original_i""_vdjbass.wav"
echo "fichier instrumental traité : " $vdjbass #2 Bass

vdjother="$original_i""_vdjother.wav"
echo "fichier instrumental traité : " $vdjother #3 other

ffmpeg -i "$i" -map 0:0 "$vdjvocal"
ffmpeg -i "$i" -map 0:1 "$vdjdrum1"
ffmpeg -i "$i" -map 0:2 "$vdjbass"
ffmpeg -i "$i" -map 0:3 "$vdjother"
ffmpeg -i "$i" -map 0:4 "$vdjdrum2"

Sox -v 1 "$original_i"".flac" "$original_i"".wav"

Sox -m -v 1 "$vdjdrum1" -v 1 "$vdjdrum2" "$original_i""_drum.wav"

Sox -v -1 "$original_i""_drum.wav" "$original_i""_vdjdrum_inverted.wav"

Sox -v -1 "$vdjvocal" "$original_i""_vdjvocal_inverted.wav"

Sox -m -v 1 "$original_i"".wav" -v 1 "$original_i""_vdjdrum_inverted.wav" -v 1 "$original_i""_vdjvocal_inverted.wav" "$original_i""_other.wav"


other="$original_i""_other.raw"
echo "fichier instrumental traité : " $other

drum="$original_i""_drum.raw"
echo "fichier vocal traité : " $drum

vocal="$original_i""_vocal.raw"
echo "fichier vocal traité : " $vocal



Sox -v 1 "$vdjvocal" -r 44100 -e floating-point -b 32 -c 2 "$vocal"

Sox -v 1 "$original_i""_drum.wav" -r 44100 -e floating-point -b 32 -c 2 "$drum"

Sox -v 1 "$original_i""_other.wav" -r 44100 -e floating-point -b 32 -c 2 "$other"

rm "$vdjdrum1"
rm "$vdjdrum2"
rm "$vdjbass"
rm "$vdjother"
rm "$original_i""_vdjdrum_inverted.wav"
rm "$original_i""_vdjvocal_inverted.wav"
rm "$original_i"".wav"

done


 

Mensajes Sun 02 Apr 23 @ 10:13 pm
optimised here :


#!/bin/sh

# need FFMPEG - SOX and MAC terminal (file.sh)
# Extract .flac and his saved .vdjstems in same directory
# VirtualDJ to 32 bits to 3 files OTHER/DRUM/VOCAL .wav and 32 bits .raw
# if you play Play the 3 .wav in Audacity minor phase inversed original .flac : silence
# so other part is used for bit perfect (other = Original - VOCAL - DRUM)
# OTHER+DRUM+VOCAL -> BIT PERFECT of original .flac

export PATH=/opt/homebrew/bin:$PATH #patch where home-brew and FFmpeg are installed on my MAC M1


echo "Drag n drop the folder with the .vdjstems to compute here: "
read chemin

echo "FOLDER: " $chemin


for i in "$chemin"/*.vdjstems; do
[ -f "$i" ] || break



original_i=$(echo "${i:0:${#i}-14}") #delete .flac .vdjstems extensions to find original file in same directory


ffmpeg -i "$i" -map 0:0 "$original_i""_vocal.wav" #0 Vocal in .vdjstems
ffmpeg -i "$i" -map 0:1 "$original_i""_vdjdrum1.wav" #1 hithat in .vdjstems
ffmpeg -i "$i" -map 0:4 "$original_i""_vdjdrum2.wav" #4 kick in .vdjstems

Sox -v 1 "$original_i"".flac" "$original_i"".wav" # original to be used to creat other = original - drum - vocal

Sox -m -v 1 "$original_i""_vdjdrum1.wav" -v 1 "$original_i""_vdjdrum2.wav" "$original_i""_drum.wav" # full drum stem drum1 + drum2

# Create Other Stem : Other stem = ( Original + Phase inverted drums + Phase inverted vocals)
# (phase inversion with "-v -1" sox option)

Sox -m -v 1 "$original_i"".wav" -v -1 "$original_i""_vocal.wav" -v -1 "$original_i""_drum.wav" "$original_i""_other.wav"


other="$original_i""_other.raw"
echo "File other : " $other

drum="$original_i""_drum.raw"
echo "File drum : " $drum

vocal="$original_i""_vocal.raw"
echo "File vocal : " $vocal

# RAW 32 bits export option 3 stems
#Sox -v 1 "$original_i""_vocal.wav" -r 44100 -e floating-point -b 32 -c 2 "$vocal"

#Sox -v 1 "$original_i""_drum.wav" -r 44100 -e floating-point -b 32 -c 2 "$drum"

#Sox -v 1 "$original_i""_other.wav" -r 44100 -e floating-point -b 32 -c 2 "$other"

rm "$original_i""_vdjdrum1.wav"
rm "$original_i""_vdjdrum2.wav"
rm "$original_i"".wav"


done

 

Mensajes Mon 03 Apr 23 @ 5:16 pm
This is all fine work.

Unfortunately I am not proficient in code/programming. Do you know if there is any simple downloadable or web based application/program that can convert the .vdjstems file to separate stems/files of common audio formats like .wav, .mp3, .flac. ?

Can any program other than VDJ accommodate/play .vdjstems files, like Adobe Audition, Audacity, or other DAW programs?

Thanks for any information.
 

Mensajes Mon 10 Jul 23 @ 1:50 pm
Yes, like posted it's really just mp4 files

So you can use basically any audio editing software to extract the stems

Here it's shown in audacity (which is free)

 

Mensajes Mon 10 Jul 23 @ 2:15 pm
Hey klausmogensen! This is great! Yes, it is dirty, but relatively quick once you have Audacity properly set. Very grateful for your very quick feedback and terrific YT vid tutorial.

I am using this for separating old personal cassette multi-track original music recordings that involved bounced tracks to mono. Though not perfect, it is stunning in its clarity. VDJ is perhaps the best stems separator I've tried and completely free, plus an unmatched DJ software.

Thanks to all who've participated in this conversation. By all means, let us all know if there is an open-source, free application that will accomplish this conversion from ,vdjstems to .wav/.mp3 in one step. It probably won't be a feature added to VDJ, but maybe someone will write a small application that can skip the audacity process.

Many smiles to Denmark!

UPDATE - I just found out that after renaming the .vdjstems file to .mp4, it can be simply dragged into Adobe Audition, (my DAW of choice), and it will be read instantly. NO NEED to export/convert in Audacity. The multi audio file can then be separated with one right-click so that each channel (L and R) of each stem (10 mono tracks total) is it's own discreet audio file for instant placement in multi-track editor. From there, if you prefer, you can rename each mono track as you like in the folder where it's stored. I Hope this helps others and thanks to all who helped me!
 

Mensajes Mon 10 Jul 23 @ 5:53 pm
UPDATE 2 for Adobe Audition users.

After renaming the .vdjstems file to .mp4, it can be simply dragged into Adobe Audition, and it will be read instantly by the Waveform editor screen. Once opened in the Waveform editor screen it will show all 10 stems all on one track and can be played there in mono

If you switch to the Multitrack editor screen and create a new multi-track session, you'll see the mp4 in the files list. Here's the COOL thing. You can then click on the file while holding the keyboard ALT button and drag it into the Multitrack editor and the files will instantly populate 5 stereo tracks with each separate stereo stem on its own track. They will be saved as separate tracks as well when the multitrack session is saved, but still saved as the original mp4 file. To save each stereo stem as separate audio files, right click on each stem's waveform and make it a unique copy, and it can be saved as it's own stereo audio file when prompted as the session is closed.

I hope this is helpful to those wanting to repurpose those VDJ stems for use in Adobe Audition.
 

Mensajes Wed 12 Jul 23 @ 3:31 pm