code: def test_fdict(
      self, image_dtype, metadata_dtype, output_metadata_dtype
  ):
      self.assertFeature(
          feature=features_lib.FeaturesDict(
              {
                  "input": AnInputConnector(),
                  "output": AnOutputConnector(),
                  "img": {
                      "size": {
                          "height": image_dtype,
                          "width": image_dtype,
                      },
                      "metadata/path": metadata_dtype,
                  },
              }
          ),
          serialized_info={
              "input": {
                  "a": features_lib.TensorInfo(
                      shape=(), dtype=np.int64
                  ),
                  "b": features_lib.TensorInfo(
                      shape=(), dtype=np.int64
                  ),
              },
              "output": features_lib.TensorInfo(
                  shape=(), dtype=np.float32
              ),
              "img": {
                  "size": {
                      "height": features_lib.TensorInfo(
                          shape=(), dtype=np.int64
                      ),
                      "width": features_lib.TensorInfo(
                          shape=(), dtype=np.int64
                      ),
                  },
                  "metadata/path": features_lib.TensorInfo(
                      shape=(), dtype=output_metadata_dtype
                  ),
              },
          },
          dtype={
              "input": np.int64,
              "output": np.float32,
              "img": {
                  "size": {
                      "height": np.int64,
                      "width": np.int64,
                  },
                  "metadata/path": output_metadata_dtype,
              },
          },
          shape={
              "input": (),
              "output": (),
              "img": {
                  "size": {
                      "height": (),
                      "width": (),
                  },
                  "metadata/path": (),
              },
          },
          tests=[
              # Np array
              testing.FeatureExpectationItem(
                  value={
                      "input": 1,
                      "output": -1,
                      "img": {
                          "size": {
                              "height": 256,
                              "width": 128,
                          },
                          "metadata/path": "path/to/xyz.jpg",
                      },
                  },
                  expected_serialized={
                      "input": {
                          "a": 2,  # 1 + 1
                          "b": 10,  # 1 * 10
                      },
                      "output": -10.0,  # -1 * 10.0
                      "img": {
                          "size": {
                              "height": 256,
                              "width": 128,
                          },
                          "metadata/path": "path/to/xyz.jpg",
                      },
                  },
                  expected={
                      # a = 1 + 1, b = 1 * 10 => output = a + b = 2 + 10 = 12
                      "input": 12,  # 2 + 10
                      "output": -1.0,
                      "img": {
                          "size": {
                              "height": 256,
                              "width": 128,
                          },
                          "metadata/path": tf.compat.as_bytes(
                              "path/to/xyz.jpg"
                          ),
                      },
                  },
              ),
          ],
      )
  
imports: import pathlib
  import sys
  import textwrap
  from unittest import mock
  from absl import logging
  from absl.testing import parameterized
  import numpy
  import tensorflow
  from tensorflow_datasets import testing
  from tensorflow_datasets.core import features
label_desc: Use image node_id 3 for calling the FeatureDictTest obj's underlying member method code with example usage: obj.test_fdict(image_dtype, metadata_dtype, output_metadata_dtype) without return types