code: def test_torch_utility_usage_tags(shutdown_only, framework):
      from ray._private.usage.usage_lib import (
          TagKey,
          get_extra_usage_tags_to_report,
      )
  
      ctx = ray.init()
      gcs_client = ray._raylet.GcsClient(
          address=ctx.address_info["gcs_address"]
      )
  
      if framework == "torch":
          run_torch()
          expected_tags = [
              TagKey.TRAIN_TORCH_GET_DEVICE,
              TagKey.TRAIN_TORCH_PREPARE_MODEL,
              TagKey.TRAIN_TORCH_PREPARE_DATALOADER,
          ]
      elif framework == "lightning":
          run_lightning()
          expected_tags = [
              TagKey.TRAIN_LIGHTNING_PREPARE_TRAINER,
              TagKey.TRAIN_LIGHTNING_RAYTRAINREPORTCALLBACK,
              TagKey.TRAIN_LIGHTNING_RAYDDPSTRATEGY,
              TagKey.TRAIN_LIGHTNING_RAYFSDPSTRATEGY,
              TagKey.TRAIN_LIGHTNING_RAYDEEPSPEEDSTRATEGY,
              TagKey.TRAIN_LIGHTNING_RAYLIGHTNINGENVIRONMENT,
          ]
      elif framework == "transformers":
          run_transformers()
          expected_tags = [
              TagKey.TRAIN_TRANSFORMERS_PREPARE_TRAINER,
              TagKey.TRAIN_TRANSFORMERS_RAYTRAINREPORTCALLBACK,
          ]
  
      result = get_extra_usage_tags_to_report(gcs_client)
      assert set(result.keys()).issuperset(
          {TagKey.Name(tag).lower() for tag in expected_tags}
      )
  
file_path: ray/python/ray/train/tests/test_train_usage.py
imports: import pytest
  import torch
  import ray
  from ray.train import ScalingConfig
  from ray.train.torch import TorchTrainer
label_desc: Use image node_id 5 for calling a global function with example usage: test_torch_utility_usage_tags(shutdown_only, framework) without return types