code: def register_flow(name, optimizers, requires=None, backend=None):
      """Create a flow and add it to the registry.
  
      Args:
          name (str): _description_
          optimizers (list): List of optimizers.
          requires (list, optional): List (str) of flows which have to be applied before this flow. Defaults to None.
          backend (str, optional): Backend to which the flow will belong. If not None, the name of the backend will be
              appended to the name of the registered flow. Defaults to None.
  
      Raises:
          Exception: If the flow has already been registered.
  
      Returns:
          str: The name of the registered flow.
      """
      name = _get_backend_name_prefix(name, backend)
  
      if name in flow_map:
          raise Exception(f"Flow {name} already registered")
  
      if callable(optimizers):
          flow = DynamicFlow(
              name, optimizer_func=optimizers, requires=requires
          )
      else:
          flow = Flow(name, optimizers=optimizers, requires=requires)
  
      flow_map[name] = flow
  
      return name
  
file_path: hls4ml/hls4ml/model/flow/flow.py
label_desc: Use image node_id 2 for calling a global function with example usage: register_flow(name, optimizers, requires, backend) and returns: name