// If the user didn"t specify tuning, do it ourselves
if "tuning" not in kwargs:
pitches, magnitudes, S = ifptrack(y, sr, n_fft=n_fft, hop_length=hop_length)
pitches = pitches[magnitudes > np.median(magnitudes)]
del magnitudes
bins_per_octave = kwargs.get("bins_per_octave", 12)
kwargs["tuning"] = estimate_tuning(pitches, bins_per_octave=bins_per_octave)