def highpassfilter(signal, samplerate, cutoff_freq_hz, filter_order=6):
    """Full spectrum high-pass filter (butterworth)"""
    cutoff_ratio = cutoff_freq_hz / (samplerate / 2.0)
    b, a = scipy.signal.butter(filter_order, cutoff_ratio, btype='high')
    return scipy.signal.filtfilt(b, a, signal)