class_docstr: Deprecated import with redirection and warning.
  
  Examples
  --------
  Suppose you previously had in some module::
  
      from foo import spam
  
  If this has to be deprecated, do::
  
      spam = DeprecatedImport("foo.spam", "baz")
  
  to redirect users to use "baz" module instead.
class_docstr_tok: ["Deprecated","import","with","redirection","and","warning",".","Examples","--","--","--","--","Suppose","you","previously","had","in","some","module",":",":","from","foo","import","spam","If","this","has","to","be","deprecated",",","do",":",":","spam","=","DeprecatedImport","(","``","foo.spam","''",",","``","baz","''",")","to","redirect","users","to","use","``","baz","''","module","instead","."]
code: def __getattr__(self, name):
      warnings.warn(
          "Module %s is deprecated, use %s instead"
          % (self._old_name, self._new_name),
          DeprecationWarning,
      )
      return getattr(self._mod, name)
  
imports: from contextlib import contextmanager
  import functools
  import operator
  import sys
  import warnings
  import numbers
  from collections import namedtuple
  import inspect
  import math
  from typing import Optional, Union, TYPE_CHECKING, TypeVar
  import numpy
label_desc: Use image node_id 3 for calling the DeprecatedImport obj's underlying member method code with example usage: obj.__getattr__(name) and returns: getattr