[2.0.4] IDE: Excessive memory usage when using alt-shift-c to stop a script run --- possible bug

Asked by Aydın on 2021-01-22

********* possible bug tracked on GitHub
https://github.com/RaiMan/SikuliX1/issues/411
----------------------------------------------------------------------------

My code was working fine before.
Now it uses a lot of memory.

https://ibb.co/GTyjtrv

For better understanding of my code, I shared it on the link below.

https://paste.ubuntu.com/p/VDzDjmkMn9/

I reviewed it over and over but couldn't find what caused this.
please help: ((

Question information

Language:
English Edit question
Status:
Solved
For:
SikuliX Edit question
Assignee:
No assignee Edit question
Solved by:
RaiMan
Solved:
Last query:
Last reply:
Revision history for this message
RaiMan (raimund-hocke) said :
#1

cannot see anything odd in your code.

what system? what Java? what SikuliX version?

anything changed?

Revision history for this message
Aydın (adn72) said :
#2

windows 10
SikuliXIDE-2.0.4
java 11

#####tesseract info###########
tesseract v4.0.0.20190314
 leptonica-1.78.0
  libgif 5.1.4 : libjpeg 8d (libjpeg-turbo 1.5.3) : libpng 1.6.34 : libtiff 4.0.9 : zlib 1.2.11 : libwebp 0.6.1 : libopenjp2 2.2.0
 Found AVX2
 Found AVX
 Found SSE
##########################

Sometimes I stop the program with a shortcut (alt + shift + c) then restart it.

Sometimes I open a new file and try new codes and then I just close the file without closing the program(SikuliXIDE-2.0.4).

When I close files, do they really not close and be running in the background?
or
Could it be because I always start code and stop code while trying my codes in the program?

Then I can try to close and reopen the program completely after I try again.

Revision history for this message
Aydın (adn72) said :
#3

Now I did not stop the program with hot keys and run it over and over again.
I ran the code and waited two hours. Memory usage has not increased much

When I stop the program with a shortcut and start it again, the memory usage increases.

What is the reason of this?
Am I using the incorrect hotkeys?

Revision history for this message
Best RaiMan (raimund-hocke) said :
#4

Ok, thanks for the feedback.
alt-shift-c ist the intended standard hotkey, to stop a running script.
So feel free to use it.

For now as the workaround: in cases where the memory increase gets too much, stop the SikuliX IDE and restart. Take care to have saved everything before.

I have to check this odd memory behavior in these cases.
I will track a possible bug on GitHub.

Revision history for this message
Aydın (adn72) said :
#5

thank you for your answer

Revision history for this message
Aydın (adn72) said :
#6

Thanks RaiMan, that solved my question.