Spaces:
Running on Zero
Running on Zero
Update faceless_processing.py
Browse files571 unmodified lines572573574575576577578579580581582583584571 unmodified linesoval_thickness = getattr(cfg, 'face_oval_thickness', 2)oval_skip_top = getattr(cfg, 'face_oval_skip_top_ratio', 0.18)drawn_centers_px: list = []def is_duplicate_px(cx, cy):min_dist = min(w, h) * 0.06for (pcx, pcy) in drawn_centers_px:dist = np.hypot(cx - pcx, cy - pcy)if dist < min_dist:return True, distreturn False, 0.0def draw_eyebrow_landmarks(face_lms, origin_x, origin_y, scale_x, scale_y):for indices in [LEFT_EYEBROW, RIGHT_EYEBROW]:571 unmodified lines572573574575576577578579580581582583584571 unmodified linesoval_thickness = getattr(cfg, 'face_oval_thickness', 2)oval_skip_top = getattr(cfg, 'face_oval_skip_top_ratio', 0.18)drawn_centers_px: list = []def is_duplicate_px(cx_px: float, cy_px: float) -> bool:min_dist = min(w, h) * 0.06for (pcx, pcy) in drawn_centers_px:if np.hypot(cx_px - pcx, cy_px - pcy) < min_dist:return Truereturn Falsedef draw_eyebrow_landmarks(face_lms, origin_x, origin_y, scale_x, scale_y):for indices in [LEFT_EYEBROW, RIGHT_EYEBROW]:
faceless_processing.py+5-5