OpenViSTAI · Agents · Blockchain · Crypto
Menu
Image & Video AI

Attentiongan

Attentiongan is a Python research implementation of attention-guided generative adversarial networks for unpaired and multi-domain image-to-image translation. Its generator learns foreground and background attention to select generated content in foreground regions while retaining input background information.

Independent OpenViST project profile, based on linked sources.

Attentiongan — OpenViST project profile in Image & Video AI.
OpenViST project illustration. See the linked sources for product details.
Understand the project

Practical overview

When it fits

Use it when you want research code and documented workflows for training, testing or generating images across domains such as horse-to-zebra or map-to-aerial-photo.

Who it is for

  • Computer-vision researchers studying attention-guided image generation.
  • Developers prototyping unpaired or multi-domain image-translation workflows.

Documented uses

  • Experiment with transformations between image domains without paired examples.
  • Prototype multi-domain image translation workflows.
  • Inspect learned attention masks alongside generated translations.
  • Run inference with a downloaded pretrained model.
Before you choose

Requirements & limits

The repository is public. The README states that the code is licensed CC BY-NC-SA 4.0 and released for academic research use; it asks users to contact the project for commercial use.

  • The documented software requirements are Python 3.6.9 or later and PyTorch 0.4.1 or later.
  • Training and inference workflows require datasets; pretrained inference also requires downloading a model.
  • The README specifies an NVIDIA Tesla V100 with 16 GB memory for reproducing the paper’s results.
  • The repository includes scripts for dataset download, training, testing and pretrained-model inference.

Check current requirements in the official documentation. Source-based guidance does not mean OpenViST has run or independently tested this project.

Source-based practical guide

Generate translations with a pretrained model

Prepare the documented prerequisites and run inference using a downloaded pretrained AttentionGAN model.

Before you start

  • Python 3.6.9 or later and PyTorch 0.4.1 or later.
  • Repository dependencies installed with pip or the provided Conda script.
  • A prepared dataset and a downloaded pretrained model.

Steps

  1. Clone the repository and install dependencies using the documented pip requirements file or Conda script.

  2. Prepare a dataset using the provided dataset download script, or obtain the selfie2anime dataset from the README’s linked source.

  3. Download a pretrained model, for example the horse2zebra model, with the provided model-download script.

  4. Run the documented test.py command with the dataset and model settings for inference; results are saved under ./results/.

Expected outcome

Generated image results saved to the results directory.

Guide limitations

  • The documented inference example uses a GPU ID; the README specifies an NVIDIA Tesla V100 with 16 GB memory for reproducing the paper’s results.
  • The repository labels the code for academic research use; commercial use requires contacting the project.
Evidence and transparency

Sources & review

Source record details
Source availability
Active
Sources checked
18 October 2026
Original website title
Ha0Tang/AttentionGAN · Official homepage title · retained in its source language