class_docstr: Data container to encapsulate different types of data, such as images, bounding boxes, etc.
  
  The container itself is iterable according to the format.
  Data container assumes the same coordinate system for all the items it is storing.
  For instance, the behavior shown below is not supported:
  
  .. highlight:: python
  .. code-block:: python
  
      from solt.core import DataContainer
      import numpy as np
  
      img1 = np.ones((100, 100, 3), dtype=np.int32)
      img2 = np.ones((110, 110, 3), dtype=np.int32)
      trf_img = DataContainer.from_dict({'images': (img1, img2)})
  
  Parameters
  ----------
  data : tuple
      Data items stored in a tuple
  fmt : str
      Data format. Example: 'IMMM' - image and three masks.
  transform_settings : dict or None
      Settings for each data item. At this stage, the settings include only padding and interpolation.
      The key in this dict corresponds to the index of the element in the given data tuple.
      The value is another dict, which has all the settings. Segmentation masks have nearest neighbor interpolation
      by default, this can be changed manually if needed.
      Example: ``transform_settings={0:{'interpolation':'bilinear'}, 1: {'interpolation':'bicubic'}}``
code: def __init__(self, data, fmt, transform_settings=None):
      if len(fmt) == 1 and not isinstance(data, tuple):
          if not isinstance(data, list):
              data = (data,)
          else:
              raise TypeError
  
      if not isinstance(data, tuple):
          raise TypeError
  
      if len(data) != len(fmt):
          raise ValueError
  
      if transform_settings is not None:
          if not isinstance(transform_settings, dict):
              raise TypeError
      else:
          transform_settings = {}
  
      # Element-wise settings
      # If no settings provided for certain items, they will be created
      for idx in range(len(data)):
          if idx not in transform_settings:
              transform_settings[idx] = {}
  
          if fmt[idx] == "I" or fmt[idx] == "M":
              val = ("nearest", "strict") if fmt[idx] == "M" else None
              if "interpolation" not in transform_settings[idx]:
                  transform_settings[idx][
                      "interpolation"
                  ] = validate_parameter(
                      val, ALLOWED_INTERPOLATIONS, "bilinear", str, True
                  )
              else:
                  transform_settings[idx][
                      "interpolation"
                  ] = validate_parameter(
                      (
                          transform_settings[idx]["interpolation"],
                          "strict",
                      ),
                      ALLOWED_INTERPOLATIONS,
                      "bilinear",
                      str,
                      True,
                  )
  
              if "padding" not in transform_settings[idx]:
                  transform_settings[idx][
                      "padding"
                  ] = validate_parameter(
                      None, ALLOWED_PADDINGS, "z", str, True
                  )
              else:
                  transform_settings[idx][
                      "padding"
                  ] = validate_parameter(
                      (transform_settings[idx]["padding"], "strict"),
                      ALLOWED_PADDINGS,
                      "z",
                      str,
                      True,
                  )
          else:
              if (
                  "interpolation" in transform_settings[idx]
                  or "padding" in transform_settings[idx]
              ):
                  raise TypeError
  
      if len(data) != len(transform_settings):
          raise ValueError
  
      for t in fmt:
          if t not in ALLOWED_TYPES:
              raise TypeError
  
      self.__data = data
      self.__fmt = fmt
      self.__transform_settings = transform_settings
  
      self.__imagenet_mean = torch.tensor((0.485, 0.456, 0.406)).view(
          3, 1, 1
      )
      self.__imagenet_std = torch.tensor((0.229, 0.224, 0.225)).view(
          3, 1, 1
      )
  
      self.validate()
  
imports: import numpy
  import torch
  from solt.constants import ALLOWED_INTERPOLATIONS, ALLOWED_PADDINGS, ALLOWED_TYPES
  from solt.utils import validate_parameter
label_desc: Use image node_id 1 to create a new DataContainer object from inherited base classes: object with example: obj = DataContainer(data, fmt, transform_settings)