code: def get_original_factors(factors):
      """
      For a set of factors, we want to
      get a mapping of the variables to
      the factor which first introduces the
      variable to the set.
      To do this without enforcing a special
      naming convention such as 'f_' for factors,
      or a special ordering, such as the last
      argument is always the new variable,
      we will have to discover the 'original'
      factor that introduces the variable
      iteratively.
      """
      original_factors = {}
      while len(original_factors) < len(factors):
          for factor in factors:
              args = get_args(factor)
              unaccounted_args = [
                  a for a in args if a not in original_factors
              ]
              if len(unaccounted_args) == 1:
                  original_factors[unaccounted_args[0]] = factor
      return original_factors
  
label_desc: Use image node_id 3 for calling a global function with example usage: get_original_factors(factors) and returns: original_factors