From f017d7e212f260f6512f469d940a77e5958f5a3f Mon Sep 17 00:00:00 2001 From: zcr Date: Tue, 3 Feb 2026 16:22:47 +0800 Subject: [PATCH] =?UTF-8?q?feat:=20fix:=20=E4=BF=AE=E5=A4=8Dsketch?= =?UTF-8?q?=E7=B1=BB=E5=9E=8B=E4=B8=BAothers=E6=97=B6=20=E8=B7=B3=E8=BF=87?= =?UTF-8?q?=20=E4=B8=8A=E5=8D=B0=E8=8A=B1=20=E5=AF=BC=E8=87=B4=E7=9A=84?= =?UTF-8?q?=E5=B0=BA=E5=AF=B8=E4=B8=8E=E5=88=86=E5=89=B2=E5=B0=BA=E5=AF=B8?= =?UTF-8?q?=E4=B8=8D=E4=B8=80=E8=87=B4=E9=97=AE=E9=A2=98,=20=E4=BF=AE?= =?UTF-8?q?=E5=A4=8Dothers=E5=88=86=E5=89=B2=E5=87=BA=E5=90=8E=E7=89=87?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- app/service/design_fast/item.py | 2 ++ app/service/design_fast/pipeline/segmentation.py | 2 ++ 2 files changed, 4 insertions(+) diff --git a/app/service/design_fast/item.py b/app/service/design_fast/item.py index 5ca89ab..3bee6bb 100644 --- a/app/service/design_fast/item.py +++ b/app/service/design_fast/item.py @@ -17,6 +17,8 @@ class OthersItem(BaseItem): LoadImage(minio_client), Segmentation(minio_client), Color(minio_client), + NoSegPrintPainting(minio_client), + PrintPainting(minio_client), Scaling(), Split(minio_client) ] diff --git a/app/service/design_fast/pipeline/segmentation.py b/app/service/design_fast/pipeline/segmentation.py index ebdb6c6..9468556 100644 --- a/app/service/design_fast/pipeline/segmentation.py +++ b/app/service/design_fast/pipeline/segmentation.py @@ -51,6 +51,8 @@ class Segmentation: if not _ or result["image"].shape[:2] != seg_result.shape: # 推理获得seg 结果 seg_result = get_seg_result(result['image']) + if result['name'] == 'others': + seg_result = seg_result.clip(max=1) self.save_seg_result(seg_result, result['image_id']) result['seg_result'] = seg_result