Astridkraft commited on
Commit
8230f4e
·
verified ·
1 Parent(s): c2c6238

Update controlnet_module.py

Browse files
Files changed (1) hide show
  1. controlnet_module.py +2 -2
controlnet_module.py CHANGED
@@ -1182,7 +1182,7 @@ class ControlNetProcessor:
1182
 
1183
  # LEICHTER DILATE FÜR MEHR ABDECKUNG (wichtig für Gesicht!)
1184
  print(" 🔲 Leichter Dilate für natürliche Abdeckung")
1185
- kernel_dilate = np.ones((15, 15), np.uint8) # Größerer Kernel für Gesicht
1186
  mask_array = cv2.dilate(mask_array, kernel_dilate, iterations=1)
1187
 
1188
 
@@ -1223,7 +1223,7 @@ class ControlNetProcessor:
1223
  if coverage_ratio < 0.9:
1224
  print(f" ⚠️ Maske zu dünn für Gesicht (<90%)")
1225
  print(f" 📈 Zusätzlicher Dilate...")
1226
- kernel_extra = np.ones((9, 9), np.uint8)
1227
  mask_array = cv2.dilate(mask_array, kernel_extra, iterations=1)
1228
 
1229
  # Nochmal weichzeichnen
 
1182
 
1183
  # LEICHTER DILATE FÜR MEHR ABDECKUNG (wichtig für Gesicht!)
1184
  print(" 🔲 Leichter Dilate für natürliche Abdeckung")
1185
+ kernel_dilate = np.ones((5, 5), np.uint8)
1186
  mask_array = cv2.dilate(mask_array, kernel_dilate, iterations=1)
1187
 
1188
 
 
1223
  if coverage_ratio < 0.9:
1224
  print(f" ⚠️ Maske zu dünn für Gesicht (<90%)")
1225
  print(f" 📈 Zusätzlicher Dilate...")
1226
+ kernel_extra = np.ones((3, 3), np.uint8)
1227
  mask_array = cv2.dilate(mask_array, kernel_extra, iterations=1)
1228
 
1229
  # Nochmal weichzeichnen