-
-
Notifications
You must be signed in to change notification settings - Fork 75
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
ValueError: array is too big; arr.size * arr.dtype.itemsize
is larger than the maximum possible size.
#7
Comments
Hello, Thanks for raising an issue about this. It's indeed an identified bug. For now your are the third one to have it and I'm still unsure about what is the origin. What I know is that it's not coming directly from my scripts but from the plotting library that fail to allocate RAM to create the spectrogram. However, by doing some very basic profiling, the array is around 15-20MB and this should work on about every single board computer. Beside that, I know that some users are running my scripts fine in a Pi Zero so it's definitely something to be investigated to understand why it fail sometimes... |
Thanks for looking into this! One more interesting/weird data point: Klippain worked on the same HW, just with different OS installation. I used fluiddpi originally, but upgraded to the latest Raspberry Pi OS + KIAUH recently, and it now fails all the time. |
Likely due to integer overflow on 32 bit machines. @AlexanderSidorenko are you running 32bit OS perchance ? |
Yes, actually! It is in fact 32 bit OS, and that is the difference between my original setup where Klippain worked, and the current one where things are broken. |
Hi, I've taken some time to do some tests on my machines and also on some machines of contributors who helped me. So here are the items I got so far:
|
For reference, here is one of the worst report that I got regarding the spectrogram generation:
|
For users having the problem here, can you try running this line in your SSH console: |
I ran this on a 64 bit Pi running Raspbian:
|
Morning, Running that gives me on my V2 where I have the issue and VT where I don't gives the same result:
Both are running 32bit raspbian |
Version checks on bits Python Numpy Matplotlib I did update the V2 while troubleshooting the issue hence newer versions. Both machines were built from raspbian minimum using KIAUH. |
This is on my Voron Trident with a 32-bit raspbian OS + KIAUH, the issue is present. |
@recrudesce do you have the issue? If it's the case, then I think you'll be the only one for now to get it on 64bit systems. |
I also have this issue on a Pi4b running 32bit Raspbian lite. It is a recent installation which I ran through using directions I wrote for myself the last time I clean installed Klipper on my old Pi3b in October. This issue didn't exist on my 3b. After running the command above, I get this:
Also, for what it's worth, tests with short frequency ranges finish as expected. On my machine, the error only appears if the difference between freq_min and freq_max is greater than 40hz. I don't know if this is useful, but now you know 🤣 |
Installing Debian Bullseye (legacy Raspberry Pi OS) fixed this issue for me. The current version of RPiOS is based on Debian Bookworm, and it is apparently incompatible with some part of Shake & Tune. |
I'm running Debian Bullseye on both printers with Shake&Tune installed, only one of them has the issue |
So based on all of the discussions, feedbacks and testings, it look like it's not really a 32bit vs 64bit issue since Shake&Tune was confirmed to work on both of this kind of systems. However, the issue seems to arise only on 32 bits system AFAIK. Still looking to find the origin. If I can't solve it I will probably switch to another plotting librairy like plotly or something like that in the future... Let's see! First thing to try for now is to make the whole thing run in a Python env and see if I can fix the lib versions and the bug that way |
Thanks for all your efforts, Frix! Looking forward to trying this out for the first time. |
Chiming in to say that I have this issue also... Uname: $ uname -a
Linux bluey 6.1.0-rpi6-rpi-v8 #1 SMP PREEMPT Debian 1:6.1.58-1+rpt2 (2023-10-27) aarch64 GNU/Linux Mainsail host data:
The test from the comments:
Traceback:
|
Also having this issue with fresh installs across the board. Posted an issue in the Klippain github at Frix-x/klippain#379 since I've installed the complete klippain, not just the Shake n Tune. |
Can confirm, changing to 64-bit Raspberry Pi OS Lite fixed the issue. Just finished my installs and testing and I'm now getting the graphs. |
Hey, I've worked on this subject and may have found a way to fix it. So if some of you could test it, I would be glad :) To proceed with the test:
cd ~/klippain_shaketune
git checkout venv
./install.sh
cd ~/klippain_shaketune
git checkout main Note: these manual steps are only necessary now since I want you to test it before creating a release tag, but when it will be pushed officially to the main branch and released, updating Shake&Tune from Mainsail/Fluidd will be enough for everyone and everything will be automated :) |
This fix works for me on bookworm and a PI5. |
Wouhouu that's great news! I'll wait for the confirmation by other people and will eventually release it later today for everyone :) |
|
Can confirm, that fix has worked for me as well |
Ok that's perfect :) |
K-Shake&Tune module branch
Version
v1.1.1, 83f5177
Describe the bug and expected behavior
I am consistently hitting an error deep in the Python guts when trying to run klippain-shaketune on my set up.
It repros 100%, on both X and Y axes. I am attaching one file to repro, but I have more if needed.
Here's the repro steps and full stack trace:
Additional information and klippy.log
klippy.log
resonances_20231106_220647_X.zip
The text was updated successfully, but these errors were encountered: