Skip to content

Commit d74fc56

Browse files
Merge pull request AUTOMATIC1111#15547 from AUTOMATIC1111/numpy-DeprecationWarning-product---prod
numpy DeprecationWarning product -> prod
2 parents a44ed23 + 63fd38a commit d74fc56

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

modules/textual_inversion/image_embedding.py

+1-1
Original file line numberDiff line numberDiff line change
@@ -47,7 +47,7 @@ def lcg(m=2**32, a=1664525, c=1013904223, seed=0):
4747

4848
def xor_block(block):
4949
g = lcg()
50-
randblock = np.array([next(g) for _ in range(np.product(block.shape))]).astype(np.uint8).reshape(block.shape)
50+
randblock = np.array([next(g) for _ in range(np.prod(block.shape))]).astype(np.uint8).reshape(block.shape)
5151
return np.bitwise_xor(block.astype(np.uint8), randblock & 0x0F)
5252

5353

0 commit comments

Comments
 (0)