PIL × DAT - Pillow extension for AI-based image upscaling.
Project description
PIL × DAT - Pillow extension for AI-based image upscaling.
Installation
For PyPI:
pip install pillow-dat
For Conda:
conda install -c conda-forge pillow-dat
Get started
-
- Download
DAT_light_x2.pth
model weight from Google Drive. We highly recommend utilizingDAT_light_x*.pth
models due to their lightweight design and exceptional speed.
- Download
-
- 🎉 Then you are all set to upscale your images:
from PIL.Image import open
from PIL_DAT.Image import upscale
image = open("./lumine.png")
image = upscale(lumine_image, "./DAT_light_x2.pth", 2)
image.show()
Contribution
Please install Miniconda.
Please install VSCode extensions:
- Black Formatter
- isort
- Python
- Pylance
To install dependencies on a given pillow-dat
Python environnement:
conda env create --file environment.yml
To update this environment:
conda env update --file environment.yml --prune
To run unit tests:
python -m pytest
Acknowledgement
This library is founded upon the pioneering research paper, "Dual Aggregation Transformer for Image Super-Resolution".
@inproceedings{chen2023dual,
title={Dual Aggregation Transformer for Image Super-Resolution},
author={Chen, Zheng and Zhang, Yulun and Gu, Jinjin and Kong, Linghe and Yang, Xiaokang and Yu, Fisher},
booktitle={ICCV},
year={2023}
}
Project details
Release history Release notifications | RSS feed
Download files
Download the file for your platform. If you're not sure which to choose, learn more about installing packages.
Source Distribution
pillow_dat-0.1.0.tar.gz
(35.7 kB
view details)
Built Distribution
File details
Details for the file pillow_dat-0.1.0.tar.gz
.
File metadata
- Download URL: pillow_dat-0.1.0.tar.gz
- Upload date:
- Size: 35.7 kB
- Tags: Source
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.2 CPython/3.12.2 Windows/11
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 8f43d1cce01878ef27d809218443f85e7e2462eb573aefcd52cfa1631766d88b |
|
MD5 | 5b9eed7adf3d4d5e3d7a99be8ff34807 |
|
BLAKE2b-256 | 2b86f96bf1afd16010c635c150c12dbab003bfb13286064f92c53e9f6ba6f7b0 |
File details
Details for the file pillow_dat-0.1.0-py3-none-any.whl
.
File metadata
- Download URL: pillow_dat-0.1.0-py3-none-any.whl
- Upload date:
- Size: 14.2 kB
- Tags: Python 3
- Uploaded using Trusted Publishing? No
- Uploaded via: poetry/1.8.2 CPython/3.12.2 Windows/11
File hashes
Algorithm | Hash digest | |
---|---|---|
SHA256 | 6c50e2d7ee214cefa85703320e96dd96d8788171efe42eccec418766a87791c6 |
|
MD5 | 921a1336baffd530dcdb467fee3e08f2 |
|
BLAKE2b-256 | 564736c0f04dad090599993a4f5a5e49b8e80ecfa78c68a6c1e4ba015b353acc |