Update README.md
Browse files
README.md
CHANGED
@@ -115,4 +115,10 @@ mlo_images = [crop_mammo(_, crop_model, device), for _ in mlo_images]
|
|
115 |
input_dict = [{"cc": cc_img, "mlo": mlo_img} for cc_img, mlo_img in zip(cc_images, mlo_images)]
|
116 |
with torch.inference_mode():
|
117 |
output = model(input_dict, device=device)
|
|
|
|
|
|
|
|
|
|
|
|
|
118 |
```
|
|
|
115 |
input_dict = [{"cc": cc_img, "mlo": mlo_img} for cc_img, mlo_img in zip(cc_images, mlo_images)]
|
116 |
with torch.inference_mode():
|
117 |
output = model(input_dict, device=device)
|
118 |
+
```
|
119 |
+
|
120 |
+
Note that if you are converting images from DICOM to 8-bit PNG/JPEG, it is important to apply the lookup table to the pixel values, which can be done using `pydicom.pixels.apply_voi_lut`.
|
121 |
+
If you have `pydicom` installed, you can also load a DICOM image directly, which handles the proper 8-bit conversion for you:
|
122 |
+
```
|
123 |
+
img = model.load_image_from_dicom(path_to_dicom)
|
124 |
```
|