davidgdd1 / Print-Camera-resilient-watermarking

0 stars 0 forks source link

关于utils #2

Open YX-wal opened 1 month ago

YX-wal commented 1 month ago

Hello dear author, can the “utils” file mentioned in the code be given, it looks like a custom toolkit file. eg. M = utils.get_rand_transform_matrix(width, np.floor(width * rnd_tran), args.batch_size) rnd_brightness = utils.get_rnd_brightness_tf(rnd_bri, rnd_hue, args.batch_size) f = utils.random_blur_kernel(probs=[.25,.25], N_blur=15,sigrange_gauss=[1.,3.], sigrange_line=[.25,1.], wmin_line=7) encoded_image = utils.jpeg_compress_decompress(encoded_image, rounding=utils.round_only_at_0, factor=jpeg_factor, downsample_c=True)

YX-wal commented 1 month ago

解决了,使用的StegaStamp的原始utils.py文件