MCPcopy Create free account
hub / github.com/thygate/stable-diffusion-webui-depthmap-script / require_depth_edge

Function require_depth_edge

inpaint/utils.py:1057–1062  ·  view source on GitHub ↗
(context_edge, mask)

Source from the content-addressed store, hash-verified

1055 return other_edges, other_edges_info
1056
1057def require_depth_edge(context_edge, mask):
1058 dilate_mask = cv2.dilate(mask, np.array([[1,1,1],[1,1,1],[1,1,1]]).astype(np.uint8), iterations=1)
1059 if (dilate_mask * context_edge).max() == 0:
1060 return False
1061 else:
1062 return True
1063
1064def refine_color_around_edge(mesh, info_on_pix, edge_ccs, config, spdb=False):
1065 H, W = mesh.graph['H'], mesh.graph['W']

Callers 2

edge_inpaintingFunction · 0.90
DL_inpaint_edgeFunction · 0.90

Calls

no outgoing calls

Tested by

no test coverage detected