@slow_test
@testing.requires_testing_data
def test_make_inverse_operator():
 evoked = _get_evoked()
 noise_cov = read_cov(fname_cov)
 inverse_operator = read_inverse_operator(fname_inv)
 fwd_op = read_forward_solution_meg(fname_fwd, surf_ori=True)
 my_inv_op = make_inverse_operator(evoked.info, fwd_op, noise_cov, loose=0.2, depth=0.8, limit_depth_chs=False)
 _compare_io(my_inv_op)
 assert_true((inverse_operator['units'] == 'Am'))
 _compare_inverses_approx(my_inv_op, inverse_operator, evoked, 0.01, 0.01, check_depth=False)
 my_inv_op = make_inverse_operator(evoked.info, fwd_op, noise_cov, loose=0.2, depth=0.8)
 _compare_io(my_inv_op)
 _compare_inverses_approx(my_inv_op, inverse_operator, evoked, 0.01, 0.01)
 assert_true(('dev_head_t' in my_inv_op['info']))
 assert_true(('mri_head_t' in my_inv_op))

@ slow_test @ testing . requires_testing_data def test_make_inverse_operator ( ) : evoked = _get_evoked ( ) noise_cov = read_cov ( fname_cov ) inverse_operator = read_inverse_operator ( fname_inv ) fwd_op = read_forward_solution_meg ( fname_fwd , surf_ori = True ) my_inv_op = make_inverse_operator ( evoked . info , fwd_op , noise_cov , loose = 0.2 , depth = 0.8 , limit_depth_chs = False ) _compare_io ( my_inv_op ) assert_true ( ( inverse_operator [ 'units' ] == 'Am' ) ) _compare_inverses_approx ( my_inv_op , inverse_operator , evoked , 0.01 , 0.01 , check_depth = False ) my_inv_op = make_inverse_operator ( evoked . info , fwd_op , noise_cov , loose = 0.2 , depth = 0.8 ) _compare_io ( my_inv_op ) _compare_inverses_approx ( my_inv_op , inverse_operator , evoked , 0.01 , 0.01 ) assert_true ( ( 'dev_head_t' in my_inv_op [ 'info' ] ) ) assert_true ( ( 'mri_head_t' in my_inv_op ) )
test mne inverse computation .