Repository: open-dicom/dicom_parser

Issue:
"ImageType" not set causes is_mosaic to crash
**Is your feature request related to a problem? Please describe.**
My dicoms don't have any "ImageType" field so I cannot use .data on them I have to work with raw

**Describe the solution you'd like**
To have a more robust check, as the only purpose is to know if it is mosaic or not, just consider that it is not if "ImageType" is not present (maybe raise a warning)

**Describe alternatives you've considered**
Changing manually the header of the dicom, can be tedious 

**Additional context**
![image](https://user-images.githubusercontent.com/35405712/138717376-1ebe70ff-1544-4843-89e9-172233abd8d2.png)


Discussion:

Patch:
diff --git a/src/dicom_parser/image.py b/src/dicom_parser/image.py
index 2866afb..b62b324 100644
--- a/src/dicom_parser/image.py
+++ b/src/dicom_parser/image.py
@@ -533,7 +533,7 @@ class Image:
         bool
             Whether the image is a mosaic encoded volume
         """
-        return "MOSAIC" in self.header.get("ImageType")
+        return "MOSAIC" in self.header.get("ImageType", "")
 
     @property
     def is_multi_frame(self) -> bool:


Test patch:
diff --git a/tests/test_image.py b/tests/test_image.py
index 738f2fc..2b4aa8d 100644
--- a/tests/test_image.py
+++ b/tests/test_image.py
@@ -20,11 +20,13 @@ from tests.fixtures import (
 class ImageTestCase(TestCase):
     @classmethod
     def setUpClass(cls):
-        cls.image = Image(TEST_IMAGE_PATH)
         cls.rsfmri_image = Image(TEST_RSFMRI_IMAGE_PATH)
         cls.siemens_dwi = Image(TEST_SIEMENS_DWI_PATH)
         cls.multi_frame = Image(TEST_MULTIFRAME)
 
+    def setUp(self):
+        self.image = Image(TEST_IMAGE_PATH)
+
     def test_initialization_with_string_path(self):
         image = Image(TEST_IMAGE_PATH)
         self.assertIsInstance(image, Image)
@@ -246,3 +248,12 @@ class ImageTestCase(TestCase):
         self.assertIsNone(self.image.multi_frame)
         self.assertIsNone(self.rsfmri_image.multi_frame)
         self.assertIsNone(self.siemens_dwi.multi_frame)
+
+    def test_data_returned_with_missing_image_type(self):
+        del self.image.header.raw["ImageType"]
+        try:
+            self.image.data
+        except Exception as e:
+            self.fail(
+                f"Exception raised retreiving data for an image with a missing ImageType header field: {e}"  # noqa: E501
+            )