Comments (6)
That is super excessive VRAM usage. Looks like it is running really, really slowly too. The ESRGAN upscale is ridiculously slow.
Unfortunately, I don't have an AMD GPU to test on. Not sure if any regular contributors do. May need community help to figure this out...
From a brief search, it looks like the env var PYTORCH_HIP_ALLOC_CONF
may be useful. This old post for A1111 has a value to try: AUTOMATIC1111/stable-diffusion-webui#6460 (comment)
If fp32 is being used instead of fp16, you'll use ~2x VRAM - try setting precision: float16
in invokeai.yaml
.
from invokeai.
Setting both PYTORCH_HIP_ALLOC_CONF=garbage_collection_threshold:0.9,max_split_size_mb:512
and precision: float16
doesn't seem to fix it. :v
(But then again, I noticed that adding log_format: color
didn't actually add colored output either, so maybe the yaml just isn't being read? I'm loading the environment variables directly via the script though, so I know that's at least being read)
This is weird.
from invokeai.
If you suspect the YAML file isn't being read, an easy way to test is add use_memory_db: true
. You should see a line like this on startup:
[2024-05-03 13:30:13,686]::[InvokeAI]::INFO --> Initializing in-memory database
Sorry, I'm not sure where to go from here with the performance issue :/
from invokeai.
Ah, that does appear in the terminal output; so I guess it is reading the file but just... not outputting color for some reason? I guess that would otherwise be somewhat reasonably safe to assume that precision: float16
is being passed but whatever the root problem is simply doesn't care.
from invokeai.
We expect colored logs for warnings and errors only (and debug, if you set the log level accordingly). This works for me.
I'm confident the precision is set correctly in normal circumstances, but who knows with the issues you are facing.
from invokeai.
Having A similar issue, Though my system is not allocating massive amounts of VRAM for txt2img, It has a staggeringly low cap. So I can generate images fine but the moment I move to inpainting I cant do anything, and get this error:
OutOfMemoryError: HIP out of memory. Tried to allocate 13.91 GiB. GPU 0 has a total capacity of 19.98 GiB of which 3.43 GiB is free. Of the allocated memory 16.06 GiB is allocated by PyTorch, and 41.54 MiB is reserved by PyTorch but unallocated.
So, for some reason, on my RX 7900 XT with 20GB VRAM, only a measly 3.43GB are available.. It doesn't make sense
Edit: I am on the same system, Ubuntu Linux using AMD ROCm for processing
from invokeai.
Related Issues (20)
- [bug]: Extremely low image quality on some models HOT 3
- [bug]: Some T2I Adapter settings are not preserved as metadata HOT 1
- AlignYourSteps
- [enhancement]: package for nix/NixOS
- [enhancement]: Gallery management - Categories "Sort by" feature
- [bug]: When I try to install a model in the model manager I get a long error that seems to have something to do with my file path that Invoke is installed in. HOT 1
- [enhancement]: Mark cached models in the dropdown list
- [bug]: Can't add SD XL Inpaint model HOT 2
- Host remote 22 issue connecting refuse HOT 1
- [bug]: 'fromisoformat: argument must be str' HOT 7
- [bug]: Meta Data Lost With Built-In Upscaler HOT 4
- [bug]: On restart of UI, width/height default to 512x512 even if an SDXL model is default.
- [bug]: [v4.2.0a4] Error: Wrong assertion encountered: "Control adapter with id {someUUID} not found" HOT 1
- [bug]: Rectangle "mousedown" persists when cursor moved beyond canvas HOT 2
- [enhancement]: Model name column in queue HOT 1
- [enhancement]: Hidiffusion for SD1.5 and SDXL HOT 3
- [bug]: Long UI loading HOT 5
- [bug]: Regional Guidance Layers should (probably) scale when changing resolution HOT 1
- [enhancement]: Option to have separate prompts per module (txt2img, img2img, canvas) HOT 1
Recommend Projects
-
React
A declarative, efficient, and flexible JavaScript library for building user interfaces.
-
Vue.js
🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
-
Typescript
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
-
TensorFlow
An Open Source Machine Learning Framework for Everyone
-
Django
The Web framework for perfectionists with deadlines.
-
Laravel
A PHP framework for web artisans
-
D3
Bring data to life with SVG, Canvas and HTML. 📊📈🎉
-
Recommend Topics
-
javascript
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
-
web
Some thing interesting about web. New door for the world.
-
server
A server is a program made to process requests and deliver data to clients.
-
Machine learning
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
-
Visualization
Some thing interesting about visualization, use data art
-
Game
Some thing interesting about game, make everyone happy.
Recommend Org
-
Facebook
We are working to build community through open source technology. NB: members must have two-factor auth.
-
Microsoft
Open source projects and samples from Microsoft.
-
Google
Google ❤️ Open Source for everyone.
-
Alibaba
Alibaba Open Source for everyone
-
D3
Data-Driven Documents codes.
-
Tencent
China tencent open source team.
from invokeai.