Browse Source

Updated preprocess.py logs

Frederik Filip Stæger 4 years ago
parent
commit
b9f0b7b428
1 changed files with 2 additions and 1 deletions
  1. 2 1
      automatic_segmentation_program/preprocess.py

+ 2 - 1
automatic_segmentation_program/preprocess.py

@@ -18,6 +18,7 @@ def get_out_paths(out_dir, stem):
 
 
 def bias_field_correction(image, output, dim=2):
+    print('Running N4BiasFieldCorrection on input slice.')
     N4BiasFieldCorrection(
         input_image=image,
         output_image=output,
@@ -30,7 +31,7 @@ def image_data_to_nii(pixdim, image_data, shrink, out_dir, file_path, save_unsca
     scale = 1/shrink
     new_dim = (round(image_dim[1] * scale), round(image_dim[0] * scale))
     new_arr = np.ndarray(new_dim + (image_data.shape[2],))
-    print(f'Pixel dimensions: {pixdim} um')
+    print(f'Pixel dimensions: {pixdim} mm')
 
     for i in range(0,image_data.shape[2]):
         cur_channel = image_data[:, :, i]