code: def test_versioned_linspace_out(self):
      class Module(torch.nn.Module):
          def forward(
              self,
              a: Union[int, float, complex],
              b: Union[int, float, complex],
              out: torch.Tensor,
          ):
              return torch.linspace(a, b, steps=100, out=out)
  
      model_path = (
          pytorch_test_dir
          + "/jit/fixtures/test_versioned_linspace_out_v7.ptl"
      )
      loaded_model = torch.jit.load(model_path)
      buffer = io.BytesIO(
          loaded_model._save_to_buffer_for_lite_interpreter()
      )
      buffer.seek(0)
      v7_mobile_module = _load_for_lite_interpreter(buffer)
      current_mobile_module = self._save_load_mobile_module(Module)
  
      sample_inputs = (
          (
              3,
              10,
              torch.empty((100,), dtype=torch.int64),
              torch.empty((100,), dtype=torch.int64),
          ),
          (
              -10,
              10,
              torch.empty((100,), dtype=torch.int64),
              torch.empty((100,), dtype=torch.int64),
          ),
          (
              4.0,
              6.0,
              torch.empty((100,), dtype=torch.float64),
              torch.empty((100,), dtype=torch.float64),
          ),
          (
              3 + 4j,
              4 + 5j,
              torch.empty((100,), dtype=torch.complex64),
              torch.empty((100,), dtype=torch.complex64),
          ),
      )
      for start, end, out_for_old, out_for_new in sample_inputs:
          output = v7_mobile_module(start, end, out_for_old)
          output_current = current_mobile_module(
              start, end, out_for_new
          )
          # when no step is given, should have used 100
          self.assertTrue(output.size(dim=0) == 100)
          # "Upgraded" model should match the new version output
          self.assertEqual(output, output_current)
  
imports: from itertools import product
  import io
  import os
  import sys
  import hypothesis.strategies
  from hypothesis import example, settings, given
  from typing import Union
  import torch
  from torch.testing._internal.jit_utils import JitTestCase
  from torch.jit.mobile import _load_for_lite_interpreter
label_desc: Use image node_id 14 for calling the TestSaveLoadForOpVersion obj's underlying member method code with example usage: obj.test_versioned_linspace_out() and returns: torch