#!/usr/bin/env python3 # -*- coding: utf-8 -*- """ 母版落盘:一相圆 F2(复环 + 款出) 甲方裁定(2026-10-14):环上 NOVALON 绕两次;圆心「睿新致遠」穿出缺口。 三个未定的数由 cut 37 的实测收口: dx = 0.30·Rb —— F1(0.18) 出环 +45.7 姿态太怯;F3(0.42) 右缘余量 −15.8 顶破画布,判死; F2 出环 +78.5、余量 +16.9,两道闸都过且留有余地。 书法用墨 —— 朱砂款(F4) 与环同色后,细笔画的书法在 140px 以下被厚环带压过去, 图底关系糊成一团红;墨款保住「环是印、字是款」的分工。 开口 110° —— 80°(F5) 更像闭合的丸印但「缺一」变弱,140°(F6) 已不像圆。留 110° 为主, F5 作为「需要更圆时」的备选记在案。 实测(final.html,仪器三条对照全过:0.0 / 100.0 / 99.6): 环带填充率 45.8% · ch/Rb 0.48→0.25 · 圆心字高 74.7 · 离环 8.0 · 出环 +78.5 · 右缘余量 16.9 """ import importlib.util import os HERE = os.path.dirname(os.path.abspath(__file__)) sp = importlib.util.spec_from_file_location("fn", os.path.join(HERE, "final.py")) fn = importlib.util.module_from_spec(sp) sp.loader.exec_module(fn) DX = 0.30 items, lay, cen, dx, g, past = fn.geom(DX, **fn.BASE) BODY = fn.r2.ring_svg(items) + cen WHT = fn.r2.ring_svg(items, col=fn.WHITE) + cen.replace(fn.INK, fn.WHITE) OUTDIR = os.path.join(HERE, "assets-master") os.makedirs(OUTDIR, exist_ok=True) HDR = ('' % (fn.S, fn.S, fn.S, fn.S)) NOTE = ('') files = { "yixiangyuan-master.svg": HDR + BODY + "", "yixiangyuan-master-reversed.svg": '' % (fn.S, fn.S, fn.S, fn.S) + WHT + "", } for name, txt in files.items(): with open(os.path.join(OUTDIR, name), "w", encoding="utf-8") as f: f.write(NOTE + "\n" + txt) print("%-34s %8s B" % (name, format(len(txt), ","))) with open(os.path.join(OUTDIR, "master-params.json"), "w", encoding="utf-8") as f: import json json.dump({ "text": fn.BASE["text"], "opening_deg": fn.BASE["opening"], "gap_at_deg": fn.BASE["gap_at"], "rho": fn.BASE["rho"], "kappa": fn.BASE["kappa"], "stroke": fn.BASE["stroke"], "gapf": 0.02, "dx_frac_of_Rb0": DX, "canvas": fn.S, "measured": {"band_fill_pct": 45.8, "ch_over_Rb_head": round(lay["ch0"] / lay["Rb0"], 3), "ch_over_Rb_tail": round(lay["ch1"] / lay["Rb1"], 3), "center_char_h": round(g["csize"], 1), "clearance_to_band": round(g["clear"], 1), "past_baseline_circle": round(past, 1), "right_margin_to_canvas": round(fn.S - fn.g_x1(lay, dx, g["csize"]), 1)}, "instrument_controls": {"blank": 0.0, "solid": 100.0, "solid_annulus": 99.6}, }, f, ensure_ascii=False, indent=2) print("master-params.json") print("dx=%g 圆心字高=%g 出环=%+.1f" % (dx, g["csize"], past))