code: def test_copy_gen_outp_has_no_prob_of_pad(self):
      for params, init_case in itertools.product(
          self.PARAMS, self.INIT_CASES
      ):
          cgen = CopyGenerator(**init_case)
          dummy_in = self.dummy_inputs(params, init_case)
          res = cgen(*dummy_in)
          self.assertTrue(
              res[:, init_case["pad_idx"]].allclose(torch.tensor(0.0))
          )
  
imports: import unittest
  from onmt.modules.copy_generator import CopyGenerator, CopyGeneratorLoss
  import itertools
  from copy import deepcopy
  import torch
  from torch.nn.functional import softmax
  from onmt.tests.utils_for_tests import product_dict
label_desc: Use image node_id 4 for calling the TestCopyGenerator obj's underlying member method code with example usage: obj.test_copy_gen_outp_has_no_prob_of_pad() without return types