Neural_SaintPetersburg

  1. Install python-telegram bot
pip install python-telegram-bot --pre
  1. Install requirements (if you are using Colab)
%cd stable-diffusion
pip install -r requirements.txt

or create conda env (if you are running locally)

conda env create -f environment.yaml
conda activate ldm
  1. Run
python3 scripts/preload_models.py
  1. Create file configs.py and paste
TELEGRAM_API_TOKEN = 'YOUR TOKEN'
  1. (Optional) Download Stable-Diffusion checkpoint Go to https://huggingface.co/CompVis/stable-diffusion-v-1-4-original and download sd-v1-4.ckpt . Place it in models/ldm/stable-diffusion-v1 .

WARNING: If sd-v1-4.ckpt wasns't downloaded the bot always will return the same test image.

  1. Run telegram bot
python bot_main.py