FrancescoLR commited on
Commit
f5eba2f
·
1 Parent(s): 1d7bf30

Updated app.py

Browse files
Files changed (1) hide show
  1. app.py +1 -1
app.py CHANGED
@@ -44,7 +44,7 @@ def extract_middle_slice(nifti_path, output_image_path):
44
 
45
  # Calculate aspect ratio
46
  height, width = slice_data.shape
47
- aspect_ratio = width / height
48
 
49
  # Dynamically adjust figure size based on aspect ratio
50
  plt.figure(figsize=(6 * aspect_ratio, 6)) # Height fixed to 6, width scaled by aspect ratio
 
44
 
45
  # Calculate aspect ratio
46
  height, width = slice_data.shape
47
+ aspect_ratio = (width / height) * 0.5
48
 
49
  # Dynamically adjust figure size based on aspect ratio
50
  plt.figure(figsize=(6 * aspect_ratio, 6)) # Height fixed to 6, width scaled by aspect ratio