##// END OF EJS Templates
Merge pull request #4305 from minrk/even-more-ways-to-get-ifaces...
Merge pull request #4305 from minrk/even-more-ways-to-get-ifaces Add even more ways to populate localinterfaces use netifaces for faster IPython.utils.localinterfaces when availlable, Parse subprocess output from ifconfig / ip addr / ipconfig. Lower priority than netifaces, but still higher priority than socket.gethostbyname. Fallback to gethostname otherwise. Should be much faster in worst case scenario where machine are badly configurred and can wait up to ~30s to start ipython. Slighly slower in other cases.

File last commit:

r9190:20a102a5
r12911:aeeb7f5a merge
Show More
pylab_figshow.py
23 lines | 661 B | text/x-python | PythonLexer
"""Manual test for figure.show() in the inline matplotlib backend.
This script should be loaded for interactive use (via %load) into a qtconsole
or notebook initialized with the pylab inline backend.
Expected behavior: only *one* copy of the figure is shown.
For further details:
https://github.com/ipython/ipython/issues/1612
https://github.com/matplotlib/matplotlib/issues/835
"""
import numpy as np
import matplotlib.pyplot as plt
plt.ioff()
x = np.random.uniform(-5, 5, size=(100))
y = np.random.uniform(-5, 5, size=(100))
f = plt.figure()
plt.scatter(x, y)
plt.plot(y)
f.show()