code: def test_bgl_unmitigated_same(A_two_dim):
      a0_count = 4
      a1_count = 4
  
      a0_label = 2
      a1_label = 3
  
      a0_factor = 1
      a1_factor = 16
  
      X, y, A = _simple_regression_data(
          a0_count,
          a1_count,
          a0_factor,
          a1_factor,
          a0_label,
          a1_label,
          A_two_dim,
      )
  
      estimator = LinearRegression()
  
      unmitigated_estimator = copy.deepcopy(estimator)
      unmitigated_estimator.fit(X, y)
  
      # Do the grid search with a zero Lagrange multiplier
      idx = pd.Index(sorted([a0_label, a1_label]))
      lagrange_balanced_series = pd.Series([1.0, 1.0], index=idx)
      grid_df = pd.DataFrame(lagrange_balanced_series)
  
      grid_search = GridSearch(
          estimator,
          constraints=BoundedGroupLoss(ZeroOneLoss()),
          grid=grid_df,
      )
      grid_search.fit(X, y, sensitive_features=A)
  
      raw_coef = unmitigated_estimator.coef_
      gs_coef = grid_search.predictors_[grid_search.best_idx_].coef_
      # Can't quite get exact match, but this should be very close
      assert np.allclose(raw_coef, gs_coef, rtol=1e-10, atol=1e-7)
  
file_path: fairlearn/test/unit/reductions/grid_search/test_grid_search_regression.py
imports: import copy
  from test.unit.reductions.grid_search.utilities import assert_n_grid_search_results
  from test.unit.utility_functions import logging_all_close
  import numpy
  import pandas
  import pytest
  from sklearn.linear_model import LinearRegression
  from fairlearn.reductions import BoundedGroupLoss, GridSearch, SquareLoss, ZeroOneLoss
label_desc: Use image node_id 3 for calling a global function with example usage: test_bgl_unmitigated_same(A_two_dim) without return types