You can download the latest version of the plugin from the GitHub Releases page.
gimp-segany-gimp3.zip: For GIMP 3Download the zip file and follow the installation instructions below.
This GIMP plugin integrates with Meta's AI-based tool Segment Anything, which enables you to effortlessly isolate objects within raster images directly from GIMP.
This project provides a plugin that supports both Segment Anything 1 (SAM1) and Segment Anything 2 (SAM2).
gimp-segany-gimp3.zip.plug-ins folder. This will create a seganyplugin directory with the plugin files inside.seganyplugin directory.You can find GIMP's user plugin location in the Edit > Preferences menu under the Folders section. Here are the default locations for each operating system:
C:\Users\[YourUsername]\AppData\Roaming\GIMP\3.0\plug-ins\~/.config/GIMP/3.0/plug-ins/~/Library/Application Support/GIMP/3.0/plug-ins/After extracting, ensure the plugin script is executable (on Linux and macOS).
You need to install the backend for the Segment Anything model you want to use. The plugin can use either SAM1 or SAM2.
You will get the detailed installation instructions about installing Segment Anything 2 on your platform on Meta's github site: https://github.com/facebookresearch/segment-anything-2.
Prerequisites: - Python 3.10 or higher - PyTorch 2.3.1 or higher
Installation Steps:
1. Clone the repository:
bash
git clone https://github.com/facebookresearch/segment-anything-2.git
2. Navigate to the directory and install the package:
bash
cd segment-anything-2 && pip install -e .
3. Download a model checkpoint (e.g., Tiny, Small, Base Plus, Large).
4. Ensure the segment-anything-2 directory is in your PYTHONPATH.
You will get the detailed installation instructions about installing Segment Anything on your platform on Meta's github site: https://github.com/facebookresearch/segment-anything.
Installation Steps:
1. Clone the repository:
bash
git clone https://github.com/facebookresearch/segment-anything.git
2. Navigate to the directory and install the package:
bash
cd segment-anything && pip install -e .
3. Download a model checkpoint (e.g., vit_h, vit_l, vit_b).
4. Ensure the segment-anything directory is in your PYTHONPATH.
Perform a quick check to ensure your Segment Anything installation is working properly. Open a console and change directory to your GIMP plugin folder.
For SAM2 model:
/path/to/python3/python ./seganybridge.py sam2_hiera_large /path/to/checkpoint/model/sam2_hiera_large.pth
For SAM1 model:
/path/to/python3/python ./seganybridge.py vit_h /path/to/checkpoint/model/sam_vit_h_4b8939.pth
A "Success!!" or "Success!" message indicates a successful installation.
Plugin UI:
Auto to infer from the checkpoint filename (sam_ prefix for SAM1, sam2 for SAM2)..pth or .safetensors).These options are only available when using a SAM2 model with "Auto" segmentation.
$ claude mcp add gimpsegany \
-- python -m otcore.mcp_server <graph>