code: def async_event_loop():
      model = nn.Sequential(
          nn.Linear(10, 10), nn.ReLU(), nn.Linear(10, 10), nn.ReLU()
      )
      pipe = AsyncPipe(
          model, [1, 1, 1, 1], worker_map=get_worker_map(), chunks=10
      )
  
      inputs = torch.rand(100, 10)
  
      output = pipe(inputs)
      if pipe.final_stage:
          loss = output.mean()
          loss.backward()
  
imports: from collections import OrderedDict
  from copy import deepcopy
  import os
  import time
  import pytest
  import torch
  from torch import nn
  from fairscale.fair_dev.testing.testing import get_worker_map, torch_spawn
  from fairscale.internal import torch_version
  from fairscale.nn.model_parallel.initialize import get_pipeline_parallel_group
  from fairscale.nn.pipe import AsyncPipe
  from fairscale.nn.pipe.types import LazyModule
label_desc: Use image node_id 38 for calling a global function with example usage: async_event_loop() without return types