MCPcopy Create free account
hub / github.com/pytorch/pytorch / _RectifyName

Function _RectifyName

caffe2/python/rnn_cell.py:29–36  ·  view source on GitHub ↗
(blob_reference_or_name)

Source from the content-addressed store, hash-verified

27
28
29def _RectifyName(blob_reference_or_name):
30 if blob_reference_or_name is None:
31 return None
32 if isinstance(blob_reference_or_name, str):
33 return core.ScopedBlobReference(blob_reference_or_name)
34 if not isinstance(blob_reference_or_name, core.BlobReference):
35 raise Exception("Unknown blob reference type")
36 return blob_reference_or_name
37
38
39def _RectifyNames(blob_references_or_names):

Callers 2

_RectifyNamesFunction · 0.85
prepare_inputMethod · 0.85

Calls 2

isinstanceFunction · 0.85
ExceptionClass · 0.85

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…