code: def instantiate_from_dict(self, values):
          
  
          name = values['ENGINE']
          options = values.get('OPTIONS', {})
  
          # Parse the name
          parts = name.split('.')
          module_name = '.'.join(parts[:-1])
          class_name = parts[-1]
  
          # Get the class
          try:
              module = import_module(module_name)
              cls = getattr(module, class_name)
          except (ValueError, AttributeError, TypeError, ImportError):
              raise ValueError('Cannot find class %s' % name)
  
          options = self.instantiate_objects(options)
  
          return cls(**options)
docs: Constructs an object given a dictionary containing an "ENGINE" key
          which contains the full module path to the class, and an "OPTIONS"
          key which contains a dictionary that will be passed in to the
          constructor as keyword args.