You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
this is an exact duplicate of issue #396 which was closed without getting a real solution.
I frequently get a very slow IPython session with a lot of IO activity triggered by cursor actions (up/dowm history and also moving left/right).
IOtop shows writes up to 50-60Mb/s.
This is always correlated to working interactivelly with matplotlib (memory use is not noticeably higher as usual). Simple stuff, no monster object or very complex figure.
I use Ipython 13.1 and matplotlib (1.2.0), but this problem is older than both these versions...
Running on Linux Mint 13 64 bit wit readline5 5.2.11 and readline6 6.2.8 (could it be a problem to have both libraries???)
Thanks a lot in advance... this is litterally a show stopper!
JF
Is there any way to determine what file it's writing to? I can't think why IPython, matplotlib or readline should be doing a lot of IO on cursor movements.
Thanks for the tips.
I am now trying to reproduce the problem, and of course it does not want to appear.
I'll post a lsof output as soon as I get it again...
Thanks for the fast answers anyway!
Thanks, @ajhorton, any hint of a pattern is a step forwards. Unfortunately, I can't replicate the problem, though. This is what I tried:
IPython master, matplotlib master, Ubuntu 12.10
ipython --pylab
...
In [2]: abc = 123 # This was testing responsiveness
In [3]: plot(arange(10))
Out[3]: [<matplotlib.lines.Line2D at 0xa3ac6ec>]
# Clicked the save button in the matplotlib window, saved as PNG to the desktop
# (Console remains responsive)
@ajhorton, you nailed it down! I thought I was trying everything but missed to save a pic.
Using pylab.savefig is apparently not a problem but as soon as I save a figure from the GUI I trigger this monster IO activity. I tried several times and the bug always shows up.
I produced a dump of lsof and strace (I'll mail it tgz (200kb) to the takluyver and rkern hoping that this is the right way to proceed... let me know if I could put it online somewhere...).
JF
Apparently recently-used.xbel is something used by GTK. I tried with ipython --pylab gtk, and I think I could just see a tiny slowdown after saving a plot. Is there anything notable about that file on your machine - like it being really big, or on a network drive?
@bfroehle , I've had no experience of reading strace logs, but does that mean it's trying to write to the file and failing?
I wonder if the matplotlib guys would have a better idea about debugging this.
/.local/share/recently-used.xbel is 967K no idea if this has to be considered big. It is on a local disk, which by the way is a ssd... so not the kind of disk you want rewritten in an endless loop.
Some people apparently try to prevent this file to be used by making it read only, but some temporary files with a similar name might be created though.
I could reproduce the problem in a normal python shell, so I guess I should post the report on Matplotlib's issue tracker
/.local/share/recently-used.xbel is 967K no idea if this has to be
considered big. It is on a local disk, which by the way is a ssd... so not
the kind of disk you want rewritten in an endless loop.
Some people apparently try to prevent this file to be used by making it
read only, but some temporary files with a similar name might be created
though.
I could reproduce the problem in a normal python shell, so I guess I
should post the report on Matplotlib's issue tracker
—
Reply to this email directly or view it on GitHubhttps://github.com//issues/2608#issuecomment-10679217.
Hi, I have an SSD disk an every times that I press enter under ipython with dummy code (example: In [19]: a = 2), a write disk is maked. It is noticeable for a some lag between press enter and see the result!
Activity
takluyver commentedon Nov 20, 2012
Is there any way to determine what file it's writing to? I can't think why IPython, matplotlib or readline should be doing a lot of IO on cursor movements.
rkern commentedon Nov 20, 2012
lsof(1)will show what files are opened by the IPython process.strace(1)may give more real-time information about the reads and writes.jfmoulin commentedon Nov 20, 2012
Thanks for the tips.
I am now trying to reproduce the problem, and of course it does not want to appear.
I'll post a lsof output as soon as I get it again...
Thanks for the fast answers anyway!
takluyver commentedon Nov 23, 2012
Thanks, @ajhorton, any hint of a pattern is a step forwards. Unfortunately, I can't replicate the problem, though. This is what I tried:
IPython master, matplotlib master, Ubuntu 12.10
jfmoulin commentedon Nov 23, 2012
Hi!
@ajhorton, you nailed it down! I thought I was trying everything but missed to save a pic.
Using pylab.savefig is apparently not a problem but as soon as I save a figure from the GUI I trigger this monster IO activity. I tried several times and the bug always shows up.
I produced a dump of lsof and strace (I'll mail it tgz (200kb) to the takluyver and rkern hoping that this is the right way to proceed... let me know if I could put it online somewhere...).
JF
jfmoulin commentedon Nov 23, 2012
Well, me again... I guess the best way is to use something like filebin:
http://filebin.ca/NdspC6wfTV3 links to the tar with the two dumps.
JF
bfroehle commentedon Nov 24, 2012
Reading through the strace log shows that the program is repeatedly re-creating
/home/jfmoulin/.local/share/recently-used.xbel.The repeated loop appears to be the following. Now I'm not sure where the loop "starts" but I chose what I thought was a reasonable start.
takluyver commentedon Nov 24, 2012
Apparently
recently-used.xbelis something used by GTK. I tried withipython --pylab gtk, and I think I could just see a tiny slowdown after saving a plot. Is there anything notable about that file on your machine - like it being really big, or on a network drive?@bfroehle , I've had no experience of reading strace logs, but does that mean it's trying to write to the file and failing?
I wonder if the matplotlib guys would have a better idea about debugging this.
jfmoulin commentedon Nov 24, 2012
/.local/share/recently-used.xbel is 967K no idea if this has to be considered big. It is on a local disk, which by the way is a ssd... so not the kind of disk you want rewritten in an endless loop.
Some people apparently try to prevent this file to be used by making it read only, but some temporary files with a similar name might be created though.
I could reproduce the problem in a normal python shell, so I guess I should post the report on Matplotlib's issue tracker
takluyver commentedon Nov 24, 2012
Yep, I think reporting it to matplotlib is a good idea. Keep us posted
about it!
On 24 November 2012 16:20, jfmoulin notifications@github.com wrote:
bfroehle commentedon Nov 24, 2012
Yes, please report it to Matplotlib, but they might send you upstream to PyGTK (or similar).
devedetti commentedon Aug 16, 2013
Hi, I have an SSD disk an every times that I press enter under ipython with dummy code (example: In [19]: a = 2), a write disk is maked. It is noticeable for a some lag between press enter and see the result!
takluyver commentedon Aug 16, 2013
@nachopro : Is this connected to matplotlib, as described in the discussion above? If so, see the matplotlib issue. If not, open a new issue.