code: def test_cell_loose_end(
      space_format: Type[ExecutableModelSpace], skip_if_graph
  ):
      model = space_format.from_model(CellLooseEnd())
      any_not_all = False
      for _ in range(10):
          selected_model = model.random().executable_model()
          indices = selected_model.cell.output_node_indices
          assert all(i >= 2 for i in indices)
          assert selected_model(
              torch.randn(1, 16), torch.randn(1, 16)
          ).size() == torch.Size([1, 16 * len(indices)])
          if len(indices) < 4:
              any_not_all = True
      assert any_not_all
  
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 4 for calling a global function with example usage: test_cell_loose_end(space_format, skip_if_graph) without return types