Kirpal / Keyboard-Layout-Editor-for-Blender

Allows you to import keyboard layouts into blender and render them in 3d
337 stars 38 forks source link

Serious performance issues when importing KLE json file #53

Closed DanielGGordon closed 3 years ago

DanielGGordon commented 4 years ago

Windows 10 Pro, Blender v2.80, v3.0 KLE for Blender

Importing a simple json file for something such a planck or ergodox takes 2+ minutes to import. I monitored resources during this time, and I also noticed a utilization of up to 17GB of memory during the json import. This seems very very high, and certainly 2+ minutes for a single import is a problem.

I have not tested with 2.79, but will attempt to do that with the current version of this plugin.

Raravin-Keebs commented 4 years ago

My entire blender is actually just going not responsive not sure if it is normal or not importing.

DanielGGordon commented 4 years ago

@Raravin-Keebs yeah it actually for me looks like it is going to crash, but after 1.5 minutes it finally loads. I switched back to blender 2.79 and I don't have this issue at all.

Raravin-Keebs commented 4 years ago

Yeah I reverted to 2.79 and getting an issue with the .py

On Mon, Jan 20, 2020 at 5:34 PM Daniel Gordon notifications@github.com wrote:

@Raravin-Keebs https://github.com/Raravin-Keebs yeah it actually for me looks like it is going to crash, but after 1.5 minutes it finally loads. I switched back to blender 2.79 and I don't have this issue at all.

— You are receiving this because you were mentioned. Reply to this email directly, view it on GitHub https://github.com/Kirpal/Keyboard-Layout-Editor-for-Blender/issues/53?email_source=notifications&email_token=AN46KBWLF456D4CQBT6OPLDQ6YRJDA5CNFSM4KEPAUHKYY3PNVWWK3TUL52HS4DFVREXG43VMVBW63LNMVXHJKTDN5WW2ZLOORPWSZGOEJN64KA#issuecomment-576450088, or unsubscribe https://github.com/notifications/unsubscribe-auth/AN46KBTCKY5QJVMZ22KXDCTQ6YRJDANCNFSM4KEPAUHA .

DanielGGordon commented 4 years ago

Hmm I don't have any issues with 2.79, although I have compared render results, and 2.80 seemed to produce more color accurate results. But that 1-2 minutes load time per .json is killer so I'm not using it.

Kirpal commented 4 years ago

Could you try again with the current master branch and see if you still have issues?

StarrKiss commented 4 years ago

I am getting this error on master branch, blender 2.82. It lasts up until 1.23 on the progress meter before blender crashes, using up ALL of my 16 gigs of ram. (i ran this in a terminal without enabling my desktop environment to test... It uses up ALL the ram if it can) It seems to work on smaller files, but on any large one (60-80 keys or more) it crashes. No idea why. I have a rather beefy computer, so I have no idea.

snagy commented 4 years ago

Weird. I imported and rendered this "beauty" after my change without a problem: https://imgur.com/BpkC8aS

This was on a 32GB machine, but I don't think it would have crashed a 16 GB machine either. I'll check it again soon and see if there's more room for improvement.

StarrKiss commented 4 years ago

This is the file I tried: The KLE Link It crashes at 0123 on the counter in Blender. I have tried this multiple times.

snagy commented 4 years ago

Thanks for the repro data!

Un/fortunately, i didn't see the issue. I successfully imported and topped out at about 2.5 gigs of memory usage after compiling shaders.

tst_board

Are you sure you have the latest version of the plugin installed? I would recommend downloading the zip again, uninstalling the old one and then reinstalling from that new zip.

StarrKiss commented 4 years ago

Hello, I was able to get it working by zipping the github repo and installing that, unfortunately, the geometry is absolutely horrendous. All the shading has a seam down the middle of each cap, and it's unusable. I guess I have to go the long way.

snagy commented 4 years ago

Good to know the perf fix worked.

It looks like the shading seam happens on DSA/DCS (maybe cherry? i didn't test it) profiles but doesn't happen for me on my SA layout. If you can, please open another issue for the shading seam.

DanielGGordon commented 4 years ago

I have also noticed that line down the middle thing with DSA. Wasn't a show stopper for me. You can really only see it when you make a large resolution and zoom in. I used it for some product images for DSA Pink/Purple and I think it was fine.

DanielGGordon commented 4 years ago

This is really the same issue a #51 - still happens to me

Hypn0tyk commented 4 years ago

I am seeing that it uses a huge amount of memory and seems to hang forever on import. image

I tried a couple of times but I waited 5+ minutes and it never finished importing. Fresh Blender install, latest release of plugin.

I should note it does directly into not responding, and the memory takes a few minutes to top out.

Lorphex commented 4 years ago

Same issue here. Running Blender 2.82a and importing freezes Blender for 2-ish minutes before crashing.

sbinlondon commented 4 years ago

Also unable to use v3.0 of this.

Macbook Pro 16-inch 2019 on Catalina OS 10.15.5 Blender 2.83.2 freshly installed

When I try to import the JSON my Blender immediately beachballs and starts consuming massive amounts of CPU and memory. Waited 5 minutes and it didn't import so I had to force quit.

Screenshot 2020-07-10 at 17 09 40 Screenshot 2020-07-10 at 17 09 49
ricardo-alan commented 4 years ago

I couldn't use with the latest version of Blender, but 2.79 works perfect!

snagy commented 4 years ago

@Kirpal any chance we could get a new release built with the recent commits? I think people are still installing 3.0 and seeing this.

DanielGGordon commented 3 years ago

I don't think @Kirpal is actively maintaining this. Has anyone tested with the latest version of blender?

Kirpal commented 3 years ago

@DanielGGordon Pretty much. I don't have the time to actively work on it and I'm not really in the mechkeys world anymore. Happy to accept PRs or add a maintainer if someone can help out

Kirpal commented 3 years ago

Working on a fix that should be out this week.