code: def test_lbfgs_toy(n_parts, datatype, client):
      def imp():
          import cuml.comm.serialize  # NOQA
  
      client.run(imp)
  
      X = np.array([(1, 2), (1, 3), (2, 1), (3, 1)], datatype)
      y = np.array([1.0, 1.0, 0.0, 0.0], datatype)
  
      from cuml.dask.linear_model import (
          LogisticRegression as cumlLBFGS_dask,
      )
  
      X_df, y_df = _prep_training_data(client, X, y, n_parts)
  
      lr = cumlLBFGS_dask()
  
      lr.fit(X_df, y_df)
  
      lr_coef = lr.coef_.to_numpy()
      lr_intercept = lr.intercept_.to_numpy()
  
      assert len(lr_coef) == 1
      assert lr_coef[0] == pytest.approx(
          [-0.71483153, 0.7148315], abs=1e-6
      )
      assert lr_intercept == pytest.approx([-2.2614916e-08], abs=1e-6)
  
      # test predict
      preds = lr.predict(X_df, delayed=True).compute().to_numpy()
      from numpy.testing import assert_array_equal
  
      assert_array_equal(preds, y, strict=True)
  
      # assert error on float64
      X = X.astype(np.float64)
      y = y.astype(np.float64)
      X_df, y_df = _prep_training_data(client, X, y, n_parts)
      with pytest.raises(
          RuntimeError,
          match="dtypes other than float32 are currently not supported yet. See issue: https://github.com/rapidsai/cuml/issues/5589",
      ):
          lr.fit(X_df, y_df)
  
imports: from cuml.internals.safe_imports import gpu_only_import
  import pytest
  from cuml.dask.common import utils
  from functools import partial
  from sklearn.metrics import accuracy_score, mean_squared_error
  from sklearn.datasets import make_classification
  from sklearn.linear_model import LogisticRegression
  from cuml.internals.safe_imports import cpu_only_import
  from cuml.testing.utils import array_equal
  from scipy.sparse import csr_matrix
label_desc: Use image node_id 6 for calling a global function with example usage: test_lbfgs_toy(n_parts, datatype, client) without return types