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
If matplotlib backend in 'matplotlibrc' is set to Qt4Agg, terminal console mode slows down on multiple levels: there is pause on every letter entered; if I paste some code I have to wait approx 1sec for every 2-3 characters!; and overall it seems so unnaturally slow. This does not happen however in IPython qtconsole, and I don't remember similar behavior when I used 10.2 on Windows 7. This also does not happen if matplotlib backend is set to WXAgg for example.
Noticed on:
Windows XP SP3 32 bit
Python 2.6.6 (official from python.org)
PyQt4 4.8.4
matplotlib 1.0.1
IPython 0.11.dev
I'm marking this as critical for 0.11 so that at least we check (I can do it) if one of us can reproduce it. If this is systemic, it will make 0.11 unusable on Windows with Qt.
@epatters, this looks pretty nasty. Do you have any inkling as to what could be going on? I had the impression you'd been testing with Windows a while ago, so I imagined you'd have seen this already.
It definitely is not a problem in Linux, so somehow it must be something with Qt on Windows. I wonder if it's a Qt 4.8 problem, I think when we did the original work we were testing (I also did some light Windows testing at the time) with Qt 4.6 or 4.7...
@epatters, btw, I just realized my previous message makes it sound like I'm blaming you, which is not the case :) Just looking for your input/wisdom...
I've been using PySide on Windows, which means that I can't use matplotlib's Qt backend. In other words, I haven't tried this out lately. When I have access to my Windows box tomorrow, I will switch back to PyQt4 and see if I can debug the problem.
Off the top of my head, though, the behavior described above also occurs when running a PDB session under vanilla Python ifQtCore.pyqtRemoveInputHook() has not been called. For more information, see:
@epatters, this looks pretty nasty. Do you have any inkling as to what could be going on? I had the impression you'd been testing with Windows a while ago, so I imagined you'd have seen this already.
It definitely is not a problem in Linux, so somehow it must be something with Qt on Windows. I wonder if it's a Qt 4.8 problem, I think when we did the original work we were testing (I also did some light Windows testing at the time) with Qt 4.6 or 4.7...
I tried to run without pyreadline and then it behaves normally. So there
seems to be some kind of interaction between pyreadline and Qt4.
Unfortunately I'm leaving for a short midsummer holiday and will be back
on sunday evening.
That's true. I use dotjs (Userscripts/greasemonkey would work too) to float it to the left and fade it a little, so I don't click it accidentally:
functionleftClose(){// float 'Comment & Close' button on the left, to prevent accidental clicking// also fade text to grey to make it stand out less// query from from userscripts.org/scripts/105325varandClose=document.querySelector('button[name="comment_and_close"]');if(andClose){// float it on the leftandClose.style.float='left';// fade textandClose.style.color="#aaa";// or you can just remove the button altogether:// andClose.parentNode.removeChild(andClose);}}leftClose();
For what it's worth, an EPD customer has seen similar problems on Windows XP with the WXAgg backend to matplotlib. Changing the inputhook constants do not seem to make any noticeable difference. I have not been able to replicate the wx slowness myself on Windows 7 (I can replicate the Qt slowness, though).
Here is a VERY simple newbie solution for someone brand new to python/iPython that may work for some of you newbies like me:
Here's my version info:
Python 2.7.2 -- EPD_free 7.2-2 (32-bit)
ipython --version 0.12
matplotlib 1.1.0
numpy 1.7.0
scipy 0.11.0 maybe?
I just created a new profile using the startup option '' and that seemed to do the trick. Utterly newb solution, but it worked for me and may work for you.
For you seasoned devs, here's some info that may help:
Before I found the hidden nanolink at Enthought, I struggled with the install for quite a while. After attempting to install manually a variety of ways, I think I had a very confused python install. I'm guessing that I had something in there that called a problematic input hook that was causing the problem. I wasn't able to find anything, but I honestly didn't look that hard yet.
Here are just a few of the misguided things I did while trying to install:
gcc manual install (was trying to avoid xcode - failed - no compiler)
clang install (failed)
llvm manual install (clang dependency)
freetype2 manual install (llvm dependency)
Finally gave in to xcode install (hate xcode -- big, closed, clunky)
Heard "Enthought" enough to realize they HAD to have a free link somewhere that had Numpy/Scipy/Matplotlib as a free package. Went back and scoured their site until I found it.
So then I finally created a new profile and it fixed the super slowness.
So does that mean that, on a Mac, simply creating a profile solved the
unresponsiveness issue for you? That's a bit odd, because when you
create a profile, it just writes files with all the settings commented
out. But it might give someone something to work with. Thanks, Dave.
I'm sorry to do this, but I'm downgrading this to 'high' priority from 'blocker', simply because we can't realistically block the entire release on an issue we have no clue how to fix.
It's a real bummer, and I hope we'll be able to track what's going on at some point, but absent any progress, we can't stall a release on this. And in fact, we were violating the 'blocker' marker already since we'd bumped this from 0.11 to 0.12 to 0.13, so if anything I'm just being upfront about what we've already done.
I would like to report that i have been facing this problem for a long time in my gnu/linux too. Surprised to see it has been reported only in Windows.
In short following are the specifications:
Linux Kernel : 3.5.2
Distro: Porteus ( https://en.wikipedia.org/wiki/Porteus_%28operating_system%29 )
Desktop: Trinity (aka. fork of KDE 3.5 )
Python version : 2.6.4
IPython version : 0.12
I run Ipython in terminal by the simple "ipython" command. (no extra arguments)
Description of problem: This usually happens when i leave Ipython terminal open for a few days.
I typically have the numpy, scipy and matplotlib modules loaded.
The machine doesnot gets slow. Infact the commands run by Ipython are also not slow.
Only the keyboard input is slow.
Even if I copy-paste some content into Ipython, it prints each pasted letter one by one with a uniform delay.
While this pasted content is being printed slowly on screen or when i use backspace to remove it, we can see the CPU percentage use of Ipython shooting significantly up in htop.
If I exit the session, and start again, everything works fine as usual.
I and my office mate both see this bug in linux too. So here's our experiences, in case it helps isolate it:
I'm using XUbuntu 12.04 (Xfce), ipython 0.12.1 and my office mate also on Linux Mint with ipython 13.1-rc2.
We both see it slowing only the keyboard input (including just moving the cursor) and pasting after use of matplotlib and numpy for some time. I do also use scipy but my officemate doesn't. We're both using the GTKAgg backend.
It doesn't occur immediately, but after some time with use of plotting etc.
We both see significant disk activity during moving the cursor back and forth (as in #1184, perhaps I should have posted this there? I don't want to double post though).
I've found that our problem is exactly that in matplotlib/matplotlib#1530 relating to writing .local/share/recently-used.xbel after opening the GTK (maybe also Qt) save figure dialog once (but not necessarily saving anything). I'll wander over there now.
One man's testimonial: I resolved this issue by installing the dev version of matplotlib. Perhaps this commit in this issue cited by @oliford did the trick.
Activity
fperez commentedon May 29, 2011
I'm marking this as critical for 0.11 so that at least we check (I can do it) if one of us can reproduce it. If this is systemic, it will make 0.11 unusable on Windows with Qt.
jstenar commentedon Jun 22, 2011
I can reproduce this problem on windows 7 64-bit.
python2.6.6 (32bit)
pyqt4 v4.8.3
matplotlib 1.0.1
ipython 0.11.dev master 1144388
However it is not a problem in the qtconsole
It does not behave like this with the tk-backend
/Jörgen
fperez commentedon Jun 22, 2011
@epatters, this looks pretty nasty. Do you have any inkling as to what could be going on? I had the impression you'd been testing with Windows a while ago, so I imagined you'd have seen this already.
It definitely is not a problem in Linux, so somehow it must be something with Qt on Windows. I wonder if it's a Qt 4.8 problem, I think when we did the original work we were testing (I also did some light Windows testing at the time) with Qt 4.6 or 4.7...
fperez commentedon Jun 22, 2011
@epatters, btw, I just realized my previous message makes it sound like I'm blaming you, which is not the case :) Just looking for your input/wisdom...
epatters commentedon Jun 23, 2011
I've been using PySide on Windows, which means that I can't use matplotlib's Qt backend. In other words, I haven't tried this out lately. When I have access to my Windows box tomorrow, I will switch back to PyQt4 and see if I can debug the problem.
Off the top of my head, though, the behavior described above also occurs when running a PDB session under vanilla Python if
QtCore.pyqtRemoveInputHook()has not been called. For more information, see:http://www.riverbankcomputing.co.uk/static/Docs/PyQt4/html/python_shell.html
Perhaps something is not playing nice with PyQt4's input hook...
jstenar commentedon Jun 23, 2011
fperez skrev 2011-06-23 00:25:
Unfortunately I'm leaving for a short midsummer holiday and will be back
on sunday evening.
/Jörgen
fperez commentedon Jun 23, 2011
On Thu, Jun 23, 2011 at 1:30 AM, jstenar
reply@reply.github.com
wrote:
Thanks for the feedback though, this is already useful.
Have a good wekend!
f
klonuo commentedon Jun 24, 2011
Feel free to contact me with instructions if you don't have Windows XP/7 PC. I have both with IPython 0.11dev
Cheers
klonuo commentedon Jun 24, 2011
Well, I have no idea how I closed this issue as I only commented
huh
epatters commentedon Jun 24, 2011
The "Comment and Close" button is dangerously close to the "Comment" button. Not a great usability decision there...
minrk commentedon Jun 24, 2011
That's true. I use dotjs (Userscripts/greasemonkey would work too) to float it to the left and fade it a little, so I don't click it accidentally:
This is what it looks like to me:

epatters commentedon Jun 24, 2011
Nice one! Thanks.
43 remaining items
rkern commentedon Dec 6, 2011
For what it's worth, an EPD customer has seen similar problems on Windows XP with the WXAgg backend to matplotlib. Changing the inputhook constants do not seem to make any noticeable difference. I have not been able to replicate the wx slowness myself on Windows 7 (I can replicate the Qt slowness, though).
SirVer commentedon Dec 24, 2011
sorry for the late feedback, I was travelling and didn't bother doing my email. Yes, I can also see the problem just with using --gui qt.
Proletariat99 commentedon Apr 15, 2012
Here is a VERY simple newbie solution for someone brand new to python/iPython that may work for some of you newbies like me:
Here's my version info:
I just created a new profile using the startup option '' and that seemed to do the trick. Utterly newb solution, but it worked for me and may work for you.
For you seasoned devs, here's some info that may help:
Before I found the hidden nanolink at Enthought, I struggled with the install for quite a while. After attempting to install manually a variety of ways, I think I had a very confused python install. I'm guessing that I had something in there that called a problematic input hook that was causing the problem. I wasn't able to find anything, but I honestly didn't look that hard yet.
Here are just a few of the misguided things I did while trying to install:
So then I finally created a new profile and it fixed the super slowness.
Hope that helps someone, somewhere.
Cheers.
takluyver commentedon Apr 15, 2012
So does that mean that, on a Mac, simply creating a profile solved the
unresponsiveness issue for you? That's a bit odd, because when you
create a profile, it just writes files with all the settings commented
out. But it might give someone something to work with. Thanks, Dave.
fperez commentedon Jun 11, 2012
I'm sorry to do this, but I'm downgrading this to 'high' priority from 'blocker', simply because we can't realistically block the entire release on an issue we have no clue how to fix.
It's a real bummer, and I hope we'll be able to track what's going on at some point, but absent any progress, we can't stall a release on this. And in fact, we were violating the 'blocker' marker already since we'd bumped this from 0.11 to 0.12 to 0.13, so if anything I'm just being upfront about what we've already done.
indiajoe commentedon Feb 7, 2013
I would like to report that i have been facing this problem for a long time in my gnu/linux too. Surprised to see it has been reported only in Windows.
In short following are the specifications:
Linux Kernel : 3.5.2
Distro: Porteus ( https://en.wikipedia.org/wiki/Porteus_%28operating_system%29 )
Desktop: Trinity (aka. fork of KDE 3.5 )
Python version : 2.6.4
IPython version : 0.12
I run Ipython in terminal by the simple "ipython" command. (no extra arguments)
Description of problem:
This usually happens when i leave Ipython terminal open for a few days.
I typically have the numpy, scipy and matplotlib modules loaded.
The machine doesnot gets slow. Infact the commands run by Ipython are also not slow.
Only the keyboard input is slow.
Even if I copy-paste some content into Ipython, it prints each pasted letter one by one with a uniform delay.
While this pasted content is being printed slowly on screen or when i use backspace to remove it, we can see the CPU percentage use of Ipython shooting significantly up in htop.
If I exit the session, and start again, everything works fine as usual.
oliford commentedon May 17, 2013
I and my office mate both see this bug in linux too. So here's our experiences, in case it helps isolate it:
I'm using XUbuntu 12.04 (Xfce), ipython 0.12.1 and my office mate also on Linux Mint with ipython 13.1-rc2.
We both see it slowing only the keyboard input (including just moving the cursor) and pasting after use of matplotlib and numpy for some time. I do also use scipy but my officemate doesn't. We're both using the GTKAgg backend.
It doesn't occur immediately, but after some time with use of plotting etc.
We both see significant disk activity during moving the cursor back and forth (as in #1184, perhaps I should have posted this there? I don't want to double post though).
oliford commentedon May 17, 2013
I've found that our problem is exactly that in matplotlib/matplotlib#1530 relating to writing .local/share/recently-used.xbel after opening the GTK (maybe also Qt) save figure dialog once (but not necessarily saving anything). I'll wander over there now.
danielballan commentedon Jun 11, 2013
I have the same experience as @oliford on Ubuntu 12.04, iPython 0.14.dev, GTKAgg.
danielballan commentedon Jun 11, 2013
One man's testimonial: I resolved this issue by installing the dev version of matplotlib. Perhaps this commit in this issue cited by @oliford did the trick.
minrk commentedon Jul 6, 2013
Based on @danielballan's feedback, I would be inclined to close.
ivanov commentedon Jul 17, 2013
closing based on the conversation around matplotlib/matplotlib#1530.
Merge pull request ipython#815 from cboos/issue481-qt4-input-hook