Re: Fwd: Re: merging mono files

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Hi all,

What you are saying is right. I did find one pair of files that have different lengths of audio. This surprised me somewhat. Generally, the files are identical in length and carry the loop marks in exactly the same place.

Irrespective of any differences, I would still like to merge all the pairs of files into stereo. It should not be such a difficult task recreating loops again and inserting pitch tuning data. LoopAuditioneer does all that quite fast and what is left is to check that the loops do not present clicks.... again.... I can do pretty well and efficiently having done the job so often.

So, forget loops and marks and other data as the issue is complicating itself unnecessarily.

The question remains how can I use SoX (what is the script that the program recognises to accomplish the task) to automate the merging process of a number of L and R pairs of recordings into single stereo files in a separate folder. As has been pointed out the L and R files are stereo themselves with one channel muted or blank. The script must essentially match the name of the file pairs which are located in respective Left and Right folders eg BourdoneL and BourdoneR, PrincipalL and PrincipalR, TrumpetL and TrumpetR, etc.

Mark


On 10/12/2016 10:23, Jeremy Nicoll - ml sox users wrote:
On 2016-12-10 06:44, Dr. Mark Bugeja MD wrote:
The files have to match in name not size
Oh?

I think what you mean is that you WANT the final stereo file to have the
same (note/pitch) name as the left & right parts.

But from everything you've said, as each pair of left & right files are 
meant to
have been created from the same original source file, they should have 
the exact
same size.  Putting a check that that's actually the case into a script 
that
is automating merging is the kind of thing a programmer would do as an 
example
of 'sanity checking'.  It should always be true, but if it isn't it's 
better
that the script stops what it's doing so the user can investigate why.

On the other hand, if you already have lots of pairs of files which are 
not the
same size... why is that?

Maybe they contain the same number of audio samples, but different 
amounts of header
data?  If that's commonly the case I would add to my script calls of sox 
with the
stat or stats (or both) effects to check in more detail that the audio 
in each file
has common characteristics.

I might also change code that expected files to be the same size, to 
something that
(say) accepted only very small differences in size.


It's normal for carefully-written programs to check that everything they 
do actually
works, because a program can get into a terrible mess if it just issues 
commands and
assumes that every one of them did exactly what was hoped.  Depending 
somewhat on the
language that a program is written in, maybe two thirds of the code in a 
program will
be all about checking for problems and recovering from them.





Avast logo

This email has been checked for viruses by Avast antivirus software.
www.avast.com


------------------------------------------------------------------------------
Developer Access Program for Intel Xeon Phi Processors
Access to Intel Xeon Phi processor-based developer platforms.
With one year of Intel Parallel Studio XE.
Training and support from Colfax.
Order your platform today.http://sdm.link/xeonphi
_______________________________________________
Sox-users mailing list
Sox-users@xxxxxxxxxxxxxxxxxxxxx
https://lists.sourceforge.net/lists/listinfo/sox-users

[Index of Archives]     [Linux Sound]     [ALSA Users]     [ALSA Devel]     [Linux Audio Users]     [Linux Media]     [Kernel]     [Photo Sharing]     [Gimp]     [Yosemite News]     [Linux Media]

  Powered by Linux