code: def is_leaf(inner_tree, index):
      # Check whether node is leaf node
      return (
          inner_tree.children_left[index] == TREE_LEAF
          and inner_tree.children_right[index] == TREE_LEAF
      )
  
imports: import os
  from copy import deepcopy
  from inspect import signature
  from typing import Optional
  from matplotlib import pyplot
  from sklearn import tree
  from sklearn.tree._tree import TREE_LEAF
  from fedot.core.composer.metrics import Metric
  from fedot.core.composer.metrics import R2, F1
  from fedot.core.data.data import InputData
  from fedot.core.pipelines.node import PipelineNode
  from fedot.core.pipelines.pipeline import Pipeline
  from fedot.core.repository.tasks import TaskTypesEnum
  from fedot.explainability.explainer_template import Explainer
label_desc: Use image node_id 3 for calling a global function with example usage: is_leaf(inner_tree, index) and returns: unknown