diff --git a/rapids/models.py b/rapids/models.py index c1f63bba..96e5c2f0 100644 --- a/rapids/models.py +++ b/rapids/models.py @@ -457,7 +457,7 @@ class RapidImage(models.Model): if self.image: # Try and read the file as a dicom try: - hash = ",".join(pydicom.dcmread(self.image).pixel_array.to()) + hash = ",".join(pydicom.dcmread(self.image.path).pixel_array.to()) self.is_dicom = True except pydicom.errors.InvalidDicomError: with self.image.open("r") as f: