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
sphinx-build -b html -d _build/doctrees -D latex_paper_size=letter . _build/html | |
sphinx-build -b html -d _build/doctrees -D latex_paper_size=letter . _build/html |
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
from __future__ import print_function | |
import sys | |
import timeit | |
import numpy as np | |
np.random.seed(0) | |
ndata=20000 | |
# data to ne interpolated | |
xp = np.linspace(0, 10, 1+ndata) |
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
MathJax doesn't directly support the Angstrom symbol, TeX's \AA. This is painful in many | |
fields, notably those that work with X-rays. | |
To use mathjax with the Sphinx documentation system, one would put | |
extensions = ['sphinx.ext.mathjax', ...] | |
in conf.py. But this will not understand \AA as the Angstrom symbol. | |
The solution is to add a Mathjax configuration script to each HTML file produced by sphinx. |
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 | |
"""Convert PDF to PNG with convert program | |
""" | |
import sys | |
import subprocess | |
import getopt | |
convert = "convert -antialias -alpha on -channel rgba -fuzz 5%" | |
density = 600 | |
quality = 90 |
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 python2.7 | |
""" | |
translate ISI bibliography (in plaintext) to bibtex | |
isi2bib savedrecs.txt > savedrecs.bib | |
Notes: | |
1. this script tries very hard to make sensible lists | |
of author names, but the task is hard, and results | |
should be checked carefully. |