code: def _check_operations_to_choose_from(
      data,
      data_type: DataTypesEnum,
      operations_to_choose_from: Set[str],
  ):
      """Since it is sometimes impossible to form a valid pipeline without some operations,
      they are added to the set of operations for current task and data.
      """
      if isinstance(data, MultiModalData):
          if (
              data_type is DataTypesEnum.image
              and "data_source_img" not in operations_to_choose_from
          ):
              operations_to_choose_from.add("data_source_img")
          if (
              data_type is DataTypesEnum.text
              and "data_source_text" not in operations_to_choose_from
          ):
              operations_to_choose_from.add("data_source_text")
          if (
              data_type is DataTypesEnum.table
              and "data_source_table" not in operations_to_choose_from
          ):
              operations_to_choose_from.add("data_source_table")
      if (
          data_type is DataTypesEnum.image
          and "cnn" not in operations_to_choose_from
      ):
          operations_to_choose_from.add("cnn")
  
imports: from abc import abstractmethod
  from typing import List, Union, Optional, Set, Tuple
  from golem.core.log import default_log
  from fedot.api.api_utils.assumptions.operations_filter import OperationsFilter, WhitelistOperationsFilter
  from fedot.api.api_utils.assumptions.preprocessing_builder import PreprocessingBuilder
  from fedot.api.api_utils.assumptions.task_assumptions import TaskAssumptions
  from fedot.core.data.data import InputData
  from fedot.core.data.multi_modal import MultiModalData
  from fedot.core.pipelines.node import PipelineNode
  from fedot.core.pipelines.pipeline import Pipeline
  from fedot.core.pipelines.pipeline_builder import PipelineBuilder
  from fedot.core.repository.dataset_types import DataTypesEnum
  from fedot.core.repository.operation_types_repository import OperationTypesRepository
  from fedot.utilities.custom_errors import AbstractMethodNotImplementError
label_desc: Use image node_id 1 for calling a global function with example usage: _check_operations_to_choose_from(data, data_type, operations_to_choose_from) without return types