Skip to content

PixelPhantomX is an image obfuscation tool designed to disrupt AI model training by injecting adversarial noise, distortions, and metadata poisoning to protect artists' work from unauthorized scraping and exploitation.

License

Notifications You must be signed in to change notification settings

AdityaBhatt3010/PixelPhantomX

Repository files navigation

PixelPhantomX: Ghost images to confuse AI models

PixelPhantomX is a powerful image obfuscation tool designed to generate ghost images that confuse AI models. In an era where generative AI scrapes and repurposes artwork without the consent of creators, this tool acts as a defensive mechanism. By applying various adversarial techniques, such as noise injection, color-space manipulation, edge distortion, and watermarking, PixelPhantomX helps protect digital images from unauthorized AI training and exploitation.

Image

Features

  • Adversarial Noise Injection (Inspired by Glaze & Nightshade)
  • Customizable Noise Levels (Min/Max)
  • Watermarking (Visible & Invisible Steganographic Protection)
  • Edge Distortion for AI Confusion
  • Metadata Poisoning to mislead AI training
  • Command-line Interface for easy use

Installation

Direct Install from PyPI

pip install PixelPhantomX

Alternatively, install via setup.py:

git clone https://github.com/AdityaBhatt3010/PixelPhantomX
python setup.py install

Otherwise, install the required dependencies:

git clone https://github.com/AdityaBhatt3010/PixelPhantomX
pip install -r requirements.txt

Repository Structure

PixelPhantomX/
├── PixelPhantomX.py               # Main script: runs full image protection pipeline
├── PixelPhantomX_Minimal.py      # Lightweight version with core functionality
├── Img_Poision.py                # Core image poisoning logic
├── RP_Struct.py                  # Runtime parameter or response structure definitions
├── utilities.py                  # Utility functions for adversarial techniques
│
├── README.md                     # Project overview and usage instructions
├── Requirements.txt              # Python dependencies
├── setup.py                      # Setup script for installation
├── pyproject.toml                # Project metadata for build tools
│
├── LICENSE                       # License information
├── .gitignore                    # Git ignored files
├── .gitattributes                # Git settings (e.g. end-of-line normalization)
│
├── /images/                      # Example input/output images and UI assets
│   ├── Input.png
│   ├── Output.jpg
│   ├── PixelPhantomX_Run.png
│   └── Help.png
│
└── .github/
    └── workflows/
        └── python-app.yml        # GitHub Actions workflow for linting and testing

Usage

Run the tool via the command line:

python PixelPhantomX.py -iP input_image_path -n noise -oP output_image_path -w watermark_text

Parameters:

Parameter Description
-iP Path to the input image (with extension)
-n Noise level (Min or Max)
-oP Output image path (without extension)
-w Custom watermark text (default: Protected)

Example:

python PixelPhantomX.py -iP Input.png -oP Output -n Min -w AdityaBhatt3010

Help Menu

To view available commands, run:

python PixelPhantomX.py -h

Alternative Usage - Interactive Mode

For a guided, interactive experience instead of command-line arguments, use:

python PixelPhantomX_Minimal.py

Screenshots

  • Help Prompt Screenshot

    python PixelPhantomX.py -h

    Image

  • Run Code Example:

    python PixelPhantomX.py -iP Input.png -oP Output -n Min -w AdityaBhatt3010

    Image

  • Input Image Screenshot
    Image

  • Output Image Screenshot
    Image

Contributing

Pull requests are welcome! For major changes, please open an issue first to discuss what you'd like to change.


Disclaimer:

This tool is intended for ethical use only. The author is not responsible for any misuse of this software.

About

PixelPhantomX is an image obfuscation tool designed to disrupt AI model training by injecting adversarial noise, distortions, and metadata poisoning to protect artists' work from unauthorized scraping and exploitation.

Resources

License

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published