I have just completed a long batch process (48 h) on some wav-format files with a high sampling rate, only to find that the ‘cleaned’ files have shrunk.
The original files are up to 60 min in length, 2 ch, sampling rate of 500 kHz, 16 bit. That equates to 1800024832 samples, and weighs in at around 7 Gb. When searching for a specific event time I found that the end of one files was missing. To cut the story short, Audacity only loaded the first 24 min before applying the chain. Strangely, 24 min is also the length shown in windows explorer file properties. When i open the files in Raven Pro though the entire 60 min recording period is present.
Can anyone tell me what is going on please? And how I can get Audacity to load and process the whole 60 min of audio?
The chain just uses the normalise module to remove a dc offset, applies a 10 Hz hi-pass filter then exports the output as a wav file.
I don’t like the sound of that, and the Wikipedia entry for wav also states a 4 Gb limit. But, the files were created ok and I can see their entirety in Raven Pro. Perhaps this is because Raven only loads short segments into memory at a time? And audacity loads the whole thing.
I will start looking at how to split the files, maybe using matlab.
It is “possible” to have WAV files greater than 4 GB, and such files “may” work in some programs on some computers, but such files do not comply with the WAV format standard. For a standard WAV file, the file size header uses a 32-bit number and 32-bit numbers have a maximum value of 4294967296 (the 4 GB limit). If a 64 bit number is used, then the file can be larger, but it is then not a “legal” WAV file because the WAV file specification requires a 32-bit number.
If you can produce RF64 files Audacity will recognise those of any length. Audacity can also export to RF64, but not unfortunately in a Chain.
Audacity can also import “WAV” files over 4 GB using File > Import > Raw Data… if you give it the correct file properties (the headers in the file will be a small “click”).
A Chain applied to files can only use standard import. If you set a rule for WAV in Extended Import Preferences (uncheck “Attempt to use…”) you can force FFmpeg if installed to import the WAV for your Chain, but I have no idea whether FFmpeg handles WAV’s over the legal size any differently.
Thanks Gale. So I’ve managed to import single 7 Gb ‘illegal’ wav files using ffmpeg, and apply some edits. But I’m stumped if i’m not able do this as a batch process, nor export the processed file as ‘wav’. Never mind, will find some kind of workaround I’m sure.
They are “illegal” if they have WAV extension and/or WAV headers.
Have you looked in MediaInfo or a hex editor at the file headers? Note: if you obtain MediaInfo, get the version without installer - the installer may have adware or malware.
If FFmpeg can import the complete WAV’s you can run a Chain that imports those “WAV” files providing you set an extended import rule for FFmpeg to take WAV.
The problem is that you can’t export through the Chain as RF64 which is the “legal” format to use.
If you are using Audacity 2.0.6 or later you can export through the Chain as FLAC which is also lossless (it takes about half the size of WAV). 2.0.6 or later is needed because there is a 2 GB maximum export limitation for Windows in the libflac version used in earlier Audacity versions.