## 5 Pre-Processing Techniques
### Room Impulse Response Reshaping  
Another possibility for taking into account the psychoacoustic characteristics of the ear is that of reshaping the impulse response in such a way that the alteration of the room becomes inaudible. In RIR shortening, the attenuation of the original RIR is accelerated so that the reverberation effect is weakened. Different techniques have been proposed in the literature [78; 122; 123; 124; 125; 126; 127; 128; 129; 130]. In what follows, we review the most relevant methods. Most of these methods are not RRE methods in a strict sense, but they could be easily combined with RRE techniques.  
The first attempts of RIR reshaping [122; 123] tried to adapt the concepts of channel shortening developed in the telecommunication area [131; 132; 133; 134], applying least-squares optimization algorithms. By properly designing a reshaping filter, it is possible to maximize the energy of the equalized RIR in a desired time window, minimizing at the same time the tails of the room response in an undesired window. In this way, for example, it is possible to directly maximize the D50 measure for intelligibility of speech, which is the ratio of the energy within 50 ms after the first peak of an RIR versus the energy of the complete response. The least-squares optimization of the reshaping filter segregating the desired time window from the undesired window provided unsatisfactory results [122] in the form of audible late echoes or spectral distortions. These problems are caused by the strong separation imposed considering non-overlapping desired and undesired windows, and by the least-squares optimization that leads to a non-uniform error distribution. Thus, already in [122] the authors modified the channel shortening paradigm with the aim of shaping the desired impulse response to a shorter reverberation time, considering a gradual transition between the desired and undesired windows.  
The approach was improved in [78; 124; 126; 127]. These approaches exploit the psychoacoustic properties of the human auditory system, and in particular the forward-masking effect. They aim to obtain an equalized response that decays sufficiently quickly to avoid audible echoes, such that the reverberation time is masked by the direct sound according to the forward-masking effect of the human auditory system. The desired and undesired windows are here specified according to the average forward masking curve of [47] and [43]. Moreover, to avoid the problems due to least-squares optimization, infinity-norm and \(p\)-norm optimization (with large values of \(p\)) are proposed. The approach is also applied to multi-channel problems in [125; 130].  
No spectral requirement is imposed by any of the above-mentioned RIR reshaping approaches. In most cases, these approaches usually yield a flat overall frequency response, but with very long impulse responses they may lead to spectral distortions [128]. To contrast this problem, in [128] the objective function is modified to incorporate a \(p\)-norm-based regularization term in the frequency domain, thus imposing the joint optimization in time and frequency domains. In [135], the regularization term is replaced by an integrated spectral flatness measure, which allows the integration of the concept of auditory scales into the equalizer design. Thus, the approaches of [128; 135] combine RIR reshaping with RRE.