code: def _fh_equals(x, y, return_msg=False):
      """Test two forecasting horizons for equality.
  
      Correct if both x and y are ForecastingHorizon
  
      Parameters
      ----------
      x: ForecastingHorizon
      y: ForecastingHorizon
      return_msg : bool, optional, default=False
          whether to return informative message about what is not equal
  
      Returns
      -------
      is_equal: bool - True if x and y are equal in value
          x and y do not need to be equal in reference
      msg : str, only returned if return_msg = True
          indication of what is the reason for not being equal
              concatenation of the following strings:
              .is_relative - x is absolute and y is relative, or vice versa
              .values - values of x and y are not equal
      """
  
      def ret(is_equal, msg):
          if return_msg:
              if is_equal:
                  msg = ""
              return is_equal, msg
          else:
              return is_equal
  
      if x.is_relative != y.is_relative:
          return ret(False, ".is_relative")
  
      # recurse through values of x, y
      is_equal, msg = deep_equals(x._values, y._values, return_msg=True)
      if not is_equal:
          return ret(False, ".values" + msg)
  
      return ret(True, "")
  
imports: from inspect import isclass
  import numpy
  import pandas
label_desc: Use image node_id 5 for calling a global function with example usage: _fh_equals(x, y, return_msg) and returns: ret, ret, ret, is_equal,  msg, is_equal