
批量去水印的軟件github

在 GitHub 上,有許多開源的批量去水印工具和庫,以下是幾個值得關注的資源:1. ImageAI 基于OpenCV的水印去除項目地址: github.com/hea...
在 GitHub 上,有許多開源的批量去水印工具和庫,以下是幾個值得關注的資源:
1. ImageAI 基于OpenCV的水印去除
- 項目地址: github.com/heartexlabs/imageai
- 特點:
- 提供
remove_watermark
方法,支持自動檢測并去除圖片中的水印。 - 支持批量處理(通過遍歷文件夾)。
- 需要安裝 OpenCV 和 Python 3.6+。
- 提供
示例代碼:
```python
from imageai import ImageAI
import os
def remove_watermark(input_path, output_path):
ai = ImageAI(input_path)
results = ai.remove_watermark(input_path)
for r in results:
r.save(output_path + '/' + r.get_file_name())
if name == "main":
input_dir = "input_images/"
output_dir = "output_images/"
os.makedirs(output_dir, exist_ok=True)
for filename in os.listdir(input_dir):
if filename.lower().endswith(('.png', '.jpg', '.jpeg')):
input_path = os.path.join(input_dir, filename)
output_path = os.path.join(output_dir, filename)
remove_watermark(input_path, output_path)
```
本文由德普網于2025-06-02發表在德普網,如有疑問,請聯系我們。
本文鏈接:http://www.wzyaohuidianqi.cn/gong/424949.html
本文鏈接:http://www.wzyaohuidianqi.cn/gong/424949.html
上一篇:百科去水印電腦版,刪除百科全書
下一篇:翰文軟件打印如何去水印
