This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Callable object, to test various parts of ipython's info system. | |
Run this file and then do f(, g( or c( or c.method( in the qt gui to see the | |
various tooltips. | |
""" | |
class Call(object): | |
"""This is the class docstring.""" | |
def __init__(self, x, y=1): |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
import numpy as np | |
def bin_perm_rep(ndim,a=0,b=1): | |
"""bin_perm_rep(ndim) -> ndim permutations with repetitions of (a,b). | |
Returns an array with all the possible permutations with repetitions of | |
(0,1) in ndim dimensions. The array is shaped as (2**ndim,ndim), and is | |
ordered with the last index changing fastest. For examble, for ndim=3: | |
Examples: |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Another change | |
// Testing gists on the web | |
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Strict//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-strict.dtd"> | |
<html xmlns="http://www.w3.org/1999/xhtml"> | |
<head> | |
<meta http-equiv="content-type" content="text/html; charset=utf-8"/> | |
<title>Google AJAX Language API - Basic Transliteration</title> | |
<script type="text/javascript" src="//www.google.com/jsapi"></script> | |
<script type="text/javascript"> | |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
"""Launchpad to github bug migration script. | |
There's a ton of code from Hydrazine copied here: | |
https://launchpad.net/hydrazine | |
WARNING: this code was written for the Github issues v2 API, and has *not* been ported to v3. If anyone finds it useful and ports it, please drop me a pull request. | |
Usage | |
----- |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
"""Contours with overlap control. | |
This script generates widely spaced black contours, with a gray patch in a | |
subregion where more finely-spaced colored contours are visible. The gray | |
patch covers the black contours. | |
""" | |
import numpy as np | |
import matplotlib.mlab as mlab | |
from matplotlib.patches import Rectangle |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
# -*- encoding: utf-8 | |
#from IPython.external | |
import sys | |
import argparse | |
if __name__ == '__main__': | |
parser = argparse.ArgumentParser() | |
paa = parser.add_argument |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
====================================================================== | |
ERROR: test pushing and pulling functions | |
---------------------------------------------------------------------- | |
Traceback (most recent call last): | |
File "/home/fperez/usr/lib/python2.6/site-packages/IPython/parallel/tests/test_view.py", line 92, in test_push_pull_function | |
self.assertEqual(r(1.0), testf(1.0)) | |
TypeError: 'AsyncResult' object is not callable | |
====================================================================== | |
FAIL: test_queue_status (IPython.parallel.tests.test_client.TestClient) |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
"""Simple script to remove nose-style parametric tests and turn them into | |
normal ones. | |
Usage: | |
param2normal.py file1.py file2.py ... | |
By default it overwrites the files in-place, you can change that below in the | |
__main__ section. |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
#!/usr/bin/env python | |
""" | |
file with deliberate errors to check IPython. | |
""" | |
from numpy import * | |
import time,sys | |
import sys |
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
longs[junk]> nosetests matplotlib | |
/home/fperez/usr/opt/lib/python2.7/site-packages/matplotlib/__init__.py:923: UserWarning: This call to matplotlib.use() has no effect | |
because the the backend has already been chosen; | |
matplotlib.use() must be called *before* pylab, matplotlib.pyplot, | |
or matplotlib.backends is imported for the first time. | |
if warn: warnings.warn(_use_error_msg) | |
/home/fperez/usr/opt/lib/python2.7/site-packages/matplotlib/font_manager.py:1210: UserWarning: findfont: Font family ['sans-serif'] not found. Falling back to Bitstream Vera Sans | |
(prop.get_family(), self.defaultFamily[fontext])) |
OlderNewer