Skip to content

Unofficial simplified implementation of Painter (2023 CVPR)

Notifications You must be signed in to change notification settings

liushh39/Painter-easy

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

10 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Painter-easy

1. Environment

  • Linux (Recommend)
  • PyTorch >= 1.8.1
  • Other requirements
     pip install -r requirements.txt
    

2. Dataset

You can make your own datasets based on test_img

3. Testing

  1. Download the pre-trained Painter from here. Place it in the same directory with test.py.
  2. Run the following command:
python test.py --task denoise

Tasks include denoise, derain, image_enhancement, instance_segmentation, keypoint_detection, and semantic_segmentation.

  1. If there is an error reported by the torch version of _six.py, try the following solution:
import collections.abc as container_abcs → from torch._six import container_abcs 

4. Citation

@article{Painter,
  title={Images Speak in Images: A Generalist Painter for In-Context Visual Learning},
  author={Wang, Xinlong and Wang, Wen and Cao, Yue and Shen, Chunhua and Huang, Tiejun},
  journal={arXiv preprint arXiv:2212.02499},
  year={2022}
}