class_docstr: Allow to decode a subset of features.
  
  See guide:
  https://www.tensorflow.org/datasets/decode#only_decode_a_sub-set_of_the_features
docstr: Returns the `tfds.features.FeaturesDict`.
  
  Extract the subset of features
  
  Args:
    features: Features on which extract the sub-set
  
  Returns:
    features_subset: A subset of the features
docstr_tok: ["Returns","the","`","tfds.features.FeaturesDict","`",".","Extract","the","subset","of","features","Args",":","features",":","Features","on","which","extract","the","sub-set","Returns",":","features_subset",":","A","subset","of","the","features"]
code: def extract_features(
      self,
      features: features_lib.FeatureConnector,
  ) -> features_lib.FeatureConnector:
      """Returns the `tfds.features.FeaturesDict`.
  
      Extract the subset of features
  
      Args:
        features: Features on which extract the sub-set
  
      Returns:
        features_subset: A subset of the features
      """
      with utils.try_reraise(
          "Provided PartialDecoding specs does not match actual features: "
      ):
          # Convert non-features into features
          expected_feature = _normalize_feature_item(
              feature=features,
              expected_feature=self._feature_specs,
          )
          # Get the intersection of `features` and `expected_feature`
          return _extract_features(
              feature=features,
              expected_feature=features_dict.to_feature(
                  expected_feature
              ),
          )
  
file_path: datasets/tensorflow_datasets/core/decode/partial_decode.py
imports: import typing
  from typing import Any, Callable, Optional, Union
  from tensorflow_datasets.core import features
  from tensorflow_datasets.core import utils
  from tensorflow_datasets.core.decode import base
  from tensorflow_datasets.core.features import features_dict
  from tensorflow_datasets.core.utils import dtype_utils
label_desc: Use image node_id 2 for calling the PartialDecoding obj's underlying member method code with example usage: obj.extract_features(features) and returns: _extract_features