code: def _test__hvd_dist_model_create_from_context_dist(
      true_backend, true_device
  ):
      assert _HorovodDistModel.create_from_context() is None
  
      hvd.init()
      lrank = hvd.local_rank()
      if torch.cuda.is_available():
          torch.cuda.set_device(lrank)
  
      true_conf = {
          "device": true_device,
          "local_rank": lrank,
          "rank": hvd.rank(),
          "world_size": hvd.size(),
          "node_index": 0,
          "nnodes": 1,
          "nproc_per_node": hvd.local_size(),
      }
  
      model = _HorovodDistModel.create_from_context()
      assert model.backend() == true_backend
      _assert_model(model, true_conf)
  
      hvd.shutdown()
  
file_path: ignite/tests/ignite/distributed/comp_models/test_horovod.py
imports: import pytest
  import torch
  from ignite.distributed.comp_models import has_hvd_support
label_desc: Use image node_id 6 for calling a global function with example usage: _test__hvd_dist_model_create_from_context_dist(true_backend, true_device) without return types