code: def test_empty_module():
      # Empty sequential module is not illegal.
      model = nn.Sequential()
      model = Pipe(model, [])
  
      assert model(torch.tensor(42)) == torch.tensor(42)
      assert model((torch.tensor(42),)) == (torch.tensor(42),)
  
      # But only tensor or tensors is legal in Pipe.
      with pytest.raises(TypeError):
          model(42)
  
imports: from collections import OrderedDict
  from copy import deepcopy
  import time
  import pytest
  import torch
  from torch import nn
  from fairscale.nn.pipe import Pipe
label_desc: Use image node_id 28 for calling a global function with example usage: test_empty_module() without return types