[{"data":1,"prerenderedAt":-1},["ShallowReactive",2],{"project-70757":3},{"id":4,"name":5,"fullName":6,"owner":7,"repo":5,"description":8,"homepage":9,"htmlUrl":10,"language":11,"languages":10,"totalLinesOfCode":10,"stars":12,"forks":13,"watchers":14,"openIssues":15,"contributorsCount":16,"subscribersCount":16,"size":16,"stars1d":17,"stars7d":18,"stars30d":19,"stars90d":16,"forks30d":16,"starsTrendScore":20,"compositeScore":21,"rankGlobal":10,"rankLanguage":10,"license":22,"archived":23,"fork":23,"defaultBranch":24,"hasWiki":25,"hasPages":25,"topics":26,"createdAt":10,"pushedAt":10,"updatedAt":31,"readmeContent":32,"aiSummary":33,"trendingCount":16,"starSnapshotCount":16,"syncStatus":34,"lastSyncTime":35,"discoverSource":36},70757,"blind_watermark","guofei9987\u002Fblind_watermark","guofei9987","Blind&Invisible Watermark ，图片盲水印，提取水印无须原图！","https:\u002F\u002Fblindwatermark.github.io\u002Fblind_watermark\u002F#\u002Fen\u002F",null,"Python",13124,1330,63,44,0,172,189,323,516,44.37,"MIT License",false,"master",true,[27,28,29,30],"blind-watermark","image-processing","watermark","watermark-image","2026-06-12 02:02:42","\n\n\n# blind-watermark\n\nBlind watermark based on DWT-DCT-SVD.\n\n\n[![PyPI](https:\u002F\u002Fimg.shields.io\u002Fpypi\u002Fv\u002Fblind_watermark)](https:\u002F\u002Fpypi.org\u002Fproject\u002Fblind_watermark\u002F)\n[![Build Status](https:\u002F\u002Ftravis-ci.com\u002Fguofei9987\u002Fblind_watermark.svg?branch=master)](https:\u002F\u002Ftravis-ci.com\u002Fguofei9987\u002Fblind_watermark)\n[![codecov](https:\u002F\u002Fcodecov.io\u002Fgh\u002Fguofei9987\u002Fblind_watermark\u002Fbranch\u002Fmaster\u002Fgraph\u002Fbadge.svg)](https:\u002F\u002Fcodecov.io\u002Fgh\u002Fguofei9987\u002Fblind_watermark)\n[![License](https:\u002F\u002Fimg.shields.io\u002Fpypi\u002Fl\u002Fblind_watermark.svg)](https:\u002F\u002Fgithub.com\u002Fguofei9987\u002Fblind_watermark\u002Fblob\u002Fmaster\u002FLICENSE)\n![Python](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fpython->=3.5-green.svg)\n![Platform](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fplatform-windows%20|%20linux%20|%20macos-green.svg)\n[![stars](https:\u002F\u002Fimg.shields.io\u002Fgithub\u002Fstars\u002Fguofei9987\u002Fblind_watermark.svg?style=social)](https:\u002F\u002Fgithub.com\u002Fguofei9987\u002Fblind_watermark\u002F)\n[![fork](https:\u002F\u002Fimg.shields.io\u002Fgithub\u002Fforks\u002Fguofei9987\u002Fblind_watermark?style=social)](https:\u002F\u002Fgithub.com\u002Fguofei9987\u002Fblind_watermark\u002Ffork)\n[![Downloads](https:\u002F\u002Fpepy.tech\u002Fbadge\u002Fblind-watermark)](https:\u002F\u002Fpepy.tech\u002Fproject\u002Fblind-watermark)\n[![Discussions](https:\u002F\u002Fimg.shields.io\u002Fbadge\u002Fdiscussions-green.svg)](https:\u002F\u002Fgithub.com\u002Fguofei9987\u002Fblind_watermark\u002Fdiscussions)\n\u003Ca href=\"https:\u002F\u002Fhellogithub.com\u002Frepository\u002Fguofei9987\u002Fblind_watermark\" target=\"_blank\">\u003Cimg src=\"https:\u002F\u002Fabroad.hellogithub.com\u002Fv1\u002Fwidgets\u002Frecommend.svg?rid=3834302ff46a40f188a651ef8bd26ff5&claim_uid=se0WHo8cbiLv2w1&theme=small\" alt=\"Featured｜HelloGitHub\" \u002F>\u003C\u002Fa>\n\n- **Documentation:** [https:\u002F\u002FBlindWatermark.github.io\u002Fblind_watermark\u002F#\u002Fen\u002F](https:\u002F\u002FBlindWatermark.github.io\u002Fblind_watermark\u002F#\u002Fen\u002F)\n- **文档：** [https:\u002F\u002FBlindWatermark.github.io\u002Fblind_watermark\u002F#\u002Fzh\u002F](https:\u002F\u002FBlindWatermark.github.io\u002Fblind_watermark\u002F#\u002Fzh\u002F)  \n- **中文 readme** [README_cn.md](README_cn.md)\n- **Source code:** [https:\u002F\u002Fgithub.com\u002Fguofei9987\u002Fblind_watermark](https:\u002F\u002Fgithub.com\u002Fguofei9987\u002Fblind_watermark)\n\n\n\n# install\n```bash\npip install blind-watermark\n```\n\nFor the current developer version:\n```bach\ngit clone git@github.com:guofei9987\u002Fblind_watermark.git\ncd blind_watermark\npip install .\n```\n\n# How to use\n\n\n## Use in bash\n\n\n```bash\n# embed watermark into image:\nblind_watermark --embed --pwd 1234 examples\u002Fpic\u002Fori_img.jpeg \"watermark text\" examples\u002Foutput\u002Fembedded.png\n# extract watermark from image:\nblind_watermark --extract --pwd 1234 --wm_shape 111 examples\u002Foutput\u002Fembedded.png\n```\n\n\n\n## Use in Python\n\nOriginal Image + Watermark = Watermarked Image\n\n![origin_image](docs\u002F原图.jpeg) + '@guofei9987 开源万岁！' = ![打上水印的图](docs\u002F打上水印的图.jpg)\n\n\nSee the [codes](\u002Fexamples\u002Fexample_str.py)\n\nEmbed watermark:\n```python\nfrom blind_watermark import WaterMark\n\nbwm1 = WaterMark(password_img=1, password_wm=1)\nbwm1.read_img('pic\u002Fori_img.jpg')\nwm = '@guofei9987 开源万岁！'\nbwm1.read_wm(wm, mode='str')\nbwm1.embed('output\u002Fembedded.png')\nlen_wm = len(bwm1.wm_bit)\nprint('Put down the length of wm_bit {len_wm}'.format(len_wm=len_wm))\n```\n\nExtract watermark:\n```python\nbwm1 = WaterMark(password_img=1, password_wm=1)\nwm_extract = bwm1.extract('output\u002Fembedded.png', wm_shape=len_wm, mode='str')\nprint(wm_extract)\n```\nOutput:\n>@guofei9987 开源万岁！\n\n### attacks on Watermarked Image\n\n\n|attack method|image after attack|extracted watermark|\n|--|--|--|\n|Rotate 45 Degrees|![旋转攻击](docs\u002F旋转攻击.jpg)|'@guofei9987 开源万岁！'|\n|Random crop|![截屏攻击](docs\u002F截屏攻击2_还原.jpg)|'@guofei9987 开源万岁！'|\n|Masks| ![多遮挡攻击](docs\u002F多遮挡攻击.jpg) |'@guofei9987 开源万岁！'|\n|Vertical cut|![横向裁剪攻击](docs\u002F横向裁剪攻击_填补.jpg)|'@guofei9987 开源万岁！'|\n|Horizontal cut|![纵向裁剪攻击](docs\u002F纵向裁剪攻击_填补.jpg)|'@guofei9987 开源万岁！'|\n|Resize|![缩放攻击](docs\u002F缩放攻击.jpg)|'@guofei9987 开源万岁！'|\n|Pepper Noise|![椒盐攻击](docs\u002F椒盐攻击.jpg)|'@guofei9987 开源万岁！'|\n|Brightness 10% Down|![亮度攻击](docs\u002F亮度攻击.jpg)|'@guofei9987 开源万岁！'|\n\n\n\n\n\n\n### embed images\n\nembed watermark:\n```python\nfrom blind_watermark import WaterMark\n\nbwm1 = WaterMark(password_wm=1, password_img=1)\n# read original image\nbwm1.read_img('pic\u002Fori_img.jpg')\n# read watermark\nbwm1.read_wm('pic\u002Fwatermark.png')\n# embed\nbwm1.embed('output\u002Fembedded.png')\n```\n\n\nExtract watermark:\n```python\nbwm1 = WaterMark(password_wm=1, password_img=1)\n# notice that wm_shape is necessary\nbwm1.extract(filename='output\u002Fembedded.png', wm_shape=(128, 128), out_wm_name='output\u002Fextracted.png', )\n```\n\n\n|attack method|image after attack|extracted watermark|\n|--|--|--|\n|Rotate 45 Degrees|![旋转攻击](docs\u002F旋转攻击.jpg)|![](docs\u002F旋转攻击_提取水印.png)|\n|Random crop|![截屏攻击](docs\u002F截屏攻击2_还原.jpg)|![多遮挡_提取水印](docs\u002F多遮挡攻击_提取水印.png)|\n|Mask| ![多遮挡攻击](docs\u002F多遮挡攻击.jpg) |![多遮挡_提取水印](docs\u002F多遮挡攻击_提取水印.png)|\n\n\n### embed array of bits\n\nSee it [here](\u002Fexamples\u002Fexample_bit.py)\n\n\nAs demo, we embed 6 bytes data:\n```python\nwm = [True, False, True, True, True, False]\n```\n\nEmbed:\n```python\nfrom blind_watermark import WaterMark\n\nbwm1 = WaterMark(password_img=1, password_wm=1)\nbwm1.read_ori_img('pic\u002Fori_img.jpg')\nbwm1.read_wm([True, False, True, True, True, False], mode='bit')\nbwm1.embed('output\u002Fembedded.png')\n```\n\nExtract:\n```python\nbwm1 = WaterMark(password_img=1, password_wm=1, wm_shape=6)\nwm_extract = bwm1.extract('output\u002F打上水印的图.png', mode='bit')\nprint(wm_extract)\n```\nNotice that `wm_shape` (shape of watermark) is necessary\n\nThe output `wm_extract` is an array of float. set a threshold such as 0.5.\n\n\n# Concurrency\n\n```python\nWaterMark(..., processes=None)\n```\n- `processes` number of processes, can be integer. Default `None`, which means using all processes.  \n\n## Related Project\n\n- text_blind_watermark (Embed message into text): [https:\u002F\u002Fgithub.com\u002Fguofei9987\u002Ftext_blind_watermark](https:\u002F\u002Fgithub.com\u002Fguofei9987\u002Ftext_blind_watermark)  \n- HideInfo（hide as image, hide as sounds, hide as text）：[https:\u002F\u002Fgithub.com\u002Fguofei9987\u002FHideInfo](https:\u002F\u002Fgithub.com\u002Fguofei9987\u002FHideInfo)\n","blind-watermark 是一个基于 Python 的图片盲水印工具，能够在不依赖原图的情况下提取嵌入的水印。其核心功能是通过 DWT-DCT-SVD 算法实现水印的嵌入与提取，支持文本和图像类型的水印。该工具具有良好的跨平台兼容性（Windows、Linux 和 macOS），并且提供了简单的命令行接口及 Python API 便于集成到不同的应用场景中。适用于需要版权保护或信息隐藏的数字媒体处理场合，如在线内容发布、数字艺术品管理和文档安全等领域。",2,"2026-06-11 03:34:00","high_star"]