pyenv.py 1.45 KB
Newer Older
1
2
3
4
5
6
7
from __future__ import division, absolute_import, print_function
import sys
if sys.version_info < (3,):
    range = xrange
else:
    unicode = str

8
9
10
11
from matplotlib import rc
from matplotlib import rcParams

font_size=14
12
13
rcParams["backend"] = "PDF"
rcParams["figure.figsize"] = (4, 3)
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
rcParams["font.family"] = "Serif"
rcParams["font.serif"] = ["Palatino"]
rcParams["font.size"] = font_size
rcParams["axes.labelsize"] = font_size
rcParams["xtick.labelsize"] = font_size - 2
rcParams["ytick.labelsize"] = font_size - 2
rcParams["legend.numpoints"] = 1
rcParams["legend.fontsize"] = "small"
rcParams["lines.markersize"] = 4
rcParams["figure.subplot.right"] = 0.95
rcParams["figure.subplot.top"] = 0.95
rcParams["figure.subplot.right"] = 0.95
rcParams["figure.subplot.top"] = 0.95
rcParams["figure.subplot.left"] = 0.2
rcParams["figure.subplot.bottom"] = 0.2

30
31
rcParams["image.cmap"] = "hot"

32
33
34
35
36
37
38
39
rcParams["text.usetex"] = True

rcParams["ps.usedistiller"] = "xpdf"
rcParams["pdf.compression"] = 9
rcParams["ps.useafm"] = True
rcParams["path.simplify"] = True
rcParams["text.latex.preamble"] = [#"\usepackage{times}",
                                   #"\usepackage{euler}",
Tiago Peixoto's avatar
Tiago Peixoto committed
40
41
                                   r"\usepackage{amssymb}",
                                   r"\usepackage{amsmath}"]
42
43
44
45

import scipy
import scipy.stats
import numpy as np
46
47
from pylab import *
from numpy import *
48
import graph_tool.all as gt
49
50
51
52
53
54

figure()

gt.openmp_set_num_threads(1)
np.random.seed(42)
gt.seed_rng(42)