#NEWLINE# def test_clipped( self ) : #NEWLINE# #INDENT# x = self . x #NEWLINE# res_r = self . res #NEWLINE# y = corr_clipped ( x , threshold = 1e-07 ) #NEWLINE# assert_almost_equal ( y , res_r . mat , decimal = 1 ) #NEWLINE# d = norm_f ( x , y ) #NEWLINE# assert_allclose ( d , res_r . normF , rtol = 0.15 ) #NEWLINE# evals = np . linalg . eigvalsh ( y ) #NEWLINE# assert_allclose ( evals , res_r . eigenvalues [ : : ( - 1 ) ] , rtol = 0.1 , atol = 1e-07 ) #NEWLINE# assert_allclose ( evals [ 0 ] , 1e-07 , rtol = 0.02 )