class_docstr: Data class for input data for the nodes
      
class_docstr_tok: ["Data","class","for","input","data","for","the","nodes"]
docstr: Get subset from :obj:`InputData` to extract all items with specified indices
  
  Args:
      selected_idx: ``list`` of indices for extraction
  
  Returns:
      :obj:`InputData`
code: def subset_indices(self, selected_idx: List):
      """Get subset from :obj:`InputData` to extract all items with specified indices
  
      Args:
          selected_idx: ``list`` of indices for extraction
  
      Returns:
          :obj:`InputData`
      """
  
      idx_list = [str(i) for i in self.idx]
  
      # extractions of row number for each existing index from selected_idx
      row_nums = [
          idx_list.index(str(selected_ind))
          for selected_ind in selected_idx
          if str(selected_ind) in idx_list
      ]
      new_features = None
  
      if self.features is not None:
          new_features = self.features[row_nums]
      return InputData(
          idx=np.asarray(self.idx)[row_nums],
          features=new_features,
          target=self.target[row_nums],
          task=self.task,
          data_type=self.data_type,
      )
  
imports: from __future__ import annotations
  import glob
  import os
  from copy import copy, deepcopy
  from dataclasses import dataclass, field
  from typing import Any, Iterable, List, Optional, Tuple, Union
  import numpy
  import pandas
  from golem.core.log import default_log
  from golem.utilities.requirements_notificator import warn_requirement
  from fedot.core.data.array_utilities import atleast_2d
  from fedot.core.data.load_data import JSONBatchLoader, TextBatchLoader
  from fedot.core.data.supplementary_data import SupplementaryData
  from fedot.core.repository.dataset_types import DataTypesEnum
  from fedot.core.repository.tasks import Task, TaskTypesEnum
label_desc: Use image node_id 5 for calling the InputData obj's underlying member method code with example usage: obj.subset_indices(selected_idx) and returns: InputData