class_docstr: Information about a metric.
  
  `MetricInfo` documents a metric, including its name, version, and features.
  See the constructor arguments and properties for a full list.
  
  Note: Not all fields are known on construction and may be updated later.
class_docstr_tok: ["Information","about","a","metric",".","`","MetricInfo","`","documents","a","metric",",","including","its","name",",","version",",","and","features",".","See","the","constructor","arguments","and","properties","for","a","full","list",".","Note",":","Not","all","fields","are","known","on","construction","and","may","be","updated","later","."]
code: def from_dict(cls, metric_info_dict: dict) -> "MetricInfo":
      field_names = {f.name for f in dataclasses.fields(cls)}
      return cls(
          **{
              k: v
              for k, v in metric_info_dict.items()
              if k in field_names
          }
      )
  
imports: import copy
  import dataclasses
  import json
  import os
  import posixpath
  import warnings
  from dataclasses import dataclass
  from pathlib import Path
  from typing import ClassVar, Dict, List, Optional, Union
  import fsspec
  from huggingface_hub import DatasetCard, DatasetCardData
  from .None import config
  from .features import Features, Value
  from .splits import SplitDict
  from .tasks import TaskTemplate, task_template_from_dict
  from .utils import Version
  from .utils.logging import get_logger
  from .utils.py_utils import asdict, unique_values
label_desc: Use image node_id 4 for calling the MetricInfo obj's underlying member method code with example usage: obj.from_dict(cls, metric_info_dict) and returns: cls