https://github.com/davidramosarchilla/colorizing-images
An implementation of the Pix2Pix paper for image colorization using PyTorch.
https://github.com/davidramosarchilla/colorizing-images
colorization computer-vision gan google-colab ia pytorch
Last synced: about 2 months ago
JSON representation
An implementation of the Pix2Pix paper for image colorization using PyTorch.
- Host: GitHub
- URL: https://github.com/davidramosarchilla/colorizing-images
- Owner: DavidRamosArchilla
- License: mit
- Created: 2024-12-01T11:52:29.000Z (over 1 year ago)
- Default Branch: main
- Last Pushed: 2024-12-01T12:46:52.000Z (over 1 year ago)
- Last Synced: 2025-03-29T07:44:59.834Z (over 1 year ago)
- Topics: colorization, computer-vision, gan, google-colab, ia, pytorch
- Language: Jupyter Notebook
- Homepage:
- Size: 3.15 MB
- Stars: 2
- Watchers: 1
- Forks: 0
- Open Issues: 0
-
Metadata Files:
- Readme: README.md
- License: LICENSE
Awesome Lists containing this project
README
# Image Colorization with Pix2Pix
An implementation of the [Pix2Pix](https://arxiv.org/abs/1611.07004) paper for image colorization using PyTorch.
Try a trained on Google Colab:
## Overview
This project applies conditional adversarial networks to colorize grayscale images. The model learns to translate grayscale images into colorful ones by training on paired datasets.
## Features
- Implemented in PyTorch
- Supports custom datasets
- Includes a training script and a jupyter notebook on google colab to test a trained model hosted on huggingface model hub.
- Data augmentation and preprocessing
- Logging to tensorboard
## Training details
It has been trained with 12000 images from [COCO 2017 dataset](https://cocodataset.org/) during 150 epochs with batch size 16 and learning rate 2e-4 for both generator and discriminator. Data augmentation is done by randomly flipping horizontally the images.
## Installation
```bash
git clone https://github.com/yourusername/colorizing_images.git
cd colorizing_images
pip install -r requirements.txt
```
## Usage
### Training
```bash
python train.py
```
## Results
Here are some examples of colorized images, the upper row are the generations of the model:


## Acknowledgments
- The original [Pix2Pix paper](https://arxiv.org/abs/1611.07004)
- [PyTorch](https://pytorch.org/) framework
- [HuggingFace🤗](https://huggingface.co/) Model Hub
## License
This project is licensed under the MIT License.