MCPcopy Index your code
hub / github.com/huggingface/diffusers / find_backend

Function find_backend

utils/check_dummies.py:58–64  ·  view source on GitHub ↗

Find one (or multiple) backend in a code line of the init.

(line)

Source from the content-addressed store, hash-verified

56
57
58def find_backend(line):
59 """Find one (or multiple) backend in a code line of the init."""
60 backends = _re_backend.findall(line)
61 if len(backends) == 0:
62 return None
63
64 return "_and_".join(backends)
65
66
67def read_init():

Callers 2

test_find_backendMethod · 0.90
read_initFunction · 0.70

Calls

no outgoing calls

Tested by 1

test_find_backendMethod · 0.72

Used in the wild real call sites across dependent graphs

searching dependent graphs…