|
|
--- |
|
|
tags: |
|
|
- model_hub_mixin |
|
|
- pytorch_model_hub_mixin |
|
|
- watermarking |
|
|
- latent-diffusion |
|
|
- stable-signature |
|
|
- watermark-extraction |
|
|
- computer-vision |
|
|
- research |
|
|
- non-commercial |
|
|
- pytorch |
|
|
license: cc-by-nc-4.0 |
|
|
--- |
|
|
|
|
|
# **MsgExtractor - Stable Signature Decoder** |
|
|
|
|
|
**A version of the Stable Signature decoder from the Meta AI project “Stable Signature: Rooting Watermarks in Latent Diffusion Models.”** |
|
|
|
|
|
--- |
|
|
|
|
|
## Model Summary |
|
|
|
|
|
* **Model Type:** Custom PyTorch Model |
|
|
* **Task:** Watermark extraction from watermarked images |
|
|
* **Source:** Derived from [facebookresearch/stable_signature](https://github.com/facebookresearch/stable_signature) |
|
|
* **License:** **CC-BY-NC 4.0** (Attribution + Non-Commercial) |
|
|
* **Framework:** PyTorch |
|
|
* **Weights:** Ported from the original TorchScript decoder |
|
|
* **Architecture:** |
|
|
|
|
|
* `HiddenDecoder(num_blocks, num_bits, channels, redundancy)` |
|
|
* `MsgExtractor(hidden_decoder, in_features, out_features)` |
|
|
* **Status:** Research-only, non-commercial |
|
|
|
|
|
### **Load the model** |
|
|
|
|
|
```python |
|
|
from modeling_msg_extractor import MsgExtractor |
|
|
import torch |
|
|
|
|
|
model = MsgExtractor.from_pretrained("ESmike/StableSignatureDecoder") |
|
|
model.eval() |
|
|
|
|
|
img = torch.randn(1, 3, 256, 256) # example input |
|
|
bits = model(img) |
|
|
print(bits.shape) |
|
|
``` |
|
|
|
|
|
### Citation |
|
|
|
|
|
If you use this model, you must cite the original Stable Signature paper: |
|
|
|
|
|
```bibtex |
|
|
@inproceedings{Fernandez2023StableSignature, |
|
|
title={The Stable Signature Rooting Watermarks in Latent Diffusion Models}, |
|
|
author={Fernandez, Pierre and Chappelier, Vivien and Nguyen-Hong, Son}, |
|
|
year={2023}, |
|
|
institution={Meta AI}, |
|
|
note={Original implementation at https://github.com/facebookresearch/stable_signature} |
|
|
} |
|
|
``` |
|
|
|
|
|
|