code: def test_distributed_data_loading(ray_start_4_cpus):
      """Checks that XGBoostTrainer does distributed data loading for Datasets."""
  
      class DummyXGBoostTrainer(XGBoostTrainer):
          def _train(self, params, dtrain, **kwargs):
              assert dtrain.distributed
              return super()._train(
                  params=params, dtrain=dtrain, **kwargs
              )
  
      train_dataset = ray.data.from_pandas(train_df)
  
      trainer = DummyXGBoostTrainer(
          scaling_config=ScalingConfig(num_workers=2),
          label_column="target",
          params=params,
          datasets={TRAIN_DATASET_KEY: train_dataset},
      )
  
      assert trainer.dmatrix_params[TRAIN_DATASET_KEY]["distributed"]
      trainer.fit()
  
imports: import json
  import pandas
  import pytest
  import xgboost
  from sklearn.datasets import load_breast_cancer
  from sklearn.model_selection import train_test_split
  import ray
  from ray import train, tune
  from ray.train import ScalingConfig
  from ray.train.constants import TRAIN_DATASET_KEY
  from ray.train.xgboost import XGBoostTrainer
label_desc: Use image node_id 10 for calling a global function with example usage: test_distributed_data_loading(ray_start_4_cpus) and returns: super