URL:
<http://gna.org/bugs/?15350>
Summary: Leaks memory like a sieve :|
Project: MyPaint
Submitted by: ion9
Submitted on: Saturday 02/13/2010 at 07:11
Severity: 3 - Normal
Priority: 5 - Normal
Status: None
Privacy: Public
Assigned to: None
Originator Email:
Open/Closed: Open
Discussion Lock: Any
Release:
Planned Release: None
Operating System:
_______________________________________________________
Details:
I needed to produce flattened versions of many .ora files, so I wrote a
script using xdotool.
After flattening all those images successfully, I noticed mypaint was eating
up all the cpu time.
Then I noticed it had a virtual size of 1.4 GB!!! (my physical ram is only
1GB)
Conclusion:
one of the following three are happening:
* Opening an ORA leaks memory
* Saving a solid PNG leaks memory
* When opening the next file, some memory belonging to the image is leaked.
I've attached the script, which is suitable for use with ora images <= 2mb,
and requires you to assign a shortcut to 'Save As' (if there isn't already --
I haven't bothered hidng my config to find out the default keybindings).
Edit the script and check the keypresses on lines 25 and 29 to make sure they
match your Open and Save As shortcuts.
Suggested use is like this:
0. make sure xdotool is installed.
1. throw some (20-100) ORA files into a temporary directory along with this
script, and make a 'plita' directory inside it; this holds the flattened
images.
2. go to the second desktop, open MyPaint, scribble a bit, and save it
(select 'png solid' format.)
3. go back to the first desktop
4. open a terminal and navigate to that temporary directory
5. run 'python flatten *.ora' and DO NOT TOUCH THE KEYBOARD OR MOUSE (or
tablet) until the last PNG has been saved (this should be the last one
alphabetically.)
6. Run top, hit 'M' to sort by memory usage, Python-2.6 should be at the top
(and vastly beyond mypaint's normal memory use)
Normally takes about 10sec to process each image.
The script should be pretty easy to modify to just continuously load or just
continuously save, to narrow down the location of the memleak, but I may not
have time to do that today.
_______________________________________________________
File Attachments:
-------------------------------------------------------
Date: Saturday 02/13/2010 at 07:11 Name: flatten Size: 2kB By: ion9
<http://gna.org/bugs/download.php?file_id=8064>
_______________________________________________________
Reply to this item at:
<http://gna.org/bugs/?15350>
_______________________________________________
Message sent via/by Gna!
http://gna.org/
_______________________________________________
Mypaint-bugs mailing list
[email protected]
https://mail.gna.org/listinfo/mypaint-bugs