Help with editing

I am using Ver 2.1.1 on Windows 7. I have a clip of organ music I recorded using a single track Sansa Clip. Unfortunately during the recording a hot air furnace in the auditorium came on resulting in several loud clicks over a few seconds of the recording. I have loaded the clip into Audacity and was unable to understand the Tutorial on editing. What I need is someone to walk me through the editing process. Many thanks…mac895

Please post a WAV file that is a sample of the offending audio. See How to post an audio sample.


Gale

I think I have saved a sample of the recording where the outside noise occyrred. I will try to attach it

I doubt the furnace caused the clicks. You have severe overshoot clipping where the samples reverse polarity. Instead of flat topping at the positive (top) part of the waveform, they shoot down to the bottom (negative) part:
overshoot.png
That abrupt change of direction causes a severe click.

You can zoom in (CTRL + 1) then select a region about the size of the region in the image above, then use Effect > Repair….

As far as I know we don’t have a plugin that deals with that type of clipping by selecting all the audio at once. If there is such, someone will say.


Gale

I moved your question about copying material from our Tutorials to https://forum.audacityteam.org/t/copying-material-from-tutorials-closed/40002/1


Gale

To expand on Gale’s correct answer…

" You have severe overshoot clipping where the samples reverse polarity."

Looking at 24 bit waveforms… as part of the analog to digital process, the initial waveform is captured 48,000 or 44,100 times a second (48kHz or 44.1kHz sample rate)…

… and converted into a large number - so big that it takes (say) 24 bits of memory to store/manipulate (lets ignore 32 bit floating, dither, etc). Because the waveform swings around a center line the number can be positive or negative. It’s a whole number so it’s a “Signed” (+ or -) “integer” (whole number).

that number calculated from the sampling process (for 24 bit) is somewhere between −8,388,608 to 8,388,607.

When some code tries to push that number past its end point (too big), it loops right around to the negative side and works up towards zero

eg: 8,388,607 + 3 = −8,388,606

or in this case, probably generates an error and is held at −8,388,608 for a few samples before the wavefom starts to come back from 8,388,607 (looking at the image of the waveform).

I wonder if this was handled with later code along the lines of (sloppy pseudocode):

if (sampleValue) greater than “8,388,607” then
sampleValue = “8,388,607” // effectively limiting the number, stops it from “reversing polarity”
end if

So are you requesting an Audacity feature to correct reverse polarity? I think someone (tried to) modify Clipfix to do this, some years ago.


Gale

That was me It was one of my first attempts to modify a Nyquist plug-in.
See: Clipfix (see waveform pic) - plugins available? - #43 by steve

Do you still regard that code as alpha/pre-alpha from your now more experienced perspective?


Gale

I recorded using a single track Sansa Clip.



You have severe overshoot clipping where the samples reverse polarity. Instead of flat topping at the positive (top) part of the waveform, they shoot down to the bottom (negative) part:

So, now we know the Sansa has a bad defect when recording!

An ADC (or DAC or any digital signal processing) should [u]clip[/u] if you try to go over the maximum. Clipping is distortion and it’s bad too, so it’s best if you can keep your levels down, but polarity reversal is a LOT worse.

“Proof of concept” would be a good description.
Clipfix.ny itself could do with being rewritten to be easier to read and maintain, but it works, so that’s not very high priority. It’s just not a good example of Nyquist code.