Skip to content

TimSeizinger/Bokehlicious

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

5 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Bokehlicious:
Photorealistic Bokeh Rendering with Controllable Apertures

Tim Seizinger, Florin-Alexandru Vasluianu, Marcos V. Conde, Zongwei Wu, Radu Timofte

Computer Vision Lab , CAIDAS, University of Wurzburg, Germany

Official Code and Dataset repository of Bokehlicious: Photorealistic Bokeh Rendering with Controllable Apertures

Installation

git clone https://github.com/TimSeizinger/Bokehlicious.git
cd Bokehlicious
pip install -r requirements.txt

Usage

Due to GitHub file size limits, if you want to use any of the large model checkpoints, don't forget to unpack the .zpaq archives!

predict.py lets you run Bokehlicious on a single image. For example:

python predict.py -img_path ./examples/collie.jpg -size small -av 2.8

Here -img_path is the path to the image you want to render, -size is the size of the model you want to use (small or large) and -av is the aperture f-stop to control the strength of bokeh (between 2.0 and 20.0).

Evaluation

This Repository includes evaluation scripts for Bokeh Rendering on our new RealBokeh dataset, as well as EBB! Val294 and EBB400.

Before running the evaluation script you need to download the test set of RealBokeh and copy it to the ./dataset/RealBokeh folder. The same applies to EBB! Val294 and EBB400.

To run the evaluation script use:

python evaluate.py -dataset RealBokeh -size small --save_outputs

Here -dataset is the dataset you want to evaluate on (RealBokeh, RealBokeh_bin, EBB_Val294, EBB400), -size is the size of the model you want to use (small or large) and --save_outputs is a flag to save the rendered images.

RealBokeh Dataset

You can find our RealBokeh Dataset on Huggingface!

Dataset on HF

Citation

If you find our work useful for your research work please cite:

@inproceedings{seizinger2025bokehlicious,
  author    = {Seizinger, Tim and Vasluianu, Florin-Alexandru and Conde, Marcos and Wu, Zongwei and Timofte, Radu},
  title     = {Bokehlicious: Photorealistic Bokeh Rendering with Controllable Apertures},
  booktitle = {ICCV},
  year      = {2025},
}

About

Official Code and Dataset repository of Bokehlicious: Photorealistic Bokeh Rendering with Controllable Apertures

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages