class_docstr: A mixin class containing methods related to a drift detector's configuration dictionary.
class_docstr_tok: ["A","mixin","class","containing","methods","related","to","a","drift","detector","'s","configuration","dictionary","."]
docstr: Instantiate a drift detector from a fully resolved (and validated) config dictionary.
  
  Parameters
  ----------
  config
      A config dictionary matching the schema's in :class:`~alibi_detect.saving.schemas`.
docstr_tok: ["Instantiate","a","drift","detector","from","a","fully","resolved","(","and","validated",")","config","dictionary",".","Parameters","--","--","--","--","--","config","A","config","dictionary","matching","the","schema","'s","in",":","class",":","`","~alibi_detect.saving.schemas","`","."]
code: def from_config(cls, config: dict):
      """
      Instantiate a drift detector from a fully resolved (and validated) config dictionary.
  
      Parameters
      ----------
      config
          A config dictionary matching the schema's in :class:`~alibi_detect.saving.schemas`.
      """
      # Check for existing version_warning. meta is pop'd as don't want to pass as arg/kwarg
      meta = config.pop("meta", None)
      meta = (
          {} if meta is None else meta
      )  # Needed because pydantic sets meta=None if it is missing from the config
      version_warning = meta.pop("version_warning", False)
      # Init detector
      detector = cls(**config)
      # Add version_warning
      detector.meta["version_warning"] = version_warning  # type: ignore[attr-defined]
      detector.config["meta"]["version_warning"] = version_warning
      return detector
  
imports: from abc import ABC, abstractmethod
  import os
  import copy
  import json
  import numpy
  from typing import Dict, Any, Optional, Union
  from typing_extensions import Protocol, runtime_checkable
  from alibi_detect.version import __version__
label_desc: Use image node_id 2 for calling the DriftConfigMixin obj's underlying member method code with example usage: obj.from_config(cls, config) and returns: detector