code: def in_bad_fork_test() -> bool:
      _ = torch.cuda.is_available()
      return torch.cuda._is_in_bad_fork()
  
file_path: pytorch/test/test_cuda_nvml_based_avail.py
imports: import os
  import sys
  import multiprocessing
  import torch
  import unittest
  from unittest.mock import patch
label_desc: Use image node_id 2 for calling the TestExtendedCUDAIsAvail obj's underlying member method code with example usage: obj.in_bad_fork_test() and returns: torch