catalys1 / fractal-pretraining

Official PyTorch code for the paper "Improving Fractal Pre-training"

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Improving Fractal Pre-training

PyTorch Lightning Config: Hydra Paper Conference

This is the official PyTorch code for Improving Fractal Pre-training (arXiv).

@article{anderson2021fractal,
  author  = {Connor Anderson and Ryan Farrell},
  title   = {Improving Fractal Pre-training},
  journal = {arXiv preprint arXiv:2110.03091},
  year    = {2021},
}
This README is incomplete (work in progress).

Setup

The code uses PyTorch-Lightning for training and Hydra for configuration. Other required packages are listed in install_requirements.sh.

# clone project
git clone https://github.com/catalys1/fractal-pretraining.git
cd fractal-pretraining

# [RECOMMENDED] set up a virtual environment
python3 -m venv venv_name  # choose your prefered venv name
source venv/bin/activate

# install requirements
bash install_requirements.sh
# install project in editable mode
pip install -e fractal_learning

Sample and Render Iterated Function Systems

See the fractals sub-package for details on sampling IFS codes and rendering fractal images.

Training

See the training sub-package for details on pre-training with fractal images, as well as finetuning on other datasets.

About

Official PyTorch code for the paper "Improving Fractal Pre-training"

License:MIT License


Languages

Language:Python 99.5%Language:Shell 0.5%