harubaru / discord-stable-diffusion Goto Github PK
View Code? Open in Web Editor NEWA neat Discord bot to run Stable Diffusion locally
License: GNU General Public License v2.0
A neat Discord bot to run Stable Diffusion locally
License: GNU General Public License v2.0
[2023-01-02 11:06:49] ERROR: Task exception was never retrieved
future: <Task finished name='Task-19' coro=<Messageable.send() done, defined at C:\Users\abcsa\OneDrive\Documents\GitHub\discord-stable-diffusion\venv\lib\site-packages\discord\abc.py:1384> exception=HTTPException('400 Bad Request (error code: 50035): Invalid Form Body\nIn embeds: Embed size exceeds maximum size of 6000')>
Traceback (most recent call last):
File "C:\Users\abcsa\OneDrive\Documents\GitHub\discord-stable-diffusion\venv\lib\site-packages\discord\abc.py", line 1606, in send
data = await state.http.send_message(
File "C:\Users\abcsa\OneDrive\Documents\GitHub\discord-stable-diffusion\venv\lib\site-packages\discord\http.py", line 366, in request
raise HTTPException(response, data)
discord.errors.HTTPException: 400 Bad Request (error code: 50035): Invalid Form Body
In embeds: Embed size exceeds maximum size of 6000
Thanks for this source!
I see the stable diffusion backend is recently changed to compvis from diffusers. What is the reason? What is the disadvantage of using diffusers implementation?
With my current system (RX 570 4GB) I can run AUTOMATIC1111/stable-diffusion-webui with their --medvram
flag without any issue.
Would it be possible to implement something similar to their --medvram
flag?
Getting invalid load key, '\x1f'. I've installed everything as stated in the instructions and I've managed to get the bot working. However, the bot does not create any images. It simply throws an error. I've made sure to have the correct path to the model.
The full error is:
_pickle.UnpicklingError: invalid load key, '\x1f'.
My PC specs:
RTX 3090
64GB RAM
12900K CPU
from what i know the bot only works on downloading/generating and not on responding to discord heartbeats
My friend is trying to run this bot on his Mac M1. However, when trying to run setup.sh
, he is plauged with this error:
[friend's user] mare.ai % sudo sh setup.sh
File "/Users/[friend's name]/Downloads/mare.ai/venv/bin/pip", line 2
/bin/python3.11
^
SyntaxError: invalid syntax
It also always opens a venv folder called venv?
instead of venv
for some reason, and every time we rename it to venv
it just creates a new folder called venv?
.
Why could that be? Thanks.
I have been following the following steps, using Windows 11 :
setup.bat
and completed the venv installationrun.bat
file to fill the model.ckpt location and the Discord bot token/dream
command with the following query : "a girl drinking soda"Seeing the same error KeyError: 'state_dict'
after multiple queries attempts, I uninstalled and redone all the above steps. But it's no use: there is still that same error.
Here's what happens from the cmd, and the displayed error on Discord :
Request -- YamakoKiasote#2844 -- Prompt: a girl drinking soda
[2022-11-30 15:20:59] INFO: Global seed set to 1105693868
[2022-11-30 15:20:59] INFO: Global seed set to 1070861717
Loading model from C:\Users\yamak\stable-diffusion\models\Stable-diffusion\model.ckpt
Traceback (most recent call last):
File "C:\Users\yamak\discord-stable-diffusion\src\bot\stablecog.py", line 161, in dream
samples, seed = self.text2image_model.dream(queue_object.prompt, queue_object.steps, False, False, 0.0,
File "C:\Users\yamak\discord-stable-diffusion\src\stablediffusion\text2image_compvis.py", line 64, in dream
results = self.generator.txt2img(prompt=prompt, iterations = 1, steps=ddim_steps, seed=seed, cfg_scale=cfg_scale, ddim_eta=ddim_eta, width=width, height=height, sampler_name=sampler_name, outdir='storage/outputs')
File "C:\Users\yamak\discord-stable-diffusion\src\stablediffusion\ldm\generate.py", line 175, in txt2img
return self.prompt2png(prompt, outdir, **kwargs)
File "C:\Users\yamak\discord-stable-diffusion\src\stablediffusion\ldm\generate.py", line 162, in prompt2png
results = self.prompt2image(prompt, **kwargs)
File "C:\Users\yamak\discord-stable-diffusion\src\stablediffusion\ldm\generate.py", line 263, in prompt2image
self.load_model()
File "C:\Users\yamak\discord-stable-diffusion\src\stablediffusion\ldm\generate.py", line 426, in load_model
model = self._load_model_from_config(config, self.weights)
File "C:\Users\yamak\discord-stable-diffusion\src\stablediffusion\ldm\generate.py", line 538, in _load_model_from_config
sd = pl_sd['state_dict']
KeyError: 'state_dict'
[2022-09-07 12:24:02] ERROR: Extension 'src.bot.stablecog' raised an error: OSError: Can't load config for 'CompVis/stable-diffusion-v1-4'. If you were trying to load it from 'https://huggingface.co/models', make sure you don't have
a local directory with the same name. Otherwise, make sure 'CompVis/stable-diffusion-v1-4' is the correct path to a directory containing a config.json file
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.