This repository contains the code for our paper:
Point-Pattern Synthesis using Gabor and Random Filters
Xingchang Huang, Pooran Memari, Hans-Peter Seidel, Gurprit Singh
Computer Graphics Forum (Proceedings of EGSR), 2022
For more details, please refer to our project page.
- 31 August 2022: updated project page
- 10 July 2022: added installation guide with CPU
- 27 June 2022: code released
- Python 3.7.9
- Pytorch 1.6.0
- matplotlib
- scipy
- tqdm
- scikit-learn
conda create -n pps python=3.7
conda activate pps
conda install pytorch==1.6.0 torchvision==0.7.0 cudatoolkit=10.1 -c pytorch
pip install matplotlib scipy tqdm
pip install -U scikit-learn
conda create -n pps_cpu python=3.7
conda activate pps_cpu
conda install pytorch==1.6.0 torchvision==0.7.0 -c pytorch
pip install matplotlib scipy tqdm
pip install -U scikit-learn
test_data/init
: initialized poisson disk distributions for different patterns.test_data/testset_point
: exemplar single-class point patternstest_data/testset_disk
: exemplar disk patternstest_data/testset_multiattributes
: exemplar multi-attribute patternssrc
: code
You can simply run a demo by:
cd src
python main.py --logs=run --kernel_sigma1=1.0 --kernel_sigma2=2.6 --test_data=../test_data/testset_point --scene_name=lines
The results
folder will be automatically created and the outputs will be saved in run
folder. Please find more commands in src/scripts/run.sh
. kernel_sigma1, kernel_sigma2
are two hyper-parameters c1, c2
explained in the paper.
Note that the generated results might be close to the ones presented in the paper but not exactly the same, due to the differences between machines.
If you find this code useful please consider citing:
@article {huang22point,
journal = {Computer Graphics Forum},
title = {{Point-Pattern Synthesis using Gabor and Random Filters}},
author = {Huang, Xingchang and Memari, Pooran and Seidel, Hans-Peter and Singh, Gurprit},
year = {2022},
publisher = {The Eurographics Association and John Wiley & Sons Ltd.},
ISSN = {1467-8659},
DOI = {10.1111/cgf.14596}
}
This work builds upon Point-Synthesis and DiffCompositing. We thank the authors for releasing their code.