.
This commit is contained in:
+6
-1
@@ -468,8 +468,13 @@ class RapidImage(models.Model):
|
||||
#hash = hashlib.md5(pre_join.encode()).hexdigest()
|
||||
#----
|
||||
md5 = hashlib.md5()
|
||||
first = True
|
||||
for i in dataset.pixel_array.astype(str).flatten():
|
||||
md5.update(f"{i},".encode())
|
||||
if first:
|
||||
first=False
|
||||
md5.update(f"{i}".encode())
|
||||
else:
|
||||
md5.update(f",{i}".encode())
|
||||
print(0)
|
||||
|
||||
hash = md5.hexdigest()
|
||||
|
||||
Reference in New Issue
Block a user