docstr: Check whether scenario is applicable to obj.
  
  Parameters
  ----------
  obj : class or object to check against scenario
  
  Returns
  -------
  applicable: bool
      True if self is applicable to obj, False if not
docstr_tok: ["Check","whether","scenario","is","applicable","to","obj",".","Parameters","--","--","--","--","--","obj",":","class","or","object","to","check","against","scenario","Returns","--","--","--","-","applicable",":","bool","True","if","self","is","applicable","to","obj",",","False","if","not"]
code: def is_applicable(self, obj):
      """Check whether scenario is applicable to obj.
  
      Parameters
      ----------
      obj : class or object to check against scenario
  
      Returns
      -------
      applicable: bool
          True if self is applicable to obj, False if not
      """
  
      def get_tag(obj, tag_name):
          if isclass(obj):
              return obj.get_class_tag(tag_name)
          else:
              return obj.get_tag(tag_name)
  
      # applicable only if obj inherits from BaseForecaster
      if scitype(obj) != "forecaster":
          return False
  
      # applicable only if number of variables in y complies with scitype:y
      # only rule: multivariate forecasters cannot deal with univariate data
      # univariate forecasters can deal with multivariate data by vectorization
      is_univariate = self.get_tag("univariate_y")
  
      if is_univariate and get_tag(obj, "scitype:y") == "multivariate":
          return False
  
      # applicable only if fh is not passed later than it needs to be
      fh_in_fit = self.get_tag("fh_passed_in_fit")
  
      if not fh_in_fit and get_tag(obj, "requires-fh-in-fit"):
          return False
  
      # run Panel/Hierarchical scenarios for genuinely Panel/Hierarchical forecasters
      y_scitype = self.get_tag("y_scitype", "Series", raise_error=False)
      scenario_is_hierarchical = y_scitype in ["Panel", "Hierarchical"]
  
      obj_y_inner_types = get_tag(obj, "y_inner_mtype")
      obj_scitypes = mtype_to_scitype(obj_y_inner_types)
      obj_is_hierarchical = (
          "Panel" in obj_scitypes or "Hierarchical" in obj_scitypes
      )
  
      # if scenario is hierarchical and obj is not genuinely hierarchical,
      # this would trigger generic vectorization, which is tested in test_base
      if scenario_is_hierarchical and not obj_is_hierarchical:
          return False
  
      return True
  
imports: from inspect import isclass
  import pandas
  from sktime.base import BaseObject
  from sktime.datatypes import mtype_to_scitype
  from sktime.registry import scitype
  from sktime.utils._testing.hierarchical import _make_hierarchical
  from sktime.utils._testing.panel import _make_panel_X
  from sktime.utils._testing.scenarios import TestScenario
  from sktime.utils._testing.series import _make_series
label_desc: Use image node_id 1 for calling the ForecasterTestScenario obj's underlying member method code with example usage: obj.is_applicable(obj) and returns: True, False, False, False, False, obj, obj