.
This commit is contained in:
+2
-2
@@ -182,13 +182,13 @@ def get_image_dicom_hash(img, dataset=None, hash_type="md5", direct_pixel_data=T
|
||||
hash = hasher.hexdigest()
|
||||
return hash
|
||||
|
||||
def get_image_hash(img, hash_type="blake3", direct_pixel_data=True) -> (str, bool):
|
||||
def get_image_hash(img, dataset=None, hash_type="blake3", direct_pixel_data=True) -> (str, bool):
|
||||
is_dicom = False
|
||||
# Try and read the file as a dicom
|
||||
hash = "1234"
|
||||
try:
|
||||
# and generate a hash from the pixel data
|
||||
hash = get_image_dicom_hash(img, hash_type=hash_type, direct_pixel_data=direct_pixel_data)
|
||||
hash = get_image_dicom_hash(img, dataset=dataset, hash_type=hash_type, direct_pixel_data=direct_pixel_data)
|
||||
is_dicom = True
|
||||
# ----
|
||||
|
||||
|
||||
Reference in New Issue
Block a user