class_docstr: Implements global Registry.
  
  Authors: Joan Puigcerver (jpuigcerver@), Alexander Kolesnikov (akolesnikov@)
class_docstr_tok: ["Implements","global","Registry",".","Authors",":","Joan","Puigcerver","(","jpuigcerver","@",")",",","Alexander","Kolesnikov","(","akolesnikov","@",")"]
docstr: Lookup a name in the registry.
docstr_tok: ["Lookup","a","name","in","the","registry","."]
code: def lookup(lookup_string, kwargs_extra=None):
      """Lookup a name in the registry."""
  
      name, args, kwargs = parse_name(lookup_string)
      if kwargs_extra:
          kwargs.update(kwargs_extra)
      item, item_type = Registry.global_registry()[name]
      if item_type == "function":
          return functools.partial(item, *args, **kwargs)
      elif item_type == "object":
          return item(*args, **kwargs)
      elif item_type == "factory":
          return partialfactory(item, lookup_string, *args, **kwargs)
      elif item_type == "class":
          return partialclass(item, *args, **kwargs)
  
file_path: scenic/scenic/dataset_lib/big_transfer/registry.py
imports: import ast
  import functools
  import logging
label_desc: Use image node_id 3 for calling the Registry obj's underlying member method code with example usage: obj.lookup(lookup_string, kwargs_extra) and returns: functools, item, partialfactory, partialclass