code: def test_finetune_model(self):
      finetune_model = build_model(self.model_config)
      finetune_model.eval()
      test_sample = Sample()
      test_sample.input_ids = torch.randint(
          low=0, high=30255, size=(128,)
      ).long()
      test_sample.input_mask = torch.ones(128).long()
      test_sample.segment_ids = torch.zeros(128).long()
      test_sample.image = torch.rand((3, 300, 300)).float()
      test_sample_list = SampleList([test_sample.copy()])
  
      with torch.no_grad():
          model_output = finetune_model.model(test_sample_list)
  
      test_sample_list = SampleList([test_sample])
      script_model = torch.jit.script(finetune_model.model)
      with torch.no_grad():
          script_output = script_model(test_sample_list)
  
      self.assertTrue(
          torch.equal(model_output["scores"], script_output["scores"])
      )
  
imports: import gc
  import unittest
  import tests.test_utils
  import torch
  from mmf.common.sample import Sample, SampleList
  from mmf.models.mmbt import MMBT
  from mmf.modules.encoders import ImageEncoderFactory, ImageEncoderTypes, ResNet152ImageEncoder, TextEncoderFactory, TextEncoderTypes
  from mmf.modules.hf_layers import undo_replace_with_jit
  from mmf.utils.build import build_model
  from mmf.utils.configuration import Configuration
  from mmf.utils.env import setup_imports, teardown_imports
  from omegaconf import OmegaConf
label_desc: Use image node_id 4 for calling the TestMMBTTorchscript obj's underlying member method code with example usage: obj.test_finetune_model() without return types