code: def test_cell(
      space_format: Type[ExecutableModelSpace], skip_if_graph
  ):
      net = CellSimple()
      assert net.cell.label == "model/1"
      assert net.cell.ops[0][0].label == "model/1/op_2_0"
      model = space_format.from_model(net)
      for _ in range(10):
          selected_model = model.random().executable_model()
          assert selected_model(
              torch.randn(1, 16), torch.randn(1, 16)
          ).size() == torch.Size([1, 64])
  
      model = space_format.from_model(CellDefaultArgs())
      for _ in range(10):
          selected_model = model.random().executable_model()
          assert selected_model(
              torch.randn(1, 16)
          ).size() == torch.Size([1, 64])
  
file_path: nni/test/ut/nas/nn/test_cell.py
imports: from typing import Type
  import pytest
  import torch
  from nni.nas.space import ExecutableModelSpace, GraphModelSpace
  from .models import CellSimple, CellDefaultArgs, CellCustomProcessor, CellLooseEnd, CellOpFactory
  from .test_choice import space_format
label_desc: Use image node_id 2 for calling a global function with example usage: test_cell(space_format, skip_if_graph) without return types