A novel illumination compensate method is proposed in this paper to improve recognition performance. A modified lighting model called Lambertin which includes additive noise and multiplicative noise are presented firstly. Then, additive noise is removed by using wavelet packet transformation. Next, the processed image is transformed into logarithm domain and the multiplicative noise, which has been named additive noise, is removed by means of the same above algorithm. Finally, a compensated face image is obtained. We examine the proposed method on Yale extended B database compared with other methods. Experimental results show that our algorithm improves by 3%~12% recognition rate. It can effectively adjust the facial images for varying illumination conditions and also improve the recognition performance and robustness.