Commit 596da333 authored by Bryce Hepner's avatar Bryce Hepner

deleted many files and testing code

parent fe1a66d3
......@@ -595,7 +595,7 @@
],
"metadata": {
"kernelspec": {
"display_name": "Python 3 (ipykernel)",
"display_name": "Python 3.8.10 64-bit",
"language": "python",
"name": "python3"
},
......@@ -610,6 +610,11 @@
"nbconvert_exporter": "python",
"pygments_lexer": "ipython3",
"version": "3.8.10"
},
"vscode": {
"interpreter": {
"hash": "916dbcbb3f70747c44a77c7bcd40155683ae19c65e1c03b4aa3499c5328201f1"
}
}
},
"nbformat": 4,
......
......@@ -172,10 +172,12 @@ def create_testable_images(images, selected_channel, quantity_of_images):
# average_image = Image.fromarray(average_image)
sftp_client.close()
def save_new_gauss():
"""\
creates gaussian kernel with side length `l` and a sigma of `sig`
"""
# x,y = np.mgrid[-1:1:.003125, -1:1:.003125]
x,y = np.mgrid[-1:1:.44, -1:1:.44]
print(x.shape)
......
This diff is collapsed.
......@@ -515,7 +515,7 @@ def text_to_tiff(filename, list_dic, bins):
if __name__ == "__main__":
scenes = file_extractor("averaged_images(11)")
scenes = file_extractor("images")
images = image_extractor(scenes)
newnamesforlater = []
list_dic, bins = make_dictionary(images, 4, False)
......@@ -534,16 +534,13 @@ if __name__ == "__main__":
newname = images[i][:-5]
else:
newname = images[i][:-4]
# print(newname)
newnamesforlater.append(newname + "_Compressed.txt")
with open(newname + "_Compressed.txt", 'wb') as f:
f.write(inletters)
file_sizes_new.append((os.path.getsize(newname + "_Compressed.txt")))
file_sizes_old.append((os.path.getsize(images[i])))
# sleep(5)
# if i % 50 == 0:
# print(i)
# sleep(20)
print(file_sizes_new)
print(file_sizes_old)
print(np.sum(file_sizes_new)/np.sum(file_sizes_old))
......@@ -551,7 +548,7 @@ if __name__ == "__main__":
print(np.sum(file_sizes_new)/np.sum(file_sizes_old))
# list_dic = np.load("first_dic.npy", allow_pickle="TRUE")
bins = [21,32,48]
# os.system("ls")
# for i,item in enumerate(newnamesforlater):
# print(item)
# image, new_error, diff = huffman(images[i], 4, False)
......
This diff is collapsed.
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment