fix way for output images

disable async
This commit is contained in:
Mikhail Guseletov 2023-06-15 17:01:52 +07:00
parent ab5985cc0e
commit 3c16bc6acb
2 changed files with 7 additions and 3 deletions

View File

@ -1,7 +1,11 @@
# sd_telegram
telegram bot on aiogram python 3.10.6 to generate images in automatic1111 locally
create bot from [this](https://t.me/BotFather) and use token in [API_TOKEN](https://github.com/amputator84/sd_telegram/blob/master/bot.py#L28)
```
pip install aiogram
pip install webuiapi
cd C:\stable-diffusion-webui\extensions\sd_telegram\
python bot.py
``````

4
bot.py
View File

@ -33,7 +33,7 @@ dp = Dispatcher(bot, storage=storage)
# -------- GLOBAL ----------
# TODO брать из outdir_txt2img_samples
img_dir = "C:/html/stable-diffusion-webui/outputs/txt2img-images/"
img_dir = "../../outputs/txt2img-images/"
formatted_date = datetime.today().strftime("%Y-%m-%d")
host = "127.0.0.1"
port = "7861"
@ -62,7 +62,7 @@ data = {
"firstphase_width": 0,
"firstphase_height": 0,
"save_images": "true",
"use_async": "True",
#"use_async": "True",
}
dataParams = {"img_thumb": "true", "img_tg": "true", "img_real": "true"}