路径调整

This commit is contained in:
Ukawka
2026-09-15 23:47:33 +08:00
parent b32fae2d48
commit 2e79bc4a12
2 changed files with 4 additions and 2 deletions
+2 -1
View File
@@ -7,6 +7,7 @@ and case-summary.json under --out-dir.
"""
import argparse, json, shutil, subprocess
from pathlib import Path
import sys
from PIL import Image
import numpy as np
@@ -18,7 +19,7 @@ def main():
ap.add_argument('--candidate', action='append', nargs=2, metavar=('NAME','PARTS_DIR'), required=True)
args = ap.parse_args()
root = Path(args.out_dir); root.mkdir(parents=True, exist_ok=True)
py = '/Users/zhaoziyu/anaconda3/bin/python'
py = sys.executable
ref = Image.open(args.reference).convert('RGBA')
ref_rgb = np.asarray(ref)[:, :, :3].astype(np.float32)
ref_fg = np.asarray(ref)[:, :, 3] > 128