Skip to content

Navigation Menu

Sign in
Appearance settings

Search code, repositories, users, issues, pull requests...

Provide feedback

We read every piece of feedback, and take your input very seriously.

Saved searches

Use saved searches to filter your results more quickly

Sign up
Appearance settings

Releases: aloshdenny/reverse-SynthID

v4

23 Apr 20:48
@aloshdenny aloshdenny
302f7c7
This commit was created on GitHub.com and signed with GitHub’s verified signature.
GPG key ID: B5690EEEBB952194
Verified
Learn about vigilant mode.

Choose a tag to compare

v4 Pre-release
Pre-release

What's New in V4

V4 is a complete rebuild of the watermark-dissolving pipeline, adding multi-model support, a richer codebook, and a new all-in-one attack that defeats the SynthID detector on both gemini-3.1-flash-image-preview and nano-banana-pro-preview after six rounds of iterative adversarial refinement.


The Breakthrough: Round-06 All-in-One Attack ✓

Previous rounds (spectral subtraction, blog-guided bin targeting, denoise-residual phase, VAE re-generation) all failed. Round 06 works by stacking every SynthID failure mode the Gemini app itself documents into a single 7-stage pipeline:

  1. VAE round-trip (Stable Diffusion sd-vae-ft-mse) — projects the image off the natural-image manifold the SynthID decoder was never trained against (Gowal et al. 2026 §6.1)
  2. Elastic deformation — smooth low-frequency random warp field that fragments the watermark's spatial phase consensus, simulating the "collage effect" Gemini's own help text identifies as a detection failure
  3. Global geometric combo — rotation + zoom + shift in one affine warp
  4. Resize-squeeze — AREA downsample → LANCZOS upsample, erases sub-pixel watermark info
  5. Color-contrast nudge — brightness / saturation / hue micro-shift
  6. Residual-phase FFT subtraction — blog-universal + codebook-harvested carrier bins
  7. JPEG chain + luma noise + bilateral filter

Two presets: final (balanced) and nuke (maximum strength). Output is visually indistinguishable from the original.


New: SpectralCodebookV4

  • Multi-model: separate profiles for gemini-3.1-flash-image-preview and nano-banana-pro-preview
  • Multi-color consensus: 6 solid-color backgrounds (black, white, blue, green, red, gray) per model per resolution — only bins with phase-locked across all colors are treated as carriers
  • 7 resolutions ×ばつ 2 models = 14 profiles, covering all common Gemini output sizes
  • Format v5: LZMA-compressed, int8 phase, uint8 mag/cw, sparse-zeroed below the 0.55 coherence threshold — 221 MB → 24 MB (89% reduction, lossless for the bypass)

⬇️ Download spectral_codebook_v4.npz from the release assets and place it in artifacts/.


New Files

File Purpose
src/extraction/synthid_bypass_v4.py Core codebook + all bypass methods
src/extraction/vae_regen.py SD-VAE re-generation stage (MPS / CUDA / CPU)
scripts/build_codebook_v4.py Build a codebook from the hierarchical dataset
scripts/dissolve_batch.py Run final / nuke presets over a folder
scripts/calibrate_from_feedback.py Update carrier weights from detection feedback

Quickstart

pip install torch diffusers safetensors accelerate opencv-python numpy scipy
python scripts/dissolve_batch.py \
 --input ./watermarked/ \
 --output ./cleaned/ \
 --codebook artifacts/spectral_codebook_v4.npz \
 --model gemini-3.1-flash-image-preview \
 --strengths final nuke
Loading
mike1858 and samuelxu-007 reacted with thumbs up emoji mike1858 and samuelxu-007 reacted with laugh emoji mike1858 and samuelxu-007 reacted with hooray emoji mike1858 and samuelxu-007 reacted with heart emoji mike1858 reacted with rocket emoji mike1858 and samuelxu-007 reacted with eyes emoji
2 people reacted

v3.1

21 Apr 17:12
@aloshdenny aloshdenny
93cf20d
This commit was created on GitHub.com and signed with GitHub’s verified signature.
GPG key ID: B5690EEEBB952194
Verified
Learn about vigilant mode.

Choose a tag to compare

v3.1 Pre-release
Pre-release

What's Changed

  • Fix multiple bugs in extraction pipeline by @hobostay in #13
  • Add 1062 reference images at 2 new resolutions + expanded codebook by @BensonRen in #14
  • Add 93 black reference images (gemini_black_nb_pro) by @mrbeandev in #17
  • Fix codebook loading error when .npz path is passed to extractor by @mrbeandev in #18
  • Migrate reference images to Hugging Face, remove from git by @mrbeandev in #22
  • Fix detection: empirically verified carrier frequencies by @mrbeandev in #23

New Contributors

Full Changelog: https://github.com/aloshdenny/reverse-SynthID/commits/v3

Contributors

BensonRen, mrbeandev, and hobostay
Loading
mike1858 and PACHAKUTlQ reacted with rocket emoji
2 people reacted

AltStyle によって変換されたページ (->オリジナル) /