Skip to content

X5 Crop v3.3.1

Choose a tag to compare

@rrriiicccooo rrriiicccooo released this 05 Jun 03:37
· 79 commits to main since this release

X5 Crop v3.3.1

快速使用

普通使用请下载本 Release 里的稳定版压缩包:

  • X5-Crop-v3.3.1.zip

第一次在新机器上使用:

  1. 下载并解压 X5-Crop-v3.3.1.zip
  2. 运行安装启动器:
    • macOS: install/X5_Crop_Mac_install.command
    • Windows: install/X5_Crop_win_install.bat
  3. 把下面这些文件和要裁切的 TIFF 长图放在同一个文件夹里:
    • X5_Crop.py
    • macOS 用 X5_Crop_Mac.command
    • Windows 用 X5_Crop_win.bat
  4. 双击对应系统的启动器。
  5. 先选择胶片格式,再选择是否开启 partial mode 和 Debug Analysis。

常用选择:

  • 直接回车或输入 135:普通 135,一条 6 张。
  • 输入 dual135 dual:双条 135,一共 12 张。
  • 输入 xpan / half / 645 / 66 / 67:对应其它格式。
  • partial mode 直接回车是 no,只在片头、片尾或不完整片条时开启。
  • debug analysis 直接回车是 no;输入 y 会只生成分析 JPG 和报告,不正式裁切。

运行耗时:

  • 在当前测试机器和常见 135 TIFF 长图上,普通 dry run / 裁切通常每张约 5-15 秒。
  • Debug Analysis 需要额外生成 JPG 分析图,通常每张约 10-30 秒。
  • 大尺寸 TIFF、开启 deskew、较慢硬盘或较慢电脑都会更久。
  • 终端在处理单张大 TIFF 时可能一段时间没有新的提示;这通常不是出错,而是脚本还在读取、检测、校平或写文件。等它进入下一张图或完成当前图后会继续输出状态。

高置信结果会自动裁切;低置信结果会进入 needs_review/,方便人工复核。

Quick Start

For normal use, download the stable zip package from this Release:

  • X5-Crop-v3.3.1.zip

On a new machine:

  1. Download and unzip X5-Crop-v3.3.1.zip.
  2. Run the installer launcher:
    • macOS: install/X5_Crop_Mac_install.command
    • Windows: install/X5_Crop_win_install.bat
  3. Put these files in the same folder as the TIFF long-strip scans:
    • X5_Crop.py
    • macOS: X5_Crop_Mac.command
    • Windows: X5_Crop_win.bat
  4. Double-click the launcher for your system.
  5. Choose the film format, then choose whether to enable partial mode and Debug Analysis.

Common choices:

  • Press Return or type 135: normal 135, 6 frames per strip.
  • Type dual or 135 dual: dual-strip 135, 12 frames total.
  • Type xpan / half / 645 / 66 / 67: other supported formats.
  • Press Return for partial mode to choose no; enable it only for leader, tail, or incomplete strips.
  • Press Return for debug analysis to choose no; type y to generate only analysis JPGs and reports without exporting cropped TIFFs.

Runtime:

  • On the current test machine with typical 135 TIFF long-strip scans, normal dry run / export usually takes about 5-15 seconds per file.
  • Debug Analysis also writes JPG analysis images and usually takes about 10-30 seconds per file.
  • Very large TIFFs, deskew, slower disks, or slower computers can take longer.
  • The terminal may show no new message for a while while one large TIFF is being read, detected, deskewed, or written. This usually does not mean the script has failed; it is still running and will print the next status line after the current file advances or finishes.

High-confidence results are cropped automatically. Low-confidence results go to needs_review/ for manual review.

稳定版说明 / Stable Release Note

普通用户建议下载 Release 压缩包。仓库 main 分支可能包含更新的开发进度,适合测试最新检测逻辑,但不一定是稳定发布版。

For normal use, download the Release zip package. The repository main branch may contain newer development work for testing the latest detection logic, but it is not necessarily the stable release.

相比上一版 v3 的主要变化

  • 保留 V3 系列较稳定的 outer / gap / candidate 主检测链路,继续坚持只有高置信结果才自动裁切。
  • 将 bleed 从检测评分中分离:bleed 只影响最终输出、报告和 Debug Analysis 色块,不参与 outer、gap、confidence 或 PASS/REVIEW。
  • 默认输出 bleed 为长轴 20px、短轴 10px,并自动对应横向 / 竖向长图方向。
  • 增加 PASS 后的轻量长轴输出保护,减少首尾画幅被同画幅拟合向内收得过多的情况;这不改变置信度或 PASS/REVIEW。
  • 保留弱分隔、片距异常、近似叠片、内容证据冲突等情况进入复核的保守流程。
  • Debug Analysis 输出 JPG 四联图,包含原始灰度图、Debug boxes、Separator evidence 和 Content evidence。
  • 支持先跑 Debug Analysis dry run,再复用报告里的裁切框进行正式导出;needs_review 会跳过。
  • 简化 Mac / Windows 启动器,并提供用户级依赖安装启动器。
  • README 改为中英双语用户文档,并加入 MIT License。

Main Changes Since Previous v3

  • Keeps the stable V3-style outer / gap / candidate detection chain and preserves the rule that only high-confidence results are cropped automatically.
  • Separates bleed from detection scoring. Bleed affects only final output, reports, and Debug Analysis boxes, not outer boxes, gaps, confidence, or PASS/REVIEW.
  • Default output bleed is 20px on the long axis and 10px on the short axis, with horizontal / vertical strip handling applied automatically.
  • Adds small PASS-only long-axis output protection to reduce inward shrink at first/last frames after same-frame fitting. This does not change confidence or PASS/REVIEW.
  • Keeps weak separators, irregular spacing, overlap-like frames, and conflicting content evidence in the conservative review workflow.
  • Debug Analysis writes JPG four-panel views: original gray, Debug boxes, Separator evidence, and Content evidence.
  • Supports running Debug Analysis dry run first, then reusing report crop boxes for export. needs_review files are skipped.
  • Simplifies Mac / Windows launchers and provides user-level dependency installers.
  • README is now bilingual Chinese/English, and the project uses the MIT License.