mirror of
https://github.com/autistic-symposium/sec-pentesting-toolkit.git
synced 2025-05-04 07:45:04 -04:00
some small fixes
This commit is contained in:
parent
4f8d5148af
commit
16757b10ac
412 changed files with 139509 additions and 0 deletions
30
Steganography/compare_two_images.py
Executable file
30
Steganography/compare_two_images.py
Executable file
|
@ -0,0 +1,30 @@
|
|||
#!/usr/bin/env python
|
||||
|
||||
__author__='bt3gl'
|
||||
'''
|
||||
Compare two aligned images of the same size.
|
||||
|
||||
Usage: python compare.py first-image second-image
|
||||
'''
|
||||
|
||||
import sys
|
||||
|
||||
from scipy.misc import imread, imsave
|
||||
|
||||
|
||||
def compare_images(img1, img2):
|
||||
diff = img1 + img2
|
||||
imsave('sum.png', diff)
|
||||
diff = img1 - img2
|
||||
imsave('diff.png', diff)
|
||||
|
||||
|
||||
|
||||
def main():
|
||||
file1, file2 = sys.argv[1:1+2]
|
||||
img1 = imread(file1).astype(float)
|
||||
img2 = imread(file2).astype(float)
|
||||
compare_images(img1, img2)
|
||||
|
||||
if __name__ == "__main__":
|
||||
main()
|
Loading…
Add table
Add a link
Reference in a new issue