class_docstr: ``ScopeMessenger`` is the implementation of :func:`pyro.contrib.autoname.scope`
class_docstr_tok: ["``","ScopeMessenger","``","is","the","implementation","of",":","func",":","`","pyro.contrib.autoname.scope","`"]
code: def _collect_scope(prefixed_scope):
      return prefixed_scope.split("/")[-1]
  
imports: import functools
  from pyro.poutine.messenger import Messenger
  from pyro.poutine.runtime import effectful
label_desc: Use image node_id 2 for calling the ScopeMessenger obj's underlying member method code with example usage: obj._collect_scope(prefixed_scope) and returns: prefixed_scope