[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"similar-esimov--caire":3,"tool-esimov--caire":61},[4,18,26,36,44,53],{"id":5,"name":6,"github_repo":7,"description_zh":8,"stars":9,"difficulty_score":10,"last_commit_at":11,"category_tags":12,"status":17},4358,"openclaw","openclaw\u002Fopenclaw","OpenClaw 是一款专为个人打造的本地化 AI 助手，旨在让你在自己的设备上拥有完全可控的智能伙伴。它打破了传统 AI 助手局限于特定网页或应用的束缚，能够直接接入你日常使用的各类通讯渠道，包括微信、WhatsApp、Telegram、Discord、iMessage 等数十种平台。无论你在哪个聊天软件中发送消息，OpenClaw 都能即时响应，甚至支持在 macOS、iOS 和 Android 设备上进行语音交互，并提供实时的画布渲染功能供你操控。\n\n这款工具主要解决了用户对数据隐私、响应速度以及“始终在线”体验的需求。通过将 AI 部署在本地，用户无需依赖云端服务即可享受快速、私密的智能辅助，真正实现了“你的数据，你做主”。其独特的技术亮点在于强大的网关架构，将控制平面与核心助手分离，确保跨平台通信的流畅性与扩展性。\n\nOpenClaw 非常适合希望构建个性化工作流的技术爱好者、开发者，以及注重隐私保护且不愿被单一生态绑定的普通用户。只要具备基础的终端操作能力（支持 macOS、Linux 及 Windows WSL2），即可通过简单的命令行引导完成部署。如果你渴望拥有一个懂你",349277,3,"2026-04-06T06:32:30",[13,14,15,16],"Agent","开发框架","图像","数据工具","ready",{"id":19,"name":20,"github_repo":21,"description_zh":22,"stars":23,"difficulty_score":10,"last_commit_at":24,"category_tags":25,"status":17},3808,"stable-diffusion-webui","AUTOMATIC1111\u002Fstable-diffusion-webui","stable-diffusion-webui 是一个基于 Gradio 构建的网页版操作界面，旨在让用户能够轻松地在本地运行和使用强大的 Stable Diffusion 图像生成模型。它解决了原始模型依赖命令行、操作门槛高且功能分散的痛点，将复杂的 AI 绘图流程整合进一个直观易用的图形化平台。\n\n无论是希望快速上手的普通创作者、需要精细控制画面细节的设计师，还是想要深入探索模型潜力的开发者与研究人员，都能从中获益。其核心亮点在于极高的功能丰富度：不仅支持文生图、图生图、局部重绘（Inpainting）和外绘（Outpainting）等基础模式，还独创了注意力机制调整、提示词矩阵、负向提示词以及“高清修复”等高级功能。此外，它内置了 GFPGAN 和 CodeFormer 等人脸修复工具，支持多种神经网络放大算法，并允许用户通过插件系统无限扩展能力。即使是显存有限的设备，stable-diffusion-webui 也提供了相应的优化选项，让高质量的 AI 艺术创作变得触手可及。",162132,"2026-04-05T11:01:52",[14,15,13],{"id":27,"name":28,"github_repo":29,"description_zh":30,"stars":31,"difficulty_score":32,"last_commit_at":33,"category_tags":34,"status":17},1381,"everything-claude-code","affaan-m\u002Feverything-claude-code","everything-claude-code 是一套专为 AI 编程助手（如 Claude Code、Codex、Cursor 等）打造的高性能优化系统。它不仅仅是一组配置文件，而是一个经过长期实战打磨的完整框架，旨在解决 AI 代理在实际开发中面临的效率低下、记忆丢失、安全隐患及缺乏持续学习能力等核心痛点。\n\n通过引入技能模块化、直觉增强、记忆持久化机制以及内置的安全扫描功能，everything-claude-code 能显著提升 AI 在复杂任务中的表现，帮助开发者构建更稳定、更智能的生产级 AI 代理。其独特的“研究优先”开发理念和针对 Token 消耗的优化策略，使得模型响应更快、成本更低，同时有效防御潜在的攻击向量。\n\n这套工具特别适合软件开发者、AI 研究人员以及希望深度定制 AI 工作流的技术团队使用。无论您是在构建大型代码库，还是需要 AI 协助进行安全审计与自动化测试，everything-claude-code 都能提供强大的底层支持。作为一个曾荣获 Anthropic 黑客大奖的开源项目，它融合了多语言支持与丰富的实战钩子（hooks），让 AI 真正成长为懂上",144730,2,"2026-04-07T23:26:32",[14,13,35],"语言模型",{"id":37,"name":38,"github_repo":39,"description_zh":40,"stars":41,"difficulty_score":32,"last_commit_at":42,"category_tags":43,"status":17},2271,"ComfyUI","Comfy-Org\u002FComfyUI","ComfyUI 是一款功能强大且高度模块化的视觉 AI 引擎，专为设计和执行复杂的 Stable Diffusion 图像生成流程而打造。它摒弃了传统的代码编写模式，采用直观的节点式流程图界面，让用户通过连接不同的功能模块即可构建个性化的生成管线。\n\n这一设计巧妙解决了高级 AI 绘图工作流配置复杂、灵活性不足的痛点。用户无需具备编程背景，也能自由组合模型、调整参数并实时预览效果，轻松实现从基础文生图到多步骤高清修复等各类复杂任务。ComfyUI 拥有极佳的兼容性，不仅支持 Windows、macOS 和 Linux 全平台，还广泛适配 NVIDIA、AMD、Intel 及苹果 Silicon 等多种硬件架构，并率先支持 SDXL、Flux、SD3 等前沿模型。\n\n无论是希望深入探索算法潜力的研究人员和开发者，还是追求极致创作自由度的设计师与资深 AI 绘画爱好者，ComfyUI 都能提供强大的支持。其独特的模块化架构允许社区不断扩展新功能，使其成为当前最灵活、生态最丰富的开源扩散模型工具之一，帮助用户将创意高效转化为现实。",107888,"2026-04-06T11:32:50",[14,15,13],{"id":45,"name":46,"github_repo":47,"description_zh":48,"stars":49,"difficulty_score":32,"last_commit_at":50,"category_tags":51,"status":17},4721,"markitdown","microsoft\u002Fmarkitdown","MarkItDown 是一款由微软 AutoGen 团队打造的轻量级 Python 工具，专为将各类文件高效转换为 Markdown 格式而设计。它支持 PDF、Word、Excel、PPT、图片（含 OCR）、音频（含语音转录）、HTML 乃至 YouTube 链接等多种格式的解析，能够精准提取文档中的标题、列表、表格和链接等关键结构信息。\n\n在人工智能应用日益普及的今天，大语言模型（LLM）虽擅长处理文本，却难以直接读取复杂的二进制办公文档。MarkItDown 恰好解决了这一痛点，它将非结构化或半结构化的文件转化为模型“原生理解”且 Token 效率极高的 Markdown 格式，成为连接本地文件与 AI 分析 pipeline 的理想桥梁。此外，它还提供了 MCP（模型上下文协议）服务器，可无缝集成到 Claude Desktop 等 LLM 应用中。\n\n这款工具特别适合开发者、数据科学家及 AI 研究人员使用，尤其是那些需要构建文档检索增强生成（RAG）系统、进行批量文本分析或希望让 AI 助手直接“阅读”本地文件的用户。虽然生成的内容也具备一定可读性，但其核心优势在于为机器",93400,"2026-04-06T19:52:38",[52,14],"插件",{"id":54,"name":55,"github_repo":56,"description_zh":57,"stars":58,"difficulty_score":10,"last_commit_at":59,"category_tags":60,"status":17},4487,"LLMs-from-scratch","rasbt\u002FLLMs-from-scratch","LLMs-from-scratch 是一个基于 PyTorch 的开源教育项目，旨在引导用户从零开始一步步构建一个类似 ChatGPT 的大型语言模型（LLM）。它不仅是同名技术著作的官方代码库，更提供了一套完整的实践方案，涵盖模型开发、预训练及微调的全过程。\n\n该项目主要解决了大模型领域“黑盒化”的学习痛点。许多开发者虽能调用现成模型，却难以深入理解其内部架构与训练机制。通过亲手编写每一行核心代码，用户能够透彻掌握 Transformer 架构、注意力机制等关键原理，从而真正理解大模型是如何“思考”的。此外，项目还包含了加载大型预训练权重进行微调的代码，帮助用户将理论知识延伸至实际应用。\n\nLLMs-from-scratch 特别适合希望深入底层原理的 AI 开发者、研究人员以及计算机专业的学生。对于不满足于仅使用 API，而是渴望探究模型构建细节的技术人员而言，这是极佳的学习资源。其独特的技术亮点在于“循序渐进”的教学设计：将复杂的系统工程拆解为清晰的步骤，配合详细的图表与示例，让构建一个虽小但功能完备的大模型变得触手可及。无论你是想夯实理论基础，还是为未来研发更大规模的模型做准备",90106,"2026-04-06T11:19:32",[35,15,13,14],{"id":62,"github_repo":63,"name":64,"description_en":65,"description_zh":66,"ai_summary_zh":66,"readme_en":67,"readme_zh":68,"quickstart_zh":69,"use_case_zh":70,"hero_image_url":71,"owner_login":72,"owner_name":73,"owner_avatar_url":74,"owner_bio":75,"owner_company":76,"owner_location":76,"owner_email":77,"owner_twitter":78,"owner_website":79,"owner_url":80,"languages":81,"stars":94,"forks":95,"last_commit_at":96,"license":97,"difficulty_score":98,"env_os":99,"env_gpu":100,"env_ram":100,"env_deps":101,"category_tags":107,"github_topics":108,"view_count":32,"oss_zip_url":76,"oss_zip_packed_at":76,"status":17,"created_at":119,"updated_at":120,"faqs":121,"releases":152},5290,"esimov\u002Fcaire","caire","Content aware image resize library","Caire 是一款基于“接缝裁剪”（Seam Carving）算法的内容感知图像缩放库，旨在解决传统图片拉伸或裁剪导致主体变形、构图破坏的难题。它不像普通工具那样简单压缩像素，而是通过计算图像的能量图，智能识别并移除画面中视觉重要性最低的区域（如空白背景），从而在改变尺寸的同时完美保留人脸、建筑等关键主体的原始形态。\n\n这款工具特别适合开发者集成到图像处理流程中，同时也为设计师和摄影师提供了高效的命令行解决方案，尤其适用于需要批量处理图片或追求高质量无损缩放的场景。其核心技术亮点在于支持双向（水平与垂直）智能缩放，甚至能将图片放大；内置人脸检测功能，有效防止人物面部扭曲；此外，它还支持保护掩码与移除掩码，允许用户自定义保留或删除的特定区域。Caire 采用 Go 语言编写，具备极高的执行效率，支持递归并发处理整个目录，并提供直观的 GUI 进度条与调试模式，让复杂的算法过程变得透明可控。无论是通过管道命令集成还是直接调用，Caire 都能以极低的资源消耗实现专业级的图像重绘效果。","\u003Ch1 align=\"center\">\u003Cimg alt=\"Caire Logo\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_09572a099799.png\" height=\"180\">\u003C\u002Fh1>\n\n[![build](https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Factions\u002Fworkflows\u002Fbuild.yml\u002Fbadge.svg)](https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Factions\u002Fworkflows\u002Fbuild.yml)\n[![Go Reference](https:\u002F\u002Fpkg.go.dev\u002Fbadge\u002Fgithub.com\u002Fesimov\u002Fcaire.svg)](https:\u002F\u002Fpkg.go.dev\u002Fgithub.com\u002Fesimov\u002Fcaire)\n[![license](https:\u002F\u002Fimg.shields.io\u002Fgithub\u002Flicense\u002Fesimov\u002Fcaire)](.\u002FLICENSE)\n[![release](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Frelease-v1.5.0-blue.svg)](https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Freleases\u002Ftag\u002Fv1.5.0)\n[![homebrew](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fhomebrew-v1.5.0-orange.svg)](https:\u002F\u002Fformulae.brew.sh\u002Fformula\u002Fcaire)\n[![caire](https:\u002F\u002Fsnapcraft.io\u002Fcaire\u002Fbadge.svg)](https:\u002F\u002Fsnapcraft.io\u002Fcaire)\n\n**Caire** is a content aware image resize library based on *[Seam Carving for Content-Aware Image Resizing](https:\u002F\u002Finst.eecs.berkeley.edu\u002F~cs194-26\u002Ffa16\u002Fhw\u002Fproj4-seamcarving\u002Fimret.pdf)* paper.\n\n## How does it work\n* An energy map (edge detection) is generated from the provided image.\n* The algorithm tries to find the least important parts of the image taking into account the lowest energy values.\n* Using a dynamic programming approach the algorithm will generate individual seams across the image from top to down, or from left to right (depending on the horizontal or vertical resizing) and will allocate for each seam a custom value, the least important pixels having the lowest energy cost and the most important ones having the highest cost.\n* We traverse the image from the second row to the last row and compute the cumulative minimum energy for all possible connected seams for each entry.\n* The minimum energy level is calculated by summing up the current pixel value with the lowest value of the neighboring pixels obtained from the previous row.\n* We traverse the image from top to bottom and compute the minimum energy level. For each pixel in a row we compute the energy of the current pixel plus the energy of one of the three possible pixels above it.\n* Find the lowest cost seam from the energy matrix starting from the last row and remove it.\n* Repeat the process.\n\n#### The process illustrated:\n\n| Original image | Energy map | Seams applied\n|:--:|:--:|:--:|\n| ![original](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_8c8dae634fe7.jpg) | ![sobel](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_50355df61f86.jpg) | ![debug](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_f0715ddc33fe.jpg) | ![out](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_74010bdcaf51.jpg) |\n\n## Features\nKey features which differentiates this library from the other existing open source solutions:\n\n- [x] **GUI progress indicator**\n- [x] Customizable command line support\n- [x] Support for both shrinking or enlarging the image\n- [x] Resize image both vertically and horizontally\n- [x] Face detection to avoid face deformation\n- [x] Support for multiple output image type (jpg, jpeg, png, bmp)\n- [x] Support for `stdin` and `stdout` pipe commands\n- [x] Can process whole directories recursively and concurrently\n- [x] Use of sobel threshold for fine tuning\n- [x] Use of blur filter for increased edge detection\n- [x] Support for squaring the image with a single command\n- [x] Support for proportional scaling\n- [x] Support for protective mask\n- [x] Support for removal mask\n- [x] [GUI debug mode support](#masks-support)\n\n## Install\nFirst, install Go, set your `GOPATH`, and make sure `$GOPATH\u002Fbin` is on your `PATH`.\n\n```bash\n$ go install github.com\u002Fesimov\u002Fcaire\u002Fcmd\u002Fcaire@latest\n```\n\n## MacOS (Brew) install\nThe library can also be installed via Homebrew.\n\n```bash\n$ brew install caire\n```\n\n## Usage\n\n```bash\n$ caire -in input.jpg -out output.jpg\n```\n\n### Supported commands:\n```bash\n$ caire --help\n```\nThe following flags are supported:\n\n| Flag | Default | Description |\n| --- | --- | --- |\n| `in` | - | Input file |\n| `out` | - | Output file |\n| `width` | n\u002Fa | New width |\n| `height` | n\u002Fa | New height |\n| `preview` | true | Show GUI window |\n| `perc` | false | Reduce image by percentage |\n| `square` | false | Reduce image to square dimensions |\n| `blur` | 4 | Blur radius |\n| `sobel` | 2 | Sobel filter threshold |\n| `debug` | false | Use debugger |\n| `face` | false | Use face detection |\n| `angle` | float | Plane rotated faces angle |\n| `mask` | string | Mask file path |\n| `rmask` | string | Remove mask file path |\n| `color` | string | Seam color (default `#ff0000`) |\n| `shape` | string | Shape type used for debugging: `circle`,`line` (default `circle`) |\n\n## Face detection\n\nThe library is capable of detecting human faces prior resizing the images by using the lightweight Pigo (https:\u002F\u002Fgithub.com\u002Fesimov\u002Fpigo) face detection library.\n\nThe image below illustrates the application capabilities for human face detection prior resizing. It's clearly visible that with face detection activated the algorithm will avoid cropping pixels inside the detected faces, retaining the face zone unaltered.\n\n| Original image | With face detection | Without face detection\n|:--:|:--:|:--:|\n| ![Original](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_5704b3a78ea0.jpg) | ![With Face Detection](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_14b2c7dfce3e.jpg) | ![Without Face Detection](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_3ed4f8fd2b29.jpg) |\n\n[Sample image source](http:\u002F\u002Fwww.lens-rumors.com\u002Fwp-content\u002Fuploads\u002F2014\u002F12\u002FEF-M-55-200mm-f4.5-6.3-IS-STM-sample.jpg)\n\n### GUI progress indicator\n\n\u003Cp align=\"center\">\u003Cimg alt=\"GUI preview\" title=\"GUI preview\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_a768d3dfb5c8.gif\">\u003C\u002Fp>\n\nA GUI preview mode is also incorporated into the library for in time process visualization. The [Gio](http:\u002F\u002Fgioui.org\u002F) GUI library has been used because of its robustness and modern architecture. Prior running it please make sure that you have installed all the required dependencies noted in the installation section (https:\u002F\u002Fgioui.org\u002F#installation) .\n\nThe preview window is activated by default but you can deactivate it any time by setting the `-preview` flag to false. When the images are processed concurrently from a directory the preview mode is deactivated.\n\n### Face detection to avoid face deformation\nIn order to detect faces prior rescaling, use the `-face` flag. There is no need to provide a face classification file, since it's already embedded into the generated binary file. The sample code below will resize the provided image with 20%, but checks for human faces in order tot avoid face deformations.\n\nFor face detection related settings please check the Pigo [documentation](https:\u002F\u002Fgithub.com\u002Fesimov\u002Fpigo\u002Fblob\u002Fmaster\u002FREADME.md).\n\n```bash\n$ caire -in input.jpg -out output.jpg -face=1 -perc=1 -width=20\n```\n\n### Support for `stdin` and `stdout` pipe commands\nYou can also use `stdin` and `stdout` with `-`:\n\n```bash\n$ cat input\u002Fsource.jpg | caire -in - -out - >out.jpg\n```\n\n`in` and `out` default to `-` so you can also use:\n\n```bash\n$ cat input\u002Fsource.jpg | caire >out.jpg\n$ caire -out out.jpg \u003C input\u002Fsource.jpg\n```\n\nYou can provide also an image URL for the `-in` flag or even use **curl** or **wget** as a pipe command in which case there is no need to use the `-in` flag.\n\n```bash\n$ caire -in \u003Cimage_url> -out \u003Coutput-folder>\n$ curl -s \u003Cimage_url> | caire > out.jpg\n```\n\n### Process multiple images from a directory concurrently\nThe library can also process multiple images from a directory **concurrently**. You have to provide only the source and the destination folder and the new width or height in this case.\n\n```bash\n$ caire -in \u003Cinput_folder> -out \u003Coutput-folder>\n```\n\n### Support for multiple output image type\nThere is no need to define the output file type, just use the correct extension and the library will encode the image to that specific type.\n\n### Other options\nIn case you wish to scale down the image by a specific percentage, it can be used the **`-perc`** boolean flag. In this case the values provided for the `width` and `height` are expressed in percentage and not pixel values. For example to reduce the image dimension by 20% both horizontally and vertically you can use the following command:\n\n```bash\n$ caire -in input\u002Fsource.jpg -out .\u002Fout.jpg -perc=1 -width=20 -height=20 -debug=false\n```\n\nAlso the library supports the **`-square`** option. When this option is used the image will be resized to a square, based on the shortest edge.\n\nWhen an image is resized on both the X and Y axis, the algorithm will first try to rescale it prior resizing, but also will preserve the image aspect ratio. The seam carving algorithm is applied only to the remaining points. Ex. : given an image of dimensions 2048x1536 if we want to resize to the 1024x500, the tool first rescale the image to 1024x768 and then will remove only the remaining 268px.\n\n### Masks support:\n\n- `-mask`: The path to the protective mask. The mask should be in binary format and have the same size as the input image. White areas represent regions where no seams should be carved.\n- `-rmask`: The path to the removal mask. The mask should be in binary format and have the same size as the input image. White areas represent regions to be removed.\n\nMask | Mask removal\n:-: | :-:\n\u003Cvideo src='https:\u002F\u002Fuser-images.githubusercontent.com\u002F883386\u002F197509861-86733da8-0846-419a-95eb-4fb5a97607d5.mp4' width=180\u002F> | \u003Cvideo src='https:\u002F\u002Fuser-images.githubusercontent.com\u002F883386\u002F197397857-7b785d7c-2f80-4aed-a5d2-75c429389060.mp4' width=180\u002F>\n\n### Caire integrations\n- [x] Caire can be used as a serverless function via OpenFaaS: https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire-openfaas\n- [x] Caire can also be used as a `snap` function (https:\u002F\u002Fsnapcraft.io\u002Fcaire): `$ snap run caire --h`\n\n\u003Ca href=\"https:\u002F\u002Fsnapcraft.io\u002Fcaire\">\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_d8e79bb391d9.png\" alt=\"snapcraft caire\">\u003C\u002Fa>\n\n## Results\n\n#### Shrunk images\n| Original | Shrunk |\n| --- | --- |\n| ![broadway_tower_edit](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_6497b6c9a160.jpg) | ![broadway_tower_edit](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_4d239632d716.jpg) |\n| ![waterfall](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_7f04e16fde0d.png) | ![waterfall](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_7b5bfa590362.jpg) |\n| ![dubai](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_efa2cc7f6126.jpg) | ![dubai](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_5628acb43ee1.jpg) |\n| ![boat](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_3a8da16111dd.jpg) | ![boat](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_f3124e4d1945.jpg) |\n\n#### Enlarged images\n| Original | Extended |\n| --- | --- |\n| ![gasadalur](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_36d68787dc84.jpg) | ![gasadalur](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_e379fd2e97ad.jpg) |\n| ![dubai](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_efa2cc7f6126.jpg) | ![dubai](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_b815f8308b6d.jpg) |\n### Useful resources\n* https:\u002F\u002Fen.wikipedia.org\u002Fwiki\u002FSeam_carving\n* https:\u002F\u002Finst.eecs.berkeley.edu\u002F~cs194-26\u002Ffa16\u002Fhw\u002Fproj4-seamcarving\u002Fimret.pdf\n* http:\u002F\u002Fpages.cs.wisc.edu\u002F~moayad\u002Fcs766\u002Fdownload_files\u002Falnammi_cs_766_final_report.pdf\n* https:\u002F\u002Fstacks.stanford.edu\u002Ffile\u002Fdruid:my512gb2187\u002FZargham_Nassirpour_Content_aware_image_resizing.pdf\n\n## Author\n\n* Endre Simo ([@simo_endre](https:\u002F\u002Ftwitter.com\u002Fsimo_endre))\n\n## License\n\nCopyright © 2018 Endre Simo\n\nThis project is under the MIT License. See the LICENSE file for the full license text.\n","\u003Ch1 align=\"center\">\u003Cimg alt=\"Caire Logo\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_09572a099799.png\" height=\"180\">\u003C\u002Fh1>\n\n[![build](https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Factions\u002Fworkflows\u002Fbuild.yml\u002Fbadge.svg)](https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Factions\u002Fworkflows\u002Fbuild.yml)\n[![Go Reference](https:\u002F\u002Fpkg.go.dev\u002Fbadge\u002Fgithub.com\u002Fesimov\u002Fcaire.svg)](https:\u002F\u002Fpkg.go.dev\u002Fgithub.com\u002Fesimov\u002Fcaire)\n[![license](https:\u002F\u002Fimg.shields.io\u002Fgithub\u002Flicense\u002Fesimov\u002Fcaire)](.\u002FLICENSE)\n[![release](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Frelease-v1.5.0-blue.svg)](https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Freleases\u002Ftag\u002Fv1.5.0)\n[![homebrew](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fhomebrew-v1.5.0-orange.svg)](https:\u002F\u002Fformulae.brew.sh\u002Fformula\u002Fcaire)\n[![caire](https:\u002F\u002Fsnapcraft.io\u002Fcaire\u002Fbadge.svg)](https:\u002F\u002Fsnapcraft.io\u002Fcaire)\n\n**Caire** 是一个基于 *[Seam Carving for Content-Aware Image Resizing](https:\u002F\u002Finst.eecs.berkeley.edu\u002F~cs194-26\u002Ffa16\u002Fhw\u002Fproj4-seamcarving\u002Fimret.pdf)* 论文的内容感知图像缩放库。\n\n## 工作原理\n* 从提供的图像中生成能量图（边缘检测）。\n* 算法会根据最低的能量值，尝试找到图像中最不重要的部分。\n* 通过动态规划方法，算法会在图像上从上到下或从左到右（取决于水平或垂直缩放）生成独立的“接缝”，并为每条接缝分配一个自定义值，其中最重要像素的能量成本最高，最不重要像素的能量成本最低。\n* 我们从第二行开始遍历图像，计算每一项所有可能连接接缝的累积最小能量。\n* 最小能量等级是通过将当前像素值与前一行中相邻像素的最低值相加来计算的。\n* 我们从上到下遍历图像，计算最小能量等级。对于每一行中的每个像素，我们计算当前像素的能量加上其上方三个可能像素之一的能量。\n* 从能量矩阵中找出成本最低的接缝并将其移除。\n* 重复该过程。\n\n#### 过程示意图：\n\n| 原始图像 | 能量图 | 应用的接缝 |\n|:--:|:--:|:--:|\n| ![original](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_8c8dae634fe7.jpg) | ![sobel](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_50355df61f86.jpg) | ![debug](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_f0715ddc33fe.jpg) | ![out](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_74010bdcaf51.jpg) |\n\n## 特性\n本库区别于其他现有开源解决方案的关键特性：\n\n- [x] **GUI 进度指示器**\n- [x] 可定制的命令行支持\n- [x] 同时支持缩小和放大图像\n- [x] 可以同时进行垂直和水平方向的缩放\n- [x] 人脸检测功能，避免面部变形\n- [x] 支持多种输出图像格式（jpg、jpeg、png、bmp）\n- [x] 支持 `stdin` 和 `stdout` 管道命令\n- [x] 可递归且并发地处理整个目录\n- [x] 使用 Sobel 阈值进行精细调整\n- [x] 使用模糊滤波器增强边缘检测\n- [x] 支持通过单个命令将图像裁剪为正方形\n- [x] 支持按比例缩放\n- [x] 支持保护性遮罩\n- [x] 支持移除性遮罩\n- [x] [GUI 调试模式支持](#masks-support)\n\n## 安装\n首先，安装 Go，设置好 `GOPATH`，并确保 `$GOPATH\u002Fbin` 在你的 `PATH` 中。\n\n```bash\n$ go install github.com\u002Fesimov\u002Fcaire\u002Fcmd\u002Fcaire@latest\n```\n\n## macOS (Brew) 安装\n该库也可以通过 Homebrew 安装。\n\n```bash\n$ brew install caire\n```\n\n## 使用\n\n```bash\n$ caire -in input.jpg -out output.jpg\n```\n\n### 支持的命令：\n```bash\n$ caire --help\n```\n支持以下标志：\n\n| 标志 | 默认值 | 描述 |\n| --- | --- | --- |\n| `in` | - | 输入文件 |\n| `out` | - | 输出文件 |\n| `width` | n\u002Fa | 新宽度 |\n| `height` | n\u002Fa | 新高度 |\n| `preview` | true | 显示 GUI 窗口 |\n| `perc` | false | 按百分比缩小图像 |\n| `square` | false | 将图像缩放为正方形 |\n| `blur` | 4 | 模糊半径 |\n| `sobel` | 2 | Sobel 滤波器阈值 |\n| `debug` | false | 使用调试器 |\n| `face` | false | 使用人脸检测 |\n| `angle` | float | 旋转平面中的人脸角度 |\n| `mask` | string | 遮罩文件路径 |\n| `rmask` | string | 移除遮罩文件路径 |\n| `color` | string | 接缝颜色（默认 `#ff0000`） |\n| `shape` | string | 调试时使用的形状类型：`circle`、`line`（默认 `circle`）|\n\n## 人脸检测\n\n该库能够利用轻量级的 Pigo（https:\u002F\u002Fgithub.com\u002Fesimov\u002Fpigo）人脸检测库，在缩放图像之前检测出人脸。\n\n下图展示了在缩放前进行人脸检测的应用效果。可以清楚地看到，启用人脸检测后，算法会避免裁剪检测到的人脸区域内的像素，从而保持人脸区域不变。\n\n| 原始图像 | 启用人脸检测 | 未启用人脸检测 |\n|:--:|:--:|:--:|\n| ![Original](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_5704b3a78ea0.jpg) | ![With Face Detection](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_14b2c7dfce3e.jpg) | ![Without Face Detection](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_3ed4f8fd2b29.jpg) |\n\n[示例图片来源](http:\u002F\u002Fwww.lens-rumors.com\u002Fwp-content\u002Fuploads\u002F2014\u002F12\u002FEF-M-55-200mm-f4.5-6.3-IS-STM-sample.jpg)\n\n### GUI 进度指示器\n\n\u003Cp align=\"center\">\u003Cimg alt=\"GUI 预览\" title=\"GUI 预览\" src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_a768d3dfb5c8.gif\">\u003C\u002Fp>\n\n该库还内置了 GUI 预览模式，用于实时可视化处理过程。由于其强大性和现代架构，使用了 [Gio](http:\u002F\u002Fgioui.org\u002F) GUI 库。在运行之前，请确保已安装安装部分中提到的所有依赖项（https:\u002F\u002Fgioui.org\u002F#installation）。\n\n预览窗口默认开启，但您可以通过将 `-preview` 标志设置为 `false` 来随时关闭它。当从目录中并发处理图像时，预览模式将被禁用。\n\n### 人脸检测以避免面部变形\n为了在重新缩放之前检测人脸，请使用 `-face` 标志。无需提供人脸分类文件，因为它已嵌入到生成的二进制文件中。下面的示例代码会将提供的图像按 20% 的比例缩小，但在执行操作前会检查是否存在人脸，以避免面部变形。\n\n有关人脸检测的相关设置，请参阅 Pigo 的 [文档](https:\u002F\u002Fgithub.com\u002Fesimov\u002Fpigo\u002Fblob\u002Fmaster\u002FREADME.md)。\n\n```bash\n$ caire -in input.jpg -out output.jpg -face=1 -perc=1 -width=20\n```\n\n### 支持 `stdin` 和 `stdout` 管道命令\n您也可以使用 `stdin` 和 `stdout`，只需将输入和输出指定为 `-`：\n\n```bash\n$ cat input\u002Fsource.jpg | caire -in - -out - >out.jpg\n```\n\n由于 `in` 和 `out` 默认为 `-`，因此也可以这样使用：\n\n```bash\n$ cat input\u002Fsource.jpg | caire >out.jpg\n$ caire -out out.jpg \u003C input\u002Fsource.jpg\n```\n\n您还可以为 `-in` 标志提供一个图像 URL，甚至可以使用 `curl` 或 `wget` 作为管道命令，在这种情况下无需使用 `-in` 标志。\n\n```bash\n$ caire -in \u003Cimage_url> -out \u003Coutput-folder>\n$ curl -s \u003Cimage_url> | caire > out.jpg\n```\n\n### 并发处理目录中的多张图片\n该库还可以**并发**处理目录中的多张图片。在这种情况下，您只需提供源文件夹和目标文件夹，以及新的宽度或高度。\n\n```bash\n$ caire -in \u003Cinput_folder> -out \u003Coutput-folder>\n```\n\n### 支持多种输出图像格式\n无需定义输出文件类型，只需使用正确的文件扩展名，库就会将图像编码为该特定格式。\n\n### 其他选项\n如果您希望按特定百分比缩小图像，可以使用 **`-perc`** 布尔标志。在这种情况下，`width` 和 `height` 提供的值将以百分比表示，而不是像素值。例如，要将图像在水平和垂直方向上都缩小 20%，可以使用以下命令：\n\n```bash\n$ caire -in input\u002Fsource.jpg -out .\u002Fout.jpg -perc=1 -width=20 -height=20 -debug=false\n```\n\n此外，库还支持 **`-square`** 选项。当使用此选项时，图像将根据最短边调整为正方形。\n\n当图像在 X 轴和 Y 轴上同时缩放时，算法会先尝试在进一步缩放之前进行重采样，同时保持图像的宽高比例不变。仅对剩余部分应用接缝雕刻算法。例如：给定一张 2048x1536 的图像，如果我们要将其调整为 1024x500，工具会先将图像缩放到 1024x768，然后再移除剩余的 268 像素。\n\n### 掩码支持：\n\n- `-mask`: 保护掩码的路径。掩码应为二进制格式，且与输入图像大小相同。白色区域表示不应雕刻接缝的区域。\n- `-rmask`: 移除掩码的路径。掩码应为二进制格式，且与输入图像大小相同。白色区域表示需要移除的区域。\n\n掩码 | 掩码移除\n:-: | :-:\n\u003Cvideo src='https:\u002F\u002Fuser-images.githubusercontent.com\u002F883386\u002F197509861-86733da8-0846-419a-95eb-4fb5a97607d5.mp4' width=180\u002F> | \u003Cvideo src='https:\u002F\u002Fuser-images.githubusercontent.com\u002F883386\u002F197397857-7b785d7c-2f80-4aed-a5d2-75c429389060.mp4' width=180\u002F>\n\n### Caire 集成\n- [x] Caire 可以通过 OpenFaaS 用作无服务器函数：https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire-openfaas\n- [x] Caire 也可以作为 `snap` 功能使用（https:\u002F\u002Fsnapcraft.io\u002Fcaire）：`$ snap run caire --h`\n\n\u003Ca href=\"https:\u002F\u002Fsnapcraft.io\u002Fcaire\">\u003Cimg src=\"https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_d8e79bb391d9.png\" alt=\"snapcraft caire\">\u003C\u002Fa>\n\n## 结果\n\n#### 缩小后的图片\n| 原图 | 缩小后 |\n| --- | --- |\n| ![broadway_tower_edit](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_6497b6c9a160.jpg) | ![broadway_tower_edit](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_4d239632d716.jpg) |\n| ![waterfall](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_7f04e16fde0d.png) | ![waterfall](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_7b5bfa590362.jpg) |\n| ![dubai](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_efa2cc7f6126.jpg) | ![dubai](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_5628acb43ee1.jpg) |\n| ![boat](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_3a8da16111dd.jpg) | ![boat](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_f3124e4d1945.jpg) |\n\n#### 放大后的图片\n| 原图 | 扩展后 |\n| --- | --- |\n| ![gasadalur](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_36d68787dc84.jpg) | ![gasadalur](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_e379fd2e97ad.jpg) |\n| ![dubai](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_efa2cc7f6126.jpg) | ![dubai](https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_readme_b815f8308b6d.jpg) |\n### 有用资源\n* https:\u002F\u002Fen.wikipedia.org\u002Fwiki\u002FSeam_carving\n* https:\u002F\u002Finst.eecs.berkeley.edu\u002F~cs194-26\u002Ffa16\u002Fhw\u002Fproj4-seamcarving\u002Fimret.pdf\n* http:\u002F\u002Fpages.cs.wisc.edu\u002F~moayad\u002Fcs766\u002Fdownload_files\u002Falnammi_cs_766_final_report.pdf\n* https:\u002F\u002Fstacks.stanford.edu\u002Ffile\u002Fdruid:my512gb2187\u002FZargham_Nassirpour_Content_aware_image_resizing.pdf\n\n## 作者\n\n* Endre Simo ([@simo_endre](https:\u002F\u002Ftwitter.com\u002Fsimo_endre))\n\n## 许可证\n\n版权所有 © 2018 Endre Simo\n\n本项目采用 MIT 许可证。完整的许可文本请参阅 LICENSE 文件。","# Caire 快速上手指南\n\nCaire 是一个基于“接缝裁剪（Seam Carving）”算法的内容感知图像大小调整库。它能在缩放图片时智能识别并保留重要内容（如人脸、主体物体），避免传统拉伸导致的变形。\n\n## 环境准备\n\n*   **操作系统**：Linux, macOS, Windows (需配置 Go 环境)\n*   **前置依赖**：\n    *   **Go 语言环境**：需安装 Go 并配置好 `GOPATH`，确保 `$GOPATH\u002Fbin` 已加入系统 `PATH` 环境变量。\n    *   **GUI 依赖（可选）**：若需使用图形化进度预览窗口 (`-preview`)，请确保系统已安装 [Gio](https:\u002F\u002Fgioui.org\u002F#installation) 所需的图形库依赖。若仅命令行批量处理，可忽略此项。\n\n## 安装步骤\n\n你可以通过以下任意一种方式安装 Caire：\n\n### 方式一：通过 Go 安装（推荐）\n适用于所有平台，直接获取最新源码编译安装：\n```bash\ngo install github.com\u002Fesimov\u002Fcaire\u002Fcmd\u002Fcaire@latest\n```\n\n### 方式二：macOS (Homebrew)\n如果你使用的是 macOS 且安装了 Homebrew：\n```bash\nbrew install caire\n```\n\n### 方式三：Snap (Linux)\n适用于支持 Snap 的 Linux 发行版：\n```bash\nsudo snap install caire\n```\n\n## 基本使用\n\n安装完成后，即可在终端使用 `caire` 命令。\n\n### 1. 基础缩放\n将图片 `input.jpg` 调整为指定宽度（高度自动计算以保持比例），输出为 `output.jpg`：\n```bash\ncaire -in input.jpg -out output.jpg -width 800\n```\n\n### 2. 按百分比缩放\n将图片长宽同时缩小 20%：\n```bash\ncaire -in input.jpg -out output.jpg -perc=1 -width 20 -height 20\n```\n\n### 3. 人脸保护模式（核心功能）\n开启人脸检测，防止缩放时人物面部变形：\n```bash\ncaire -in input.jpg -out output.jpg -face=1 -width 600\n```\n\n### 4. 批量处理目录\n递归并发处理整个文件夹内的图片：\n```bash\ncaire -in .\u002Fsource_folder -out .\u002Fdest_folder -width 1024\n```\n\n### 5. 管道流式处理\n支持 stdin\u002Fstdout，可结合 curl 或其他工具使用：\n```bash\ncurl -s https:\u002F\u002Fexample.com\u002Fimage.jpg | caire -width 500 > resized.jpg\n```\n\n> **提示**：运行时会默认弹出 GUI 进度窗口。若在服务器或无界面环境下运行，请添加 `-preview=false` 参数禁用它。","某电商运营团队需要为移动端首页快速生成大量商品展示图，要求将不同比例的原始素材统一裁剪为正方形，同时必须保证商品主体和模特面部不发生变形。\n\n### 没有 caire 时\n- 传统强制拉伸或简单裁剪导致商品关键细节丢失，或者人物脸部被严重压扁变形，视觉效果极差。\n- 设计师不得不手动使用 Photoshop 逐张进行“内容识别缩放”，处理几百张图片耗时数小时，效率极低。\n- 难以批量自动化处理，每次活动上新都需要投入大量人力重复机械劳动，无法集成到现有的 CI\u002FCD 发布流程中。\n- 缺乏对重要区域的保护机制，算法无法区分背景噪音与核心商品，经常误删关键像素。\n\n### 使用 caire 后\n- 利用 seam carving（接缝裁剪）算法智能移除低能量背景像素，在改变尺寸的同时完美保留商品结构和人脸特征。\n- 通过 `-face` 参数自动检测并保护面部区域，结合掩码功能指定商品为保护区，彻底杜绝核心主体变形。\n- 支持递归并发处理整个目录，一条命令即可在秒级内完成数百张图片的智能化方形适配，大幅缩短上线周期。\n- 轻松嵌入后端 Go 服务或 Shell 脚本流水线，实现从图片上传到多端适配的全流程自动化，无需人工干预。\n\ncaire 通过智能感知图像内容，将原本繁琐的手工修图工作转化为高效的自动化流程，在确保视觉质量的前提下实现了图片处理的降本增效。","https:\u002F\u002Foss.gittoolsai.com\u002Fimages\u002Fesimov_caire_f0715ddc.jpg","esimov","Endre Simo","https:\u002F\u002Foss.gittoolsai.com\u002Favatars\u002Fesimov_73960714.jpg","Software developer",null,"esimov@gmail.com","simo_endre","www.esimov.com","https:\u002F\u002Fgithub.com\u002Fesimov",[82,86,90],{"name":83,"color":84,"percentage":85},"Go","#00ADD8",98.7,{"name":87,"color":88,"percentage":89},"Shell","#89e051",1.1,{"name":91,"color":92,"percentage":93},"Makefile","#427819",0.2,10487,386,"2026-04-07T14:01:41","MIT",1,"Linux, macOS, Windows","未说明",{"notes":102,"python":103,"dependencies":104},"该工具基于 Go 语言开发，无需 Python 环境。可通过 Go 包管理器、Homebrew (macOS) 或 Snap 安装。若启用 GUI 预览模式，需安装 Gio 库的系统依赖（详见 Gio 官方文档）。人脸检测功能已内置模型，无需额外下载分类文件。支持通过管道命令处理图像流及并发处理目录下的多张图片。","不需要",[105,106],"Go (最新稳定版)","Gio (GUI 库，可选)",[14,15],[109,110,111,112,113,114,115,116,117,118],"seam-carving","image-processing","image-resize","edge-detection","golang","face-detection","computer-vision","machine-learning","content-aware-scaling","content-aware-resize","2026-03-27T02:49:30.150509","2026-04-08T09:23:09.153218",[122,127,132,137,142,147],{"id":123,"question_zh":124,"answer_zh":125,"source_url":126},23982,"如何在 Linux (Ubuntu) 上解决缺少源文件（如 X11\u002FXlib.h, wayland-client.h）的安装错误？","在 Ubuntu 上安装时若遇到缺少头文件的错误，需要手动安装 GIOUI 库的依赖项。具体步骤如下：\n1. 安装 Go 并配置好 GOPATH，确保 $GOPATH\u002Fbin 已加入 PATH。\n2. 按照官方文档安装 GIOUI 库：https:\u002F\u002Fgioui.org\u002Fdoc\u002Finstall\u002Flinux\n3. 如果运行测试命令失败，尝试在 .bashrc 中添加 `export LC_ALL=en_US.UTF-8` 以解决编码问题。\n4. 运行命令时使用 `go run github.com\u002Fesimov\u002Fcaire\u002Fcmd\u002Fcaire@latest -in input.jpeg -out output.jpeg`。注意直接运行 `caire` 命令可能会报错，建议使用 go run 方式或确保二进制文件正确构建。\n此外，也可以尝试通过 apt 安装开发库：`apt install libwayland-dev` 等。","https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Fissues\u002F79",{"id":128,"question_zh":129,"answer_zh":130,"source_url":131},23983,"为什么在使用人脸检测功能放大图像时会发生程序崩溃 (Panic)？","这是一个已知问题，在特定版本中当同时启用“放大图像”和“人脸检测”功能时会导致空指针引用崩溃。维护者已在 v1.4.4 版本中修复了此问题。如果您遇到此类 panic 错误，请确保将库或命令行工具更新到最新版本（v1.4.4 或更高）：\n`go install github.com\u002Fesimov\u002Fcaire\u002Fcmd\u002Fcaire@latest`\n更新后该问题应已解决。","https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Fissues\u002F75",{"id":133,"question_zh":134,"answer_zh":135,"source_url":136},23984,"如何正确配置 Windows 上的 Go 环境以运行 caire？","在 Windows 上运行失败通常是因为 GOPATH 配置错误。请检查并遵循以下配置：\n1. GOPATH 不应指向 Go 的安装目录（如 C:\\Go\\bin），而应指向您的项目工作目录，例如：`GOPATH=\"C:\\Users\\YourName\\Go\"`。\n2. 在该目录下创建 `src` 文件夹。执行 `go get` 后，项目路径应为 `C:\\Users\\YourName\\Go\\src\\github.com\\esimov\\caire`。\n3. 避免将项目放在 OneDrive 同步文件夹中，因为 Go 在 Windows 10 的 OneDrive 上运行存在已知问题。\n4. 确保图片文件路径存在，并注意不要混用 Linux 和 Windows 的路径分隔符。","https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Fissues\u002F37",{"id":138,"question_zh":139,"answer_zh":140,"source_url":141},23985,"使用 `-face` 标志进行人脸保护时为什么没有效果？","如果使用 `go run` 直接运行命令导致人脸检测无效，可能是因为级联文件（cascade file）未正确嵌入。建议尝试以下方法：\n1. 本地构建二进制文件以确保资源正确嵌入：进入 `cmd\u002Fcaire` 目录，运行 `go build main.go`，然后使用生成的可执行文件运行。\n2. 或者使用 `go install github.com\u002Fesimov\u002Fcaire\u002Fcmd\u002Fcaire@latest` 安装到 $GOPATH\u002Fbin，这通常能正确处理依赖和资源。\n维护者指出，本地构建 (`go build`) 能确保证人脸检测功能正常工作，而直接使用 `go run` 在某些环境下可能存在资源加载问题。","https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Fissues\u002F84",{"id":143,"question_zh":144,"answer_zh":145,"source_url":146},23986,"为什么修改图像尺寸时报错“无法在保持纵横比的情况下调整到此大小”？","该错误曾在旧版本中出现，即使用户意图改变纵横比时也会误报。此问题已在后续的 Pull Request (#60) 中得到修复。如果您遇到此错误，请务必更新到最新版本的 caire。更新后，工具将允许用户自由指定新的宽度和高度，不再强制要求保持原始纵横比，从而实现真正的内容感知缩放。","https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Fissues\u002F54",{"id":148,"question_zh":149,"answer_zh":150,"source_url":151},23987,"如何使用 mask 参数完全保护特定对象不被算法扭曲？","目前算法在处理 mask 参数时可能仍会对标记为重要的对象产生轻微扭曲，暂时没有一个特定的参数可以强制算法“完全忽略”掩码区域而不进行任何处理。不过，维护者正在开发 GUI 调试模式，未来将更容易观察和调整算法对掩码的处理逻辑。建议关注后续版本更新，以获得更精确的掩码控制功能。当前可以通过调整 mask 的权重或百分比参数来尽量减少扭曲，但无法做到 100% 不触碰。","https:\u002F\u002Fgithub.com\u002Fesimov\u002Fcaire\u002Fissues\u002F86",[153,158,163,168,173,178,183,188,193,198,203,208,213,218,223,228,233,238,243,248],{"id":154,"version":155,"summary_zh":156,"released_at":157},145519,"v1.5.0","# 版本更新说明\n \n- 升级至最新的 Gio 0.8.0 版本\n- 性能优化\n- 代码清理与重构\n- 修复了启用调试掩码时的性能回归问题\n- 修复了接缝位移问题\n- 禁止调整 GUI 窗口大小\n- 将大量代码段适配到后续 Go 版本引入的新特性\n- 更新了测试用例\n- 移除了 vendor 依赖\n","2025-04-27T14:35:51",{"id":159,"version":160,"summary_zh":161,"released_at":162},145520,"v1.4.6","## 发布变更\n \n- 扩展了 `imop` 包，新增功能和测试用例\n- 为 GUI 控件添加了自定义主题\n- 更新 CI 流水线以支持 Go 1.19\n- 修复了拼写错误\n- 其他小幅改动","2023-02-20T10:29:16",{"id":164,"version":165,"summary_zh":166,"released_at":167},145521,"v1.4.5","## 版本更新内容\n \n- **新增 GUI 调试选项** #88\n- 实现了 Porter-Duff 复合变换和混合模式\n- 修复使用蒙版时垂直方向图像缩放的问题 #86\n- 修复垂直方向图像缩放时人脸检测失效的问题\n- 处理在启用人脸检测且无法在不使检测到的人脸变形的情况下进行缩放的情形 #67\n- 修复在启用 GUI 模式和接缝调试选项时，视网膜显示屏上出现的像素到 DP 转换问题","2022-10-24T08:44:23",{"id":169,"version":170,"summary_zh":171,"released_at":172},145522,"v1.4.4","## 版本更新说明\n\n- 修复了使用人脸检测 API 时出现的无效内存地址问题 #75\n- GUI 改进：在调整窗口大小操作完成后发出提示信号。\n- 当显示静态消息时，更改 GUI 背景颜色。","2022-04-05T11:57:21",{"id":174,"version":175,"summary_zh":176,"released_at":177},145523,"v1.4.3","## 版本更新说明\n\n- 升级以支持 Go 1.18 引入的泛型。\n- 进行了一些不影响整体可用性的代码小改动。","2022-03-20T04:34:27",{"id":179,"version":180,"summary_zh":181,"released_at":182},145524,"v1.4.2","## 版本更新说明\n\n- 修复了图像放大时出现的接缝扩散问题 #74\n- 当图像同时进行水平和垂直缩放时，禁用预览模式\n- 调整了默认标志值，以获得更好的效果","2022-02-07T15:13:50",{"id":184,"version":185,"summary_zh":186,"released_at":187},145525,"v1.4.1","## 版本更新说明\n\n- 修复了 GUI 调试模式。现在不再将接缝编码到图像中，而是使用单独的 GUI 控件来指示应移除或添加哪条接缝。\n- 修复了与 macOS 相关的 GUI 问题。\n- 支持使用二进制文件掩码来保护和移除图像补丁（`-mask`、`-rmask`）。\n- 扩展了支持的命令行选项，新增了接缝的 `color` 和 `shape` 标志。","2022-01-08T05:40:23",{"id":189,"version":190,"summary_zh":191,"released_at":192},145526,"v1.4.0","## 发布变更\n\n- 实现了 GUI 进度指示器\n- 通过在每次迭代中不再将图像转换为灰度模式，显著提升了性能\n- 通过将人脸检测尝试次数限制在指定阈值内，优化了启用人脸检测时的性能\n- 增加了新的测试和基准测试\n- 修复了垂直缩放问题\n- 修复了垂直缩放时人脸检测缺失的问题\n- 修复了正方形图像的缩放问题\n- 支持在 GIF 输出中放大图像","2021-12-03T07:58:59",{"id":194,"version":195,"summary_zh":196,"released_at":197},145527,"v1.3.3","## 版本更新说明\n\n* 改进了图像在同时进行水平和垂直缩放时的生成质量。这一改进是通过一种合并技术实现的，即缩小和放大操作不再依次执行，而是并行触发。例如，在旧版本中，如果需要将图像垂直放大、水平缩小，会先调用放大操作，待其完成后再调用缩小操作。由于水平和垂直的拼接线没有交错，最终效果并不理想。而在当前版本中，缩小和放大操作会交错执行。\n* 此外，还覆盖了所有可能的缩小和放大组合，无论是否使用百分比标志。\n* 代码重构及文档优化\n* 更新了支持的命令。","2021-10-10T08:02:57",{"id":199,"version":200,"summary_zh":201,"released_at":202},145528,"v1.3.2","## 发布变更\r\n\r\n* 将级联分类器嵌入到二进制文件中。这是 Go 1.16 的一项便捷功能，因为在使用 `-face` 选项时，我们无需再单独提供级联分类器，因为它会直接嵌入到生成的二进制文件中。","2021-06-02T15:10:34",{"id":204,"version":205,"summary_zh":206,"released_at":207},145529,"v1.3.1","## Release changes\r\n\r\n* speed improvement when using the face detection flag (#62)\r\n* detect the content type of the binary classifier prior using it. Signal error in case the file provided is not a binary file.\r\n* other minor improvements and code refactoring","2021-05-28T12:54:36",{"id":209,"version":210,"summary_zh":211,"released_at":212},145530,"v1.3.0","## Release changes\r\n\r\n* consistent speedup by processing whole image libraries concurrently\r\n* pipe in-out\r\n* improved visual appearance of the CLI\r\n* improved process indicator\r\n* process image from the internet without downloading it","2021-05-24T13:29:08",{"id":214,"version":215,"summary_zh":216,"released_at":217},145531,"v1.2.6","## Release changes\r\n\r\n* Fixed huge memory allocation on processing #59 \r\n","2020-07-02T08:58:07",{"id":219,"version":220,"summary_zh":221,"released_at":222},145532,"v1.2.5","## Release changes\r\n\r\n* Added support for pipe commands #43","2020-02-03T08:02:02",{"id":224,"version":225,"summary_zh":226,"released_at":227},145533,"v1.2.4","## Release changes\r\n\r\n* Fixed square option issue #55 ","2019-11-18T09:58:55",{"id":229,"version":230,"summary_zh":231,"released_at":232},145534,"v1.2.3","## Release changes\r\n\r\n* Upgrade to Pigo [v1.2.0](https:\u002F\u002Fgithub.com\u002Fesimov\u002Fpigo\u002Freleases\u002Ftag\u002Fv1.2.0)\r\n* Fixed unused `fmt` import","2019-09-11T12:29:57",{"id":234,"version":235,"summary_zh":236,"released_at":237},145535,"v1.2.2","## Release changes\r\n* Fixing square option usage in case the source image is a square.","2019-09-11T10:42:34",{"id":239,"version":240,"summary_zh":241,"released_at":242},145536,"v1.2.1","## Release changes\r\n* Increased performance by using the scale function if needed\r\n* Fixed index out of range error when using the scale option without specifying the width or height\r\n* Support for multiple output image formats","2019-04-25T09:29:51",{"id":244,"version":245,"summary_zh":246,"released_at":247},145537,"v1.2.0","## Release changes\r\n* Using Pigo [v1.1.0](https:\u002F\u002Fgithub.com\u002Fesimov\u002Fpigo\u002Freleases\u002Ftag\u002Fv1.1.0) for face detection\r\n* Support for rotated faces detection\r\n* Include `angle` parameter into the supported arguments","2019-01-17T11:23:48",{"id":249,"version":250,"summary_zh":251,"released_at":252},145538,"1.1.1","## Release changes\r\n* Limit usage of scale option only for image reduction","2018-10-31T14:05:15"]