MCPcopy Create free account
hub / github.com/imrahulr/hat / replicate_input

Function replicate_input

core/attacks/utils.py:13–17  ·  view source on GitHub ↗

Clone the input tensor x.

(x)

Source from the content-addressed store, hash-verified

11
12
13def replicate_input(x):
14 """
15 Clone the input tensor x.
16 """
17 return x.detach().clone()
18
19
20def replicate_input_withgrad(x):

Callers 2

line_searchFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected

Used in the wild real call sites across dependent graphs

searching dependent graphs…