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

Function _compute_group_hash

src/diffusers/hooks/group_offloading.py:1028–1031  ·  view source on GitHub ↗
(group_id)

Source from the content-addressed store, hash-verified

1026
1027
1028def _compute_group_hash(group_id):
1029 hashed_id = hashlib.sha256(group_id.encode("utf-8")).hexdigest()
1030 # first 16 characters for a reasonably short but unique name
1031 return hashed_id[:16]
1032
1033
1034def _maybe_remove_and_reapply_group_offloading(module: torch.nn.Module) -> None:

Callers 3

get_hashed_filenameFunction · 0.90
get_hashed_filenameFunction · 0.90
__init__Method · 0.85

Calls 1

encodeMethod · 0.45

Tested by 2

get_hashed_filenameFunction · 0.72
get_hashed_filenameFunction · 0.72

Used in the wild real call sites across dependent graphs

searching dependent graphs…