We read every piece of feedback, and take your input very seriously.
To see all available qualifiers, see our documentation.
1 parent adadb4e commit c9a04c6Copy full SHA for c9a04c6
modules/textual_inversion/image_embedding.py
@@ -43,7 +43,7 @@ def lcg(m=2**32, a=1664525, c=1013904223, seed=0):
43
44
def xor_block(block):
45
g = lcg()
46
- randblock = np.array([next(g) for _ in range(np.product(block.shape))]).astype(np.uint8).reshape(block.shape)
+ randblock = np.array([next(g) for _ in range(np.prod(block.shape))]).astype(np.uint8).reshape(block.shape)
47
return np.bitwise_xor(block.astype(np.uint8), randblock & 0x0F)
48
49
0 commit comments