├── .gitignore
├── CHANGES
├── LICENSE
├── MANIFEST.in
├── README.md
├── doc
├── Makefile
├── _build
│ ├── doctrees
│ │ ├── documentation.doctree
│ │ ├── environment.pickle
│ │ ├── host.doctree
│ │ ├── index.doctree
│ │ ├── source
│ │ │ ├── faerun.doctree
│ │ │ └── modules.doctree
│ │ └── tutorial.doctree
│ ├── html
│ │ ├── .buildinfo
│ │ ├── _images
│ │ │ ├── drugbank_2d_dark.png
│ │ │ ├── drugbank_2d_light.png
│ │ │ ├── tutorial.png
│ │ │ ├── tutorial_host_label.png
│ │ │ ├── tutorial_host_search.png
│ │ │ └── tutorial_host_search_2.png
│ │ ├── _sources
│ │ │ ├── documentation.rst.txt
│ │ │ ├── host.rst.txt
│ │ │ ├── index.rst.txt
│ │ │ ├── source
│ │ │ │ ├── faerun.rst.txt
│ │ │ │ └── modules.rst.txt
│ │ │ └── tutorial.rst.txt
│ │ ├── _static
│ │ │ ├── ajax-loader.gif
│ │ │ ├── basic.css
│ │ │ ├── comment-bright.png
│ │ │ ├── comment-close.png
│ │ │ ├── comment.png
│ │ │ ├── css
│ │ │ │ ├── badge_only.css
│ │ │ │ └── theme.css
│ │ │ ├── doctools.js
│ │ │ ├── documentation_options.js
│ │ │ ├── down-pressed.png
│ │ │ ├── down.png
│ │ │ ├── drugbank_2d_dark.png
│ │ │ ├── drugbank_2d_light.png
│ │ │ ├── file.png
│ │ │ ├── fonts
│ │ │ │ ├── Inconsolata-Bold.ttf
│ │ │ │ ├── Inconsolata-Regular.ttf
│ │ │ │ ├── Inconsolata.ttf
│ │ │ │ ├── Lato-Bold.ttf
│ │ │ │ ├── Lato-Regular.ttf
│ │ │ │ ├── Lato
│ │ │ │ │ ├── lato-bold.eot
│ │ │ │ │ ├── lato-bold.ttf
│ │ │ │ │ ├── lato-bold.woff
│ │ │ │ │ ├── lato-bold.woff2
│ │ │ │ │ ├── lato-bolditalic.eot
│ │ │ │ │ ├── lato-bolditalic.ttf
│ │ │ │ │ ├── lato-bolditalic.woff
│ │ │ │ │ ├── lato-bolditalic.woff2
│ │ │ │ │ ├── lato-italic.eot
│ │ │ │ │ ├── lato-italic.ttf
│ │ │ │ │ ├── lato-italic.woff
│ │ │ │ │ ├── lato-italic.woff2
│ │ │ │ │ ├── lato-regular.eot
│ │ │ │ │ ├── lato-regular.ttf
│ │ │ │ │ ├── lato-regular.woff
│ │ │ │ │ └── lato-regular.woff2
│ │ │ │ ├── RobotoSlab-Bold.ttf
│ │ │ │ ├── RobotoSlab-Regular.ttf
│ │ │ │ ├── RobotoSlab
│ │ │ │ │ ├── roboto-slab-v7-bold.eot
│ │ │ │ │ ├── roboto-slab-v7-bold.ttf
│ │ │ │ │ ├── roboto-slab-v7-bold.woff
│ │ │ │ │ ├── roboto-slab-v7-bold.woff2
│ │ │ │ │ ├── roboto-slab-v7-regular.eot
│ │ │ │ │ ├── roboto-slab-v7-regular.ttf
│ │ │ │ │ ├── roboto-slab-v7-regular.woff
│ │ │ │ │ └── roboto-slab-v7-regular.woff2
│ │ │ │ ├── fontawesome-webfont.eot
│ │ │ │ ├── fontawesome-webfont.svg
│ │ │ │ ├── fontawesome-webfont.ttf
│ │ │ │ ├── fontawesome-webfont.woff
│ │ │ │ └── fontawesome-webfont.woff2
│ │ │ ├── jquery-3.2.1.js
│ │ │ ├── jquery.js
│ │ │ ├── js
│ │ │ │ ├── modernizr.min.js
│ │ │ │ └── theme.js
│ │ │ ├── language_data.js
│ │ │ ├── minus.png
│ │ │ ├── plus.png
│ │ │ ├── pygments.css
│ │ │ ├── searchtools.js
│ │ │ ├── tutorial.png
│ │ │ ├── tutorial_host_label.png
│ │ │ ├── tutorial_host_search.png
│ │ │ ├── tutorial_host_search_2.png
│ │ │ ├── underscore-1.3.1.js
│ │ │ ├── underscore.js
│ │ │ ├── up-pressed.png
│ │ │ ├── up.png
│ │ │ └── websupport.js
│ │ ├── documentation.html
│ │ ├── genindex.html
│ │ ├── host.html
│ │ ├── index.html
│ │ ├── objects.inv
│ │ ├── py-modindex.html
│ │ ├── search.html
│ │ ├── searchindex.js
│ │ ├── source
│ │ │ ├── faerun.html
│ │ │ └── modules.html
│ │ └── tutorial.html
│ ├── latex
│ │ ├── Faerun.aux
│ │ ├── Faerun.fdb_latexmk
│ │ ├── Faerun.fls
│ │ ├── Faerun.idx
│ │ ├── Faerun.ilg
│ │ ├── Faerun.ind
│ │ ├── Faerun.out
│ │ ├── Faerun.pdf
│ │ ├── Faerun.tex
│ │ ├── Faerun.toc
│ │ ├── LICRcyr2utf8.xdy
│ │ ├── LICRlatin2utf8.xdy
│ │ ├── LatinRules.xdy
│ │ ├── Makefile
│ │ ├── drugbank_2d_dark.png
│ │ ├── drugbank_2d_light.png
│ │ ├── footnotehyper-sphinx.sty
│ │ ├── latexmkjarc
│ │ ├── latexmkrc
│ │ ├── make.bat
│ │ ├── python.ist
│ │ ├── sphinx.sty
│ │ ├── sphinx.xdy
│ │ ├── sphinxhighlight.sty
│ │ ├── sphinxhowto.cls
│ │ ├── sphinxmanual.cls
│ │ ├── sphinxmulticell.sty
│ │ ├── tutorial.png
│ │ ├── tutorial_host_label.png
│ │ ├── tutorial_host_search.png
│ │ └── tutorial_host_search_2.png
│ └── markdown
│ │ ├── documentation.md
│ │ ├── host.md
│ │ ├── index.md
│ │ └── tutorial.md
├── _static
│ ├── drugbank_2d_dark.png
│ ├── drugbank_2d_light.png
│ ├── tutorial.png
│ ├── tutorial_host_label.png
│ ├── tutorial_host_search.png
│ └── tutorial_host_search_2.png
├── conf.py
├── documentation.rst
├── host.rst
├── index.rst
├── make.bat
└── tutorial.rst
├── examples
├── drugbank.smi
├── example.py
├── example_sin.py
├── example_web.py
├── example_web_3d.py
├── helix.html
├── helix.js
├── index.html
├── index.js
├── index.pickle
├── test.html
├── test.js
├── tutorial.py
└── tutorial_host.py
├── faerun
├── __init__.py
├── assets
│ └── index_static.html
├── faerun.py
├── plot.py
├── template_default.j2
├── template_reaction_smiles.j2
├── template_smiles.j2
├── template_url_image.j2
└── web.py
├── notebook
├── faerun.ipynb
├── helix.html
├── requirements.txt
├── runtime.txt
├── sin.html
└── sine.html
├── requirements.txt
└── setup.py
/.gitignore:
--------------------------------------------------------------------------------
1 | # Byte-compiled / optimized / DLL files
2 | __pycache__/
3 | *.py[cod]
4 | *$py.class
5 |
6 | # C extensions
7 | *.so
8 |
9 | # Distribution / packaging
10 | .Python
11 | build/
12 | develop-eggs/
13 | dist/
14 | downloads/
15 | eggs/
16 | .eggs/
17 | lib/
18 | lib64/
19 | parts/
20 | sdist/
21 | var/
22 | wheels/
23 | *.egg-info/
24 | .installed.cfg
25 | *.egg
26 | MANIFEST
27 |
28 | # PyInstaller
29 | # Usually these files are written by a python script from a template
30 | # before PyInstaller builds the exe, so as to inject date/other infos into it.
31 | *.manifest
32 | *.spec
33 |
34 | # Installer logs
35 | pip-log.txt
36 | pip-delete-this-directory.txt
37 |
38 | # Unit test / coverage reports
39 | htmlcov/
40 | .tox/
41 | .coverage
42 | .coverage.*
43 | .cache
44 | nosetests.xml
45 | coverage.xml
46 | *.cover
47 | .hypothesis/
48 | .pytest_cache/
49 |
50 | # Translations
51 | *.mo
52 | *.pot
53 |
54 | # Django stuff:
55 | *.log
56 | local_settings.py
57 | db.sqlite3
58 |
59 | # Flask stuff:
60 | instance/
61 | .webassets-cache
62 |
63 | # Scrapy stuff:
64 | .scrapy
65 |
66 | # Sphinx documentation
67 | # docs/_build
68 |
69 | # PyBuilder
70 | target/
71 |
72 | # Jupyter Notebook
73 | .ipynb_checkpoints
74 |
75 | # pyenv
76 | .python-version
77 |
78 | # celery beat schedule file
79 | celerybeat-schedule
80 |
81 | # SageMath parsed files
82 | *.sage.py
83 |
84 | # Environments
85 | .env
86 | .venv
87 | env/
88 | venv/
89 | ENV/
90 | env.bak/
91 | venv.bak/
92 |
93 | # Spyder project settings
94 | .spyderproject
95 | .spyproject
96 |
97 | # Rope project settings
98 | .ropeproject
99 |
100 | # mkdocs documentation
101 | /site
102 |
103 | # mypy
104 | .mypy_cache/
105 |
106 | # Data
107 | data.js
108 | *.faerun
--------------------------------------------------------------------------------
/CHANGES:
--------------------------------------------------------------------------------
1 | # Changelog
2 | ## [0.3.2] - 2019-09-20
3 | ### Added
4 | - Possibility to load custom jinja2 templates by supplying their path to the template argument (if the value for template is "default", "smiles", or "url_image", the internal templates will be loaded).
5 | ## [0.3.3] - 2019-10-09
6 | ### Added
7 | - The possibility to export screenshots at 2x the on-screen resolution
8 | ### Changed
9 | - The preserveDrawingBuffer option of Lore is set to true now in order to allow for screenshots
10 | ## [0.3.4] - 2019-11-09
11 | ### Bugfix
12 | - Fixed bug where a list of legend_labels was not recognized as such
13 | ## [0.3.5] - 2019-11-11
14 | ### Bugfix
15 | - Fixed bug where a list of legend_labels was not recognized as such, again
16 | ## [0.3.6] - 2019-12-01
17 | ### Changed
18 | - Updated lore to version 1.1.10
19 | ## [0.3.7] - 2019-12-01
20 | ### Changed
21 | - Fixed bug where hidden geometires (scatters) were not moved
22 | ## [0.3.8] - 2020-04-22
23 | ### Bugfix
24 | - Defining sizes for series is now possible just as it is with colours
25 | ## [0.3.9] - 2020-04-22
26 | ### Changes
27 | - Rounding sizes to reduce file size
28 | ## [0.3.10] - 2020-04-27
29 | ### Changes
30 | - Updated SmilesDrawer version
--------------------------------------------------------------------------------
/LICENSE:
--------------------------------------------------------------------------------
1 | MIT License
2 |
3 | Copyright (c) 2018 Reymond Group, University of Bern
4 |
5 | Permission is hereby granted, free of charge, to any person obtaining a copy
6 | of this software and associated documentation files (the "Software"), to deal
7 | in the Software without restriction, including without limitation the rights
8 | to use, copy, modify, merge, publish, distribute, sublicense, and/or sell
9 | copies of the Software, and to permit persons to whom the Software is
10 | furnished to do so, subject to the following conditions:
11 |
12 | The above copyright notice and this permission notice shall be included in all
13 | copies or substantial portions of the Software.
14 |
15 | THE SOFTWARE IS PROVIDED "AS IS", WITHOUT WARRANTY OF ANY KIND, EXPRESS OR
16 | IMPLIED, INCLUDING BUT NOT LIMITED TO THE WARRANTIES OF MERCHANTABILITY,
17 | FITNESS FOR A PARTICULAR PURPOSE AND NONINFRINGEMENT. IN NO EVENT SHALL THE
18 | AUTHORS OR COPYRIGHT HOLDERS BE LIABLE FOR ANY CLAIM, DAMAGES OR OTHER
19 | LIABILITY, WHETHER IN AN ACTION OF CONTRACT, TORT OR OTHERWISE, ARISING FROM,
20 | OUT OF OR IN CONNECTION WITH THE SOFTWARE OR THE USE OR OTHER DEALINGS IN THE
21 | SOFTWARE.
--------------------------------------------------------------------------------
/MANIFEST.in:
--------------------------------------------------------------------------------
1 | include faerun/template_default.j2
2 | include faerun/template_smiles.j2
3 | include faerun/template_reaction_smiles.j2
4 | include faerun/template_url_image.j2
5 | include faerun/assets/index_static.html
6 |
--------------------------------------------------------------------------------
/doc/Makefile:
--------------------------------------------------------------------------------
1 | # Minimal makefile for Sphinx documentation
2 | #
3 |
4 | # You can set these variables from the command line, and also
5 | # from the environment for the first two.
6 | SPHINXOPTS ?=
7 | SPHINXBUILD ?= sphinx-build
8 | SOURCEDIR = .
9 | BUILDDIR = _build
10 |
11 | # Put it first so that "make" without argument is like "make help".
12 | help:
13 | @$(SPHINXBUILD) -M help "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
14 |
15 | .PHONY: help Makefile
16 |
17 | # Catch-all target: route all unknown targets to Sphinx using the new
18 | # "make mode" option. $(O) is meant as a shortcut for $(SPHINXOPTS).
19 | %: Makefile
20 | @$(SPHINXBUILD) -M $@ "$(SOURCEDIR)" "$(BUILDDIR)" $(SPHINXOPTS) $(O)
21 |
--------------------------------------------------------------------------------
/doc/_build/doctrees/documentation.doctree:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/doctrees/documentation.doctree
--------------------------------------------------------------------------------
/doc/_build/doctrees/environment.pickle:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/doctrees/environment.pickle
--------------------------------------------------------------------------------
/doc/_build/doctrees/host.doctree:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/doctrees/host.doctree
--------------------------------------------------------------------------------
/doc/_build/doctrees/index.doctree:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/doctrees/index.doctree
--------------------------------------------------------------------------------
/doc/_build/doctrees/source/faerun.doctree:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/doctrees/source/faerun.doctree
--------------------------------------------------------------------------------
/doc/_build/doctrees/source/modules.doctree:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/doctrees/source/modules.doctree
--------------------------------------------------------------------------------
/doc/_build/doctrees/tutorial.doctree:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/doctrees/tutorial.doctree
--------------------------------------------------------------------------------
/doc/_build/html/.buildinfo:
--------------------------------------------------------------------------------
1 | # Sphinx build info version 1
2 | # This file hashes the configuration used when building these files. When it is not found, a full rebuild will be done.
3 | config: 22232186176eb38a1f262fb47044552f
4 | tags: 645f666f9bcd5a90fca523b33c5a78b7
5 |
--------------------------------------------------------------------------------
/doc/_build/html/_images/drugbank_2d_dark.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_images/drugbank_2d_dark.png
--------------------------------------------------------------------------------
/doc/_build/html/_images/drugbank_2d_light.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_images/drugbank_2d_light.png
--------------------------------------------------------------------------------
/doc/_build/html/_images/tutorial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_images/tutorial.png
--------------------------------------------------------------------------------
/doc/_build/html/_images/tutorial_host_label.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_images/tutorial_host_label.png
--------------------------------------------------------------------------------
/doc/_build/html/_images/tutorial_host_search.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_images/tutorial_host_search.png
--------------------------------------------------------------------------------
/doc/_build/html/_images/tutorial_host_search_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_images/tutorial_host_search_2.png
--------------------------------------------------------------------------------
/doc/_build/html/_sources/documentation.rst.txt:
--------------------------------------------------------------------------------
1 | Documentation
2 | -------------
3 |
4 | Faerun
5 | ^^^^^^
6 | .. autoclass:: faerun.Faerun
7 | :members:
8 |
9 | Web
10 | ^^^
11 | .. autofunction:: faerun.host
12 |
--------------------------------------------------------------------------------
/doc/_build/html/_sources/host.rst.txt:
--------------------------------------------------------------------------------
1 | Web
2 | ---
3 |
4 | Introduction
5 | ^^^^^^^^^^^^
6 | While small plots can easily be created and stored in a single HTML and JavaScript file, which are then loaded completely in the browsers memory, this is not possible for larger data sets due to browser limitations.
7 | In order to solve this problem, Faerun includes a small HTTP server (based on cherrypy) to serve the data to the browser.
8 |
9 | Creating Faerun Data Files
10 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
11 | As shown in :doc:`tutorial`, Faerun can save data as ``.faerun`` data files using ``pickle``.
12 |
13 | .. code-block:: python
14 |
15 | with open('helix.faerun', 'wb+') as handle:
16 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
17 |
18 | Starting a Faerun Web Server
19 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
20 | .. code-block:: python
21 |
22 | from faerun import host
23 |
24 | host('helix.faerun', label_type='default',
25 | theme='dark')
26 |
27 | Formatting Labels
28 | ^^^^^^^^^^^^^^^^^
29 | Labels can be formatted by defining a custom ``label_formatter``. If no ``label_formatter`` is provided to the ``host`` function, the default is used:
30 |
31 | .. code-block:: python
32 |
33 | label_formatter = lambda label, index, name: label.split('__')[0]
34 |
35 | This default splits the label value on ``'__'`` to store different labels and enable search on different values the the displayed labels. See "Searching" for details. Defining a custom label formatter is straight forward. As an example, let's prefix each label with a string and add their index and layer name:
36 |
37 | .. code-block:: python
38 |
39 | def custom_label_formatter(label, index, name):
40 | return f'Example: {label} ({index}, {name})'
41 |
42 | host('helix.faerun', label_type='default',
43 | theme='dark', label_formatter=custom_label_formatter)
44 |
45 | This function is then called whenever a label is requested from the server. In addition to the argument ``label``, the arguments ``index`` and ``name`` can be used to further customize the displayed label and represent the integer index of the data point and the data layer they belong to (e.g. the name defined with ``add_scatter``).
46 |
47 | .. image:: _static/tutorial_host_label.png
48 | :alt: Example of a custom label formatter.
49 |
50 | Adding Hyperlinks
51 | ^^^^^^^^^^^^^^^^^
52 | Faerun allows to link the data to an arbitrary URL which can be visited upon double-clicking a data point. In order to do this, a ``link_formatter`` has to be provided. This works similar to customizing the label.
53 |
54 | .. code-block:: python
55 |
56 | def custom_link_formatter(label, index, name):
57 | return f'https://www.google.com/search?q={label}'
58 |
59 | host('helix.faerun', label_type='default',
60 | theme='dark', link_formatter=custom_link_formatter)
61 |
62 |
63 | Searching
64 | ^^^^^^^^^
65 | The hosted version of a Faerun visualization also allows for searching. As a default, the search searches for exact matches in labels (substring or regex searches are not possible at this time).
66 |
67 | .. image:: _static/tutorial_host_search.png
68 | :alt: The result of a search.
69 |
70 | However, the search can be customized. As described in "Formatting Labels", additional label values can be added by separating them using ``'__'``.
71 |
72 | .. code-block:: python
73 |
74 | c = np.random.randint(0, 2, len(x))
75 | labels = [''] * len(c)
76 |
77 | for i, e in enumerate(c):
78 | labels[i] = str(e) + '__' + str(i % 20)
79 |
80 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': labels}
81 |
82 | The above examples adds an additional label value and as default, the second label value is then used by the search.
83 |
84 | .. image:: _static/tutorial_host_search_2.png
85 | :alt: The result of a custom search.
86 |
87 | If there are additional label values, the search index can be set using the ``search_index`` argument.
88 |
89 | Add Info / Documentation
90 | ^^^^^^^^^^^^^^^^^^^^^^^^
91 | As the visualization is ready to be deployed to a publicly accessible web server, it might be of interest to add a documentation. The ``host`` method supports the argument ``info`` that accepts a (markdown formatted) string. This information is the desplayed on the generated web page.
92 |
93 | .. code-block:: python
94 |
95 | info = ('#Welcome to Fearun',
96 | 'This is a small Faerun example.'
97 | '',
98 | 'Yay markdown! This means that you can easily:',
99 | '- Add lists',
100 | '- Build tables',
101 | '- Insert images and links',
102 | '- Add code examples',
103 | '- ...'
104 | )
105 |
106 | host('helix.faerun', label_type='default', theme='dark',
107 | label_formatter=custom_label_formatter, link_formatter=custom_link_formatter,
108 | info='\n'.join(info))
109 |
110 | An info button is then shown next to the screenshot button, which upon click opens a window containing the info.
111 |
112 | Complete Example
113 | ^^^^^^^^^^^^^^^^
114 |
115 | .. code-block:: python
116 |
117 | import pickle
118 | import numpy as np
119 | from faerun import Faerun, host
120 |
121 |
122 | def main():
123 | f = Faerun(title='faerun-example', clear_color='#222222', coords=False, view='free')
124 |
125 | x = np.linspace(0, 12.0, 326)
126 | y = np.sin(np.pi * x)
127 | z = np.cos(np.pi * x)
128 | c = np.random.randint(0, 2, len(x))
129 |
130 | labels = [''] * len(c)
131 |
132 | for i, e in enumerate(c):
133 | labels[i] = str(e) + '__' + str(i % 20)
134 |
135 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': labels}
136 |
137 | f.add_scatter('helix', data, shader='sphere', colormap='Dark2', point_scale=5.0,
138 | categorical=True, has_legend=True, legend_labels=[(0, 'Zero'), (1, 'One')])
139 |
140 | f.plot('helix')
141 |
142 | with open('helix.faerun', 'wb+') as handle:
143 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
144 |
145 | def custom_label_formatter(label, index, name):
146 | return f'Example: {label} ({index}, {name})'
147 |
148 | def custom_link_formatter(label, index, name):
149 | return f'https://www.google.com/search?q={label}'
150 |
151 | info = ('#Welcome to Fearun',
152 | 'This is a small Faerun example.'
153 | '',
154 | 'Yay markdown! This means that you can easily:',
155 | '- Add lists',
156 | '- Build tables',
157 | '- Insert images and links',
158 | '- Add code examples',
159 | '- ...'
160 | )
161 |
162 | host('helix.faerun', label_type='default', theme='dark',
163 | label_formatter=custom_label_formatter, link_formatter=custom_link_formatter,
164 | info='\n'.join(info))
165 |
166 |
167 | if __name__ == '__main__':
168 | main()
169 |
170 |
--------------------------------------------------------------------------------
/doc/_build/html/_sources/index.rst.txt:
--------------------------------------------------------------------------------
1 | Welcome to Faerun's documentation!
2 | ==================================
3 | Here are some teasers.
4 |
5 | .. image:: _static/drugbank_2d_light.png
6 | :alt: Example of Drugbank compounds in 2d with the light theme.
7 |
8 | .. image:: _static/drugbank_2d_dark.png
9 | :alt: Example of Drugbank compounds in 2d with the dark theme.
10 |
11 | Table of Contents
12 | -----------------
13 |
14 | .. toctree::
15 |
16 | tutorial
17 | host
18 | documentation
19 |
--------------------------------------------------------------------------------
/doc/_build/html/_sources/source/faerun.rst.txt:
--------------------------------------------------------------------------------
1 | faerun package
2 | ==============
3 |
4 | Submodules
5 | ----------
6 |
7 | faerun.faerun module
8 | --------------------
9 |
10 | .. automodule:: faerun.faerun
11 | :members:
12 | :undoc-members:
13 | :show-inheritance:
14 |
15 | faerun.web module
16 | -----------------
17 |
18 | .. automodule:: faerun.web
19 | :members:
20 | :undoc-members:
21 | :show-inheritance:
22 |
23 |
24 | Module contents
25 | ---------------
26 |
27 | .. automodule:: faerun
28 | :members:
29 | :undoc-members:
30 | :show-inheritance:
31 |
--------------------------------------------------------------------------------
/doc/_build/html/_sources/source/modules.rst.txt:
--------------------------------------------------------------------------------
1 | faerun
2 | ======
3 |
4 | .. toctree::
5 | :maxdepth: 4
6 |
7 | faerun
8 |
--------------------------------------------------------------------------------
/doc/_build/html/_sources/tutorial.rst.txt:
--------------------------------------------------------------------------------
1 | Getting Started
2 | ---------------
3 |
4 | Installation
5 | ^^^^^^^^^^^^
6 | Faerun can be installed using pip.
7 |
8 | .. code-block:: bash
9 |
10 | pip install faerun
11 |
12 | In order to use it in a script, the class ``Faerun`` has to be imported from the package.
13 |
14 | .. code-block:: python
15 |
16 | from faerun import Faerun
17 |
18 | That's it for the installation.
19 |
20 | Create a Plot Document
21 | ^^^^^^^^^^^^^^^^^^^^^^
22 | In order to plot, a plot document has to be created. To do so, create an instance of the class ``Faerun``
23 |
24 | .. code-block:: python
25 |
26 | from faerun import Faerun
27 |
28 | f = Faerun(title='faerun-example', clear_color='#222222', coords=False, view='free')
29 |
30 | Here, we set the ``title`` of the plot document. This will be used as the title of the HTML document. The clear color of the canvas, which is the background color of the plot, is set to ``'#222222'`` (which is the hex-code for a dark gray).
31 | The drawing of coordinate axes is disabled by setting ``coords=False`` and since we want to draw 3D data, the argument ``view`` is set to ``'free'`` to enable the user to pan and rotate the plot.
32 |
33 | Preparing Data for Plotting
34 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
35 | The next step is to prepare the data which is to be plotted. In the tutorial, we will just generate some nice looking data using ``numpy``.
36 |
37 | .. code-block:: python
38 |
39 | import numpy as np
40 |
41 | x = np.linspace(0, 12.0, 326)
42 | y = np.sin(np.pi * x)
43 | z = np.cos(np.pi * x)
44 | c = np.random.randint(0, 6, len(x))
45 |
46 | This data can then be wrapped in a ``dict``. In addition, ``DataFrame`` from the ``pandas`` package are also supported by faerun.
47 | In the example, the same values are used for the colors ``c`` and labels ``labels``.
48 |
49 | .. code-block:: python
50 |
51 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': c}
52 |
53 | Adding a Scatter Layer
54 | ^^^^^^^^^^^^^^^^^^^^^^
55 | Given the ``Faerun`` instance and the data, a scatter plot can be created using the method ``add_scatter``.
56 |
57 | .. code-block:: python
58 |
59 | f.add_scatter('helix', data, shader='sphere', colormap='Dark2', point_scale=5.0,
60 | categorical=True, has_legend=True, legend_labels=[(0, 'Zero'), (1, 'One')])
61 |
62 | The data is added as a scatter layer named helix. The chose shader will render the data points as
63 | spheres (with diffuse and specular lighting) of size 5.0 with colors from the ``matplotlib`` colormap ``'Dark2'``.
64 | As the ``c`` is categorical, the parameter ``categorical`` is set to ``True``, otherwise ``matplotlib`` will mess up the values.
65 |
66 | Finally, ``has_legend=True`` adds the scatter layer to the legend and ``legend_labels`` is a ``list`` of ``tuple``, associating values with a label.
67 |
68 | Saving to HTML
69 | ^^^^^^^^^^^^^^
70 | The faerun document can the be plotted to an HTML document with an accompanying JavaScript data file.
71 |
72 | .. code-block:: python
73 |
74 | f.plot('helix')
75 |
76 | This saves the plot as ``helix.html` and ``helix.js``. The files can be opened locally or hosted on any web server.
77 |
78 | .. image:: _static/tutorial.png
79 | :alt: A helix drawn using faerun.
80 |
81 | Saving to Faerun Data File
82 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
83 | The faerun document can also be exported to a faerun data file, which in turn can then be hosted using the ``web`` module.
84 |
85 | .. code-block:: python
86 |
87 | import pickle
88 |
89 | with open('helix.faerun', 'wb+') as handle:
90 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
91 |
92 | Complete Example
93 | ^^^^^^^^^^^^^^^^
94 | .. code-block:: python
95 |
96 | import pickle
97 | import numpy as np
98 | from faerun import Faerun
99 |
100 | def main():
101 | f = Faerun(title='faerun-example', clear_color='#222222', coords=False, view='free')
102 |
103 | x = np.linspace(0, 12.0, 326)
104 | y = np.sin(np.pi * x)
105 | z = np.cos(np.pi * x)
106 | c = np.random.randint(0, 2, len(x))
107 |
108 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': c}
109 |
110 | f.add_scatter('helix', data, shader='sphere', colormap='Dark2', point_scale=5.0,
111 | categorical=True, has_legend=True, legend_labels=[(0, 'Zero'), (1, 'One')])
112 |
113 | f.plot('helix')
114 |
115 | with open('helix.faerun', 'wb+') as handle:
116 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
117 |
118 | if __name__ == '__main__':
119 | main()
120 |
121 |
--------------------------------------------------------------------------------
/doc/_build/html/_static/ajax-loader.gif:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/ajax-loader.gif
--------------------------------------------------------------------------------
/doc/_build/html/_static/comment-bright.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/comment-bright.png
--------------------------------------------------------------------------------
/doc/_build/html/_static/comment-close.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/comment-close.png
--------------------------------------------------------------------------------
/doc/_build/html/_static/comment.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/comment.png
--------------------------------------------------------------------------------
/doc/_build/html/_static/css/badge_only.css:
--------------------------------------------------------------------------------
1 | .fa:before{-webkit-font-smoothing:antialiased}.clearfix{*zoom:1}.clearfix:before,.clearfix:after{display:table;content:""}.clearfix:after{clear:both}@font-face{font-family:FontAwesome;font-weight:normal;font-style:normal;src:url("../fonts/fontawesome-webfont.eot");src:url("../fonts/fontawesome-webfont.eot?#iefix") format("embedded-opentype"),url("../fonts/fontawesome-webfont.woff") format("woff"),url("../fonts/fontawesome-webfont.ttf") format("truetype"),url("../fonts/fontawesome-webfont.svg#FontAwesome") format("svg")}.fa:before{display:inline-block;font-family:FontAwesome;font-style:normal;font-weight:normal;line-height:1;text-decoration:inherit}a .fa{display:inline-block;text-decoration:inherit}li .fa{display:inline-block}li .fa-large:before,li .fa-large:before{width:1.875em}ul.fas{list-style-type:none;margin-left:2em;text-indent:-0.8em}ul.fas li .fa{width:.8em}ul.fas li .fa-large:before,ul.fas li .fa-large:before{vertical-align:baseline}.fa-book:before{content:""}.icon-book:before{content:""}.fa-caret-down:before{content:""}.icon-caret-down:before{content:""}.fa-caret-up:before{content:""}.icon-caret-up:before{content:""}.fa-caret-left:before{content:""}.icon-caret-left:before{content:""}.fa-caret-right:before{content:""}.icon-caret-right:before{content:""}.rst-versions{position:fixed;bottom:0;left:0;width:300px;color:#fcfcfc;background:#1f1d1d;font-family:"Lato","proxima-nova","Helvetica Neue",Arial,sans-serif;z-index:400}.rst-versions a{color:#2980B9;text-decoration:none}.rst-versions .rst-badge-small{display:none}.rst-versions .rst-current-version{padding:12px;background-color:#272525;display:block;text-align:right;font-size:90%;cursor:pointer;color:#27AE60;*zoom:1}.rst-versions .rst-current-version:before,.rst-versions .rst-current-version:after{display:table;content:""}.rst-versions .rst-current-version:after{clear:both}.rst-versions .rst-current-version .fa{color:#fcfcfc}.rst-versions .rst-current-version .fa-book{float:left}.rst-versions .rst-current-version .icon-book{float:left}.rst-versions .rst-current-version.rst-out-of-date{background-color:#E74C3C;color:#fff}.rst-versions .rst-current-version.rst-active-old-version{background-color:#F1C40F;color:#000}.rst-versions.shift-up{height:auto;max-height:100%;overflow-y:scroll}.rst-versions.shift-up .rst-other-versions{display:block}.rst-versions .rst-other-versions{font-size:90%;padding:12px;color:gray;display:none}.rst-versions .rst-other-versions hr{display:block;height:1px;border:0;margin:20px 0;padding:0;border-top:solid 1px #413d3d}.rst-versions .rst-other-versions dd{display:inline-block;margin:0}.rst-versions .rst-other-versions dd a{display:inline-block;padding:6px;color:#fcfcfc}.rst-versions.rst-badge{width:auto;bottom:20px;right:20px;left:auto;border:none;max-width:300px;max-height:90%}.rst-versions.rst-badge .icon-book{float:none}.rst-versions.rst-badge .fa-book{float:none}.rst-versions.rst-badge.shift-up .rst-current-version{text-align:right}.rst-versions.rst-badge.shift-up .rst-current-version .fa-book{float:left}.rst-versions.rst-badge.shift-up .rst-current-version .icon-book{float:left}.rst-versions.rst-badge .rst-current-version{width:auto;height:30px;line-height:30px;padding:0 6px;display:block;text-align:center}@media screen and (max-width: 768px){.rst-versions{width:85%;display:none}.rst-versions.shift{display:block}}
2 |
--------------------------------------------------------------------------------
/doc/_build/html/_static/doctools.js:
--------------------------------------------------------------------------------
1 | /*
2 | * doctools.js
3 | * ~~~~~~~~~~~
4 | *
5 | * Sphinx JavaScript utilities for all documentation.
6 | *
7 | * :copyright: Copyright 2007-2019 by the Sphinx team, see AUTHORS.
8 | * :license: BSD, see LICENSE for details.
9 | *
10 | */
11 |
12 | /**
13 | * select a different prefix for underscore
14 | */
15 | $u = _.noConflict();
16 |
17 | /**
18 | * make the code below compatible with browsers without
19 | * an installed firebug like debugger
20 | if (!window.console || !console.firebug) {
21 | var names = ["log", "debug", "info", "warn", "error", "assert", "dir",
22 | "dirxml", "group", "groupEnd", "time", "timeEnd", "count", "trace",
23 | "profile", "profileEnd"];
24 | window.console = {};
25 | for (var i = 0; i < names.length; ++i)
26 | window.console[names[i]] = function() {};
27 | }
28 | */
29 |
30 | /**
31 | * small helper function to urldecode strings
32 | */
33 | jQuery.urldecode = function(x) {
34 | return decodeURIComponent(x).replace(/\+/g, ' ');
35 | };
36 |
37 | /**
38 | * small helper function to urlencode strings
39 | */
40 | jQuery.urlencode = encodeURIComponent;
41 |
42 | /**
43 | * This function returns the parsed url parameters of the
44 | * current request. Multiple values per key are supported,
45 | * it will always return arrays of strings for the value parts.
46 | */
47 | jQuery.getQueryParameters = function(s) {
48 | if (typeof s === 'undefined')
49 | s = document.location.search;
50 | var parts = s.substr(s.indexOf('?') + 1).split('&');
51 | var result = {};
52 | for (var i = 0; i < parts.length; i++) {
53 | var tmp = parts[i].split('=', 2);
54 | var key = jQuery.urldecode(tmp[0]);
55 | var value = jQuery.urldecode(tmp[1]);
56 | if (key in result)
57 | result[key].push(value);
58 | else
59 | result[key] = [value];
60 | }
61 | return result;
62 | };
63 |
64 | /**
65 | * highlight a given string on a jquery object by wrapping it in
66 | * span elements with the given class name.
67 | */
68 | jQuery.fn.highlightText = function(text, className) {
69 | function highlight(node, addItems) {
70 | if (node.nodeType === 3) {
71 | var val = node.nodeValue;
72 | var pos = val.toLowerCase().indexOf(text);
73 | if (pos >= 0 &&
74 | !jQuery(node.parentNode).hasClass(className) &&
75 | !jQuery(node.parentNode).hasClass("nohighlight")) {
76 | var span;
77 | var isInSVG = jQuery(node).closest("body, svg, foreignObject").is("svg");
78 | if (isInSVG) {
79 | span = document.createElementNS("http://www.w3.org/2000/svg", "tspan");
80 | } else {
81 | span = document.createElement("span");
82 | span.className = className;
83 | }
84 | span.appendChild(document.createTextNode(val.substr(pos, text.length)));
85 | node.parentNode.insertBefore(span, node.parentNode.insertBefore(
86 | document.createTextNode(val.substr(pos + text.length)),
87 | node.nextSibling));
88 | node.nodeValue = val.substr(0, pos);
89 | if (isInSVG) {
90 | var rect = document.createElementNS("http://www.w3.org/2000/svg", "rect");
91 | var bbox = node.parentElement.getBBox();
92 | rect.x.baseVal.value = bbox.x;
93 | rect.y.baseVal.value = bbox.y;
94 | rect.width.baseVal.value = bbox.width;
95 | rect.height.baseVal.value = bbox.height;
96 | rect.setAttribute('class', className);
97 | addItems.push({
98 | "parent": node.parentNode,
99 | "target": rect});
100 | }
101 | }
102 | }
103 | else if (!jQuery(node).is("button, select, textarea")) {
104 | jQuery.each(node.childNodes, function() {
105 | highlight(this, addItems);
106 | });
107 | }
108 | }
109 | var addItems = [];
110 | var result = this.each(function() {
111 | highlight(this, addItems);
112 | });
113 | for (var i = 0; i < addItems.length; ++i) {
114 | jQuery(addItems[i].parent).before(addItems[i].target);
115 | }
116 | return result;
117 | };
118 |
119 | /*
120 | * backward compatibility for jQuery.browser
121 | * This will be supported until firefox bug is fixed.
122 | */
123 | if (!jQuery.browser) {
124 | jQuery.uaMatch = function(ua) {
125 | ua = ua.toLowerCase();
126 |
127 | var match = /(chrome)[ \/]([\w.]+)/.exec(ua) ||
128 | /(webkit)[ \/]([\w.]+)/.exec(ua) ||
129 | /(opera)(?:.*version|)[ \/]([\w.]+)/.exec(ua) ||
130 | /(msie) ([\w.]+)/.exec(ua) ||
131 | ua.indexOf("compatible") < 0 && /(mozilla)(?:.*? rv:([\w.]+)|)/.exec(ua) ||
132 | [];
133 |
134 | return {
135 | browser: match[ 1 ] || "",
136 | version: match[ 2 ] || "0"
137 | };
138 | };
139 | jQuery.browser = {};
140 | jQuery.browser[jQuery.uaMatch(navigator.userAgent).browser] = true;
141 | }
142 |
143 | /**
144 | * Small JavaScript module for the documentation.
145 | */
146 | var Documentation = {
147 |
148 | init : function() {
149 | this.fixFirefoxAnchorBug();
150 | this.highlightSearchWords();
151 | this.initIndexTable();
152 | if (DOCUMENTATION_OPTIONS.NAVIGATION_WITH_KEYS) {
153 | this.initOnKeyListeners();
154 | }
155 | },
156 |
157 | /**
158 | * i18n support
159 | */
160 | TRANSLATIONS : {},
161 | PLURAL_EXPR : function(n) { return n === 1 ? 0 : 1; },
162 | LOCALE : 'unknown',
163 |
164 | // gettext and ngettext don't access this so that the functions
165 | // can safely bound to a different name (_ = Documentation.gettext)
166 | gettext : function(string) {
167 | var translated = Documentation.TRANSLATIONS[string];
168 | if (typeof translated === 'undefined')
169 | return string;
170 | return (typeof translated === 'string') ? translated : translated[0];
171 | },
172 |
173 | ngettext : function(singular, plural, n) {
174 | var translated = Documentation.TRANSLATIONS[singular];
175 | if (typeof translated === 'undefined')
176 | return (n == 1) ? singular : plural;
177 | return translated[Documentation.PLURALEXPR(n)];
178 | },
179 |
180 | addTranslations : function(catalog) {
181 | for (var key in catalog.messages)
182 | this.TRANSLATIONS[key] = catalog.messages[key];
183 | this.PLURAL_EXPR = new Function('n', 'return +(' + catalog.plural_expr + ')');
184 | this.LOCALE = catalog.locale;
185 | },
186 |
187 | /**
188 | * add context elements like header anchor links
189 | */
190 | addContextElements : function() {
191 | $('div[id] > :header:first').each(function() {
192 | $('').
193 | attr('href', '#' + this.id).
194 | attr('title', _('Permalink to this headline')).
195 | appendTo(this);
196 | });
197 | $('dt[id]').each(function() {
198 | $('').
199 | attr('href', '#' + this.id).
200 | attr('title', _('Permalink to this definition')).
201 | appendTo(this);
202 | });
203 | },
204 |
205 | /**
206 | * workaround a firefox stupidity
207 | * see: https://bugzilla.mozilla.org/show_bug.cgi?id=645075
208 | */
209 | fixFirefoxAnchorBug : function() {
210 | if (document.location.hash && $.browser.mozilla)
211 | window.setTimeout(function() {
212 | document.location.href += '';
213 | }, 10);
214 | },
215 |
216 | /**
217 | * highlight the search words provided in the url in the text
218 | */
219 | highlightSearchWords : function() {
220 | var params = $.getQueryParameters();
221 | var terms = (params.highlight) ? params.highlight[0].split(/\s+/) : [];
222 | if (terms.length) {
223 | var body = $('div.body');
224 | if (!body.length) {
225 | body = $('body');
226 | }
227 | window.setTimeout(function() {
228 | $.each(terms, function() {
229 | body.highlightText(this.toLowerCase(), 'highlighted');
230 | });
231 | }, 10);
232 | $('
' + _('Hide Search Matches') + '
')
234 | .appendTo($('#searchbox'));
235 | }
236 | },
237 |
238 | /**
239 | * init the domain index toggle buttons
240 | */
241 | initIndexTable : function() {
242 | var togglers = $('img.toggler').click(function() {
243 | var src = $(this).attr('src');
244 | var idnum = $(this).attr('id').substr(7);
245 | $('tr.cg-' + idnum).toggle();
246 | if (src.substr(-9) === 'minus.png')
247 | $(this).attr('src', src.substr(0, src.length-9) + 'plus.png');
248 | else
249 | $(this).attr('src', src.substr(0, src.length-8) + 'minus.png');
250 | }).css('display', '');
251 | if (DOCUMENTATION_OPTIONS.COLLAPSE_INDEX) {
252 | togglers.click();
253 | }
254 | },
255 |
256 | /**
257 | * helper function to hide the search marks again
258 | */
259 | hideSearchWords : function() {
260 | $('#searchbox .highlight-link').fadeOut(300);
261 | $('span.highlighted').removeClass('highlighted');
262 | },
263 |
264 | /**
265 | * make the url absolute
266 | */
267 | makeURL : function(relativeURL) {
268 | return DOCUMENTATION_OPTIONS.URL_ROOT + '/' + relativeURL;
269 | },
270 |
271 | /**
272 | * get the current relative url
273 | */
274 | getCurrentURL : function() {
275 | var path = document.location.pathname;
276 | var parts = path.split(/\//);
277 | $.each(DOCUMENTATION_OPTIONS.URL_ROOT.split(/\//), function() {
278 | if (this === '..')
279 | parts.pop();
280 | });
281 | var url = parts.join('/');
282 | return path.substring(url.lastIndexOf('/') + 1, path.length - 1);
283 | },
284 |
285 | initOnKeyListeners: function() {
286 | $(document).keyup(function(event) {
287 | var activeElementType = document.activeElement.tagName;
288 | // don't navigate when in search box or textarea
289 | if (activeElementType !== 'TEXTAREA' && activeElementType !== 'INPUT' && activeElementType !== 'SELECT') {
290 | switch (event.keyCode) {
291 | case 37: // left
292 | var prevHref = $('link[rel="prev"]').prop('href');
293 | if (prevHref) {
294 | window.location.href = prevHref;
295 | return false;
296 | }
297 | case 39: // right
298 | var nextHref = $('link[rel="next"]').prop('href');
299 | if (nextHref) {
300 | window.location.href = nextHref;
301 | return false;
302 | }
303 | }
304 | }
305 | });
306 | }
307 | };
308 |
309 | // quick alias for translations
310 | _ = Documentation.gettext;
311 |
312 | $(document).ready(function() {
313 | Documentation.init();
314 | });
315 |
--------------------------------------------------------------------------------
/doc/_build/html/_static/documentation_options.js:
--------------------------------------------------------------------------------
1 | var DOCUMENTATION_OPTIONS = {
2 | URL_ROOT: document.getElementById("documentation_options").getAttribute('data-url_root'),
3 | VERSION: '1.0',
4 | LANGUAGE: 'None',
5 | COLLAPSE_INDEX: false,
6 | FILE_SUFFIX: '.html',
7 | HAS_SOURCE: true,
8 | SOURCELINK_SUFFIX: '.txt',
9 | NAVIGATION_WITH_KEYS: false
10 | };
--------------------------------------------------------------------------------
/doc/_build/html/_static/down-pressed.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/down-pressed.png
--------------------------------------------------------------------------------
/doc/_build/html/_static/down.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/down.png
--------------------------------------------------------------------------------
/doc/_build/html/_static/drugbank_2d_dark.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/drugbank_2d_dark.png
--------------------------------------------------------------------------------
/doc/_build/html/_static/drugbank_2d_light.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/drugbank_2d_light.png
--------------------------------------------------------------------------------
/doc/_build/html/_static/file.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/file.png
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Inconsolata-Bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Inconsolata-Bold.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Inconsolata-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Inconsolata-Regular.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Inconsolata.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Inconsolata.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato-Bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato-Bold.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato-Regular.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-bold.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-bold.eot
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-bold.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-bold.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-bold.woff
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-bold.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-bold.woff2
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-bolditalic.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-bolditalic.eot
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-bolditalic.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-bolditalic.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-bolditalic.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-bolditalic.woff
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-bolditalic.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-bolditalic.woff2
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-italic.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-italic.eot
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-italic.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-italic.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-italic.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-italic.woff
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-italic.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-italic.woff2
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-regular.eot
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-regular.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-regular.woff
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/Lato/lato-regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/Lato/lato-regular.woff2
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/RobotoSlab-Bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/RobotoSlab-Bold.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/RobotoSlab-Regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/RobotoSlab-Regular.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.eot
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-bold.woff2
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.eot
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/RobotoSlab/roboto-slab-v7-regular.woff2
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/fontawesome-webfont.eot:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/fontawesome-webfont.eot
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/fontawesome-webfont.ttf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/fontawesome-webfont.ttf
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/fontawesome-webfont.woff:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/fontawesome-webfont.woff
--------------------------------------------------------------------------------
/doc/_build/html/_static/fonts/fontawesome-webfont.woff2:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/_static/fonts/fontawesome-webfont.woff2
--------------------------------------------------------------------------------
/doc/_build/html/_static/js/theme.js:
--------------------------------------------------------------------------------
1 | /* sphinx_rtd_theme version 0.4.3 | MIT license */
2 | /* Built 20190212 16:02 */
3 | require=function r(s,a,l){function c(e,n){if(!a[e]){if(!s[e]){var i="function"==typeof require&&require;if(!n&&i)return i(e,!0);if(u)return u(e,!0);var t=new Error("Cannot find module '"+e+"'");throw t.code="MODULE_NOT_FOUND",t}var o=a[e]={exports:{}};s[e][0].call(o.exports,function(n){return c(s[e][1][n]||n)},o,o.exports,r,s,a,l)}return a[e].exports}for(var u="function"==typeof require&&require,n=0;n"),i("table.docutils.footnote").wrap(""),i("table.docutils.citation").wrap(""),i(".wy-menu-vertical ul").not(".simple").siblings("a").each(function(){var e=i(this);expand=i(''),expand.on("click",function(n){return t.toggleCurrent(e),n.stopPropagation(),!1}),e.prepend(expand)})},reset:function(){var n=encodeURI(window.location.hash)||"#";try{var e=$(".wy-menu-vertical"),i=e.find('[href="'+n+'"]');if(0===i.length){var t=$('.document [id="'+n.substring(1)+'"]').closest("div.section");0===(i=e.find('[href="#'+t.attr("id")+'"]')).length&&(i=e.find('[href="#"]'))}0this.docHeight||(this.navBar.scrollTop(i),this.winPosition=n)},onResize:function(){this.winResize=!1,this.winHeight=this.win.height(),this.docHeight=$(document).height()},hashChange:function(){this.linkScroll=!0,this.win.one("hashchange",function(){this.linkScroll=!1})},toggleCurrent:function(n){var e=n.closest("li");e.siblings("li.current").removeClass("current"),e.siblings().find("li.current").removeClass("current"),e.find("> ul li.current").removeClass("current"),e.toggleClass("current")}},"undefined"!=typeof window&&(window.SphinxRtdTheme={Navigation:e.exports.ThemeNav,StickyNav:e.exports.ThemeNav}),function(){for(var r=0,n=["ms","moz","webkit","o"],e=0;e
5 |
6 |
7 |
8 |
9 |
10 |
11 |
12 | Index — Faerun 1.0 documentation
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
93 |
94 |
95 |
96 |
97 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 | - Docs »
130 |
131 | - Index
132 |
133 |
134 | -
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
Index
150 |
151 |
152 |
_
153 | |
A
154 | |
C
155 | |
D
156 | |
F
157 | |
G
158 | |
H
159 | |
I
160 | |
P
161 |
162 |
163 |
_
164 |
170 |
171 |
A
172 |
182 |
183 |
C
184 |
194 |
195 |
D
196 |
202 |
203 |
F
204 |
210 |
211 |
G
212 |
218 |
219 |
H
220 |
226 |
227 |
I
228 |
234 |
235 |
P
236 |
242 |
243 |
244 |
245 |
246 |
247 |
248 |
262 |
263 |
264 |
265 |
266 |
267 |
268 |
269 |
270 |
271 |
272 |
277 |
278 |
279 |
280 |
281 |
282 |
283 |
284 |
--------------------------------------------------------------------------------
/doc/_build/html/index.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 | Welcome to Faerun’s documentation! — Faerun 1.0 documentation
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
93 |
94 |
95 |
96 |
97 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 | - Docs »
130 |
131 | - Welcome to Faerun’s documentation!
132 |
133 |
134 | -
135 |
136 |
137 | View page source
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
Welcome to Faerun’s documentation!
152 |
Here are some teasers.
153 |

154 |

155 |
156 |
Table of Contents
157 |
187 |
188 |
189 |
190 |
191 |
192 |
193 |
194 |
215 |
216 |
217 |
218 |
219 |
220 |
221 |
222 |
223 |
224 |
225 |
230 |
231 |
232 |
233 |
234 |
235 |
236 |
237 |
--------------------------------------------------------------------------------
/doc/_build/html/objects.inv:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/html/objects.inv
--------------------------------------------------------------------------------
/doc/_build/html/py-modindex.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 | Python Module Index — Faerun 1.0 documentation
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
47 |
48 |
99 |
100 |
101 |
102 |
103 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 |
133 |
134 |
135 | - Docs »
136 |
137 | - Python Module Index
138 |
139 |
140 | -
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
Python Module Index
154 |
155 |
158 |
159 |
160 | | | |
161 | |
162 | f | |
163 |
164 |  |
166 |
167 | faerun |
168 | |
169 |
170 | |
171 |
172 | faerun.faerun |
173 | |
174 |
175 | |
176 |
177 | faerun.web |
178 | |
179 |
180 |
181 |
182 |
183 |
184 |
185 |
199 |
200 |
201 |
202 |
203 |
204 |
205 |
206 |
207 |
208 |
209 |
214 |
215 |
216 |
217 |
218 |
219 |
220 |
221 |
--------------------------------------------------------------------------------
/doc/_build/html/search.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 | Search — Faerun 1.0 documentation
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
46 |
93 |
94 |
95 |
96 |
97 |
103 |
104 |
105 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 | - Docs »
130 |
131 | - Search
132 |
133 |
134 | -
135 |
136 |
137 |
138 |
139 |
140 |
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
156 |
157 |
158 |
159 |
160 |
161 |
162 |
163 |
164 |
165 |
179 |
180 |
181 |
182 |
183 |
184 |
185 |
186 |
187 |
188 |
189 |
194 |
195 |
196 |
197 |
198 |
199 |
202 |
203 |
204 |
205 |
206 |
207 |
208 |
--------------------------------------------------------------------------------
/doc/_build/html/searchindex.js:
--------------------------------------------------------------------------------
1 | Search.setIndex({docnames:["documentation","host","index","tutorial"],envversion:{"sphinx.domains.c":1,"sphinx.domains.changeset":1,"sphinx.domains.citation":1,"sphinx.domains.cpp":1,"sphinx.domains.javascript":1,"sphinx.domains.math":2,"sphinx.domains.python":1,"sphinx.domains.rst":1,"sphinx.domains.std":1,sphinx:56},filenames:["documentation.rst","host.rst","index.rst","tutorial.rst"],objects:{"faerun.Faerun":{__init__:[0,1,1,""],add_scatter:[0,1,1,""],add_tree:[0,1,1,""],create_data:[0,1,1,""],create_python_data:[0,1,1,""],discrete_cmap:[0,1,1,""],get_min_max:[0,1,1,""],in_notebook:[0,1,1,""],plot:[0,1,1,""]},faerun:{Faerun:[0,0,1,""],host:[0,2,1,""]}},objnames:{"0":["py","class","Python class"],"1":["py","method","Python method"],"2":["py","function","Python function"]},objtypes:{"0":"py:class","1":"py:method","2":"py:function"},terms:{"class":[0,3],"default":[0,1],"export":3,"final":3,"float":0,"function":[0,1],"import":[1,3],"int":0,"return":[0,1],"static":0,"true":[0,1,3],"while":1,Adding:2,One:[1,3],That:3,The:[0,1,3],__init__:0,__main__:[1,3],__name__:[1,3],abov:1,accept:1,access:1,accompani:3,activ:0,add:[0,2,3],add_scatt:[0,1,3],add_tre:0,added:[0,1,3],addit:[1,3],allow:1,alpha:0,alpha_blend:0,also:[0,1,3],ani:[0,3],appli:0,arbitrari:1,argument:[0,1,3],around:0,associ:[0,3],avoid:0,axes:[0,3],axi:0,back:0,background:[0,3],base:[0,1],base_cmap:0,belong:1,bin:0,blend:0,bool:0,bottom:0,box:0,browser:1,build:1,button:1,call:1,callabl:0,can:[0,1,3],canva:3,categor:[0,1,3],check:0,cherrypi:[0,1],chose:3,clear:3,clear_color:[0,1,3],click:1,code:[0,1,3],color:[0,3],colormap:[0,1,3],column:0,com:1,complet:2,constructor:0,contain:[0,1],content:0,coord:[0,1,3],coordin:[0,3],coords_box:0,coords_color:0,coords_grid:0,coords_offset:0,coords_tick:0,coords_tick_count:0,coords_tick_length:0,core:0,cos:[1,3],creat:[0,2],create_data:0,create_python_data:[0,1,3],css:0,custom:1,custom_label_formatt:1,custom_link_formatt:1,dark2:[1,3],dark:[1,3],data:[0,2],datafram:[0,3],def:[1,3],defin:[0,1],deploi:1,describ:1,desplai:1,detail:1,dict:[0,3],differ:1,diffus:3,disabl:3,discret:0,discrete_cmap:0,displai:[0,1],distanc:0,doubl:1,draw:[0,3],due:1,dump:[1,3],each:1,easili:1,element:0,empti:0,enabl:[1,3],end:0,enumer:1,exact:1,exampl:2,extend:0,fals:[0,1,3],fearun:[0,1],file:[0,2],file_nam:0,fog:0,fog_intens:0,format:[0,2],formatt:1,forward:1,frame:0,free:[0,1,3],from:[0,1,3],front:0,further:1,gener:[0,1,3],get:[0,1,2],get_min_max:0,given:3,googl:1,grai:[0,3],grid:0,handl:[1,3],has:[1,3],has_legend:[0,1,3],helix:[1,3],here:[2,3],hex:3,highest_protocol:[1,3],horizont:0,host:[0,1,3],howev:1,html:[0,1,2],http:1,hyperlink:2,imag:1,in_notebook:0,includ:1,index:[0,1],info:[0,2],inform:1,input:0,insert:1,instal:2,instanc:[0,3],integ:1,intens:0,interact:0,interest:1,introduct:2,ipython:0,javascript:[0,1,3],join:1,just:3,kei:0,keyword:0,label:[0,2,3],label_formatt:[0,1],label_typ:[0,1],lambda:1,larger:1,layer:[0,1,2],left:0,legend:[0,3],legend_label:[0,1,3],legend_number_format:0,legend_orient:0,legend_titl:0,len:[1,3],length:0,let:1,light:[0,3],limit:1,link:[0,1],link_formatt:[0,1],linspac:[1,3],list:[1,3],load:1,local:3,look:3,main:[1,3],map:0,markdown:[0,1],match:1,matplotlib:[0,3],max_legend_label:0,max_point_s:0,maximum:0,mean:1,memori:1,mess:3,method:[1,3],might:1,miminum:0,min_legend_label:0,minimum:0,modul:3,n_color:0,name:[0,1,3],next:[1,3],nice:3,non:0,none:0,normal:0,notebook:0,number:0,numpi:[1,3],object:0,offset:0,open:[1,3],option:0,order:[1,3],orient:0,otherwis:3,packag:3,page:1,pan:3,panda:[0,3],paramet:[0,3],path:0,per:0,pickl:[1,3],pip:3,plasma:0,plot:[0,1,2],plotter:0,point:[0,1,3],point_help:0,point_scal:[0,1,3],possibl:1,prefix:1,prepar:2,problem:1,protocol:[1,3],provid:1,publicli:1,python:0,randint:[1,3],random:[1,3],rang:0,readi:1,regex:1,rel:0,render:3,repres:1,request:1,requir:0,right:0,rotat:3,run:0,same:3,satur:0,saturation_limit:0,save:[1,2],scale:0,scatter:[0,2],screenshot:1,script:3,search:[0,2],search_index:[0,1],second:1,see:1,separ:1,serv:1,server:[0,2,3],set:[1,3],shader:[0,1,3],show:0,show_legend:0,shown:[0,1],similar:1,sin:[1,3],sinc:3,singl:1,size:[0,3],small:1,smile:0,smoothcircl:0,solv:1,some:[2,3],soup:0,sourc:0,specifi:0,specular:3,sphere:[0,1,3],split:1,start:[0,2],step:3,store:1,str:[0,1],straight:1,string:[0,1],style:0,substr:1,support:[1,3],surfac:0,tabl:1,teaser:2,templat:0,thei:1,them:1,theme:[0,1],thi:[0,1,3],tick:0,time:1,titl:[0,1,3],top:0,tree:0,tupl:[0,3],turn:3,tutori:3,type:0,union:0,upon:1,url:1,use:[0,3],used:[0,1,3],user:3,using:[1,3],valu:[0,1,3],version:1,vertic:0,view:[0,1,3],visit:1,visual:[0,1],want:3,web:[2,3],welcom:1,what:0,when:0,whenev:1,where:0,whether:0,which:[0,1,3],window:1,work:1,wrap:3,write:0,www:1,x_titl:0,y_titl:0,yai:1,you:1,zero:[1,3],zoom:0},titles:["Documentation","Web","Welcome to Faerun\u2019s documentation!","Getting Started"],titleterms:{Adding:[1,3],add:1,complet:[1,3],content:2,creat:[1,3],data:[1,3],document:[0,1,2,3],exampl:[1,3],faerun:[0,1,2,3],file:[1,3],format:1,get:3,html:3,hyperlink:1,info:1,instal:3,introduct:1,label:1,layer:3,plot:3,prepar:3,save:3,scatter:3,search:1,server:1,start:[1,3],tabl:2,web:[0,1],welcom:2}})
--------------------------------------------------------------------------------
/doc/_build/html/source/modules.html:
--------------------------------------------------------------------------------
1 |
2 |
3 |
4 |
5 |
6 |
7 |
8 |
9 |
10 |
11 | faerun — Faerun 1.0 documentation
12 |
13 |
14 |
15 |
16 |
17 |
18 |
19 |
20 |
21 |
22 |
23 |
24 |
25 |
26 |
27 |
28 |
29 |
30 |
31 |
32 |
33 |
34 |
35 |
36 |
37 |
38 |
39 |
40 |
41 |
42 |
43 |
44 |
45 |
96 |
97 |
98 |
99 |
100 |
106 |
107 |
108 |
109 |
110 |
111 |
112 |
113 |
114 |
115 |
116 |
117 |
118 |
119 |
120 |
121 |
122 |
123 |
124 |
125 |
126 |
127 |
128 |
129 |
130 |
131 |
132 | - Docs »
133 |
134 | - faerun
135 |
136 |
137 | -
138 |
139 |
140 | View page source
141 |
142 |
143 |
144 |
145 |
146 |
147 |
148 |
149 |
150 |
151 |
152 |
153 |
173 |
174 |
175 |
176 |
177 |
178 |
192 |
193 |
194 |
195 |
196 |
197 |
198 |
199 |
200 |
201 |
202 |
207 |
208 |
209 |
210 |
211 |
212 |
213 |
214 |
--------------------------------------------------------------------------------
/doc/_build/latex/Faerun.aux:
--------------------------------------------------------------------------------
1 | \relax
2 | \providecommand\hyper@newdestlabel[2]{}
3 | \providecommand\HyperFirstAtBeginDocument{\AtBeginDocument}
4 | \HyperFirstAtBeginDocument{\ifx\hyper@anchor\@undefined
5 | \global\let\oldcontentsline\contentsline
6 | \gdef\contentsline#1#2#3#4{\oldcontentsline{#1}{#2}{#3}}
7 | \global\let\oldnewlabel\newlabel
8 | \gdef\newlabel#1#2{\newlabelxx{#1}#2}
9 | \gdef\newlabelxx#1#2#3#4#5#6{\oldnewlabel{#1}{{#2}{#3}}}
10 | \AtEndDocument{\ifx\hyper@anchor\@undefined
11 | \let\contentsline\oldcontentsline
12 | \let\newlabel\oldnewlabel
13 | \fi}
14 | \fi}
15 | \global\let\hyper@last\relax
16 | \gdef\HyperFirstAtBeginDocument#1{#1}
17 | \providecommand\HyField@AuxAddToFields[1]{}
18 | \providecommand\HyField@AuxAddToCoFields[2]{}
19 | \babel@aux{english}{}
20 | \newlabel{index::doc}{{}{1}{}{section*.2}{}}
21 | \@writefile{toc}{\contentsline {chapter}{\numberline {1}Table of Contents}{3}{chapter.1}\protected@file@percent }
22 | \@writefile{lof}{\addvspace {10\p@ }}
23 | \@writefile{lot}{\addvspace {10\p@ }}
24 | \newlabel{index:table-of-contents}{{1}{3}{Table of Contents}{chapter.1}{}}
25 | \@writefile{toc}{\contentsline {section}{\numberline {1.1}Getting Started}{3}{section.1.1}\protected@file@percent }
26 | \newlabel{tutorial:getting-started}{{1.1}{3}{Getting Started}{section.1.1}{}}
27 | \newlabel{tutorial::doc}{{1.1}{3}{Getting Started}{section.1.1}{}}
28 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.1.1}Installation}{3}{subsection.1.1.1}\protected@file@percent }
29 | \newlabel{tutorial:installation}{{1.1.1}{3}{Installation}{subsection.1.1.1}{}}
30 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.1.2}Create a Plot Document}{3}{subsection.1.1.2}\protected@file@percent }
31 | \newlabel{tutorial:create-a-plot-document}{{1.1.2}{3}{Create a Plot Document}{subsection.1.1.2}{}}
32 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.1.3}Preparing Data for Plotting}{3}{subsection.1.1.3}\protected@file@percent }
33 | \newlabel{tutorial:preparing-data-for-plotting}{{1.1.3}{3}{Preparing Data for Plotting}{subsection.1.1.3}{}}
34 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.1.4}Adding a Scatter Layer}{4}{subsection.1.1.4}\protected@file@percent }
35 | \newlabel{tutorial:adding-a-scatter-layer}{{1.1.4}{4}{Adding a Scatter Layer}{subsection.1.1.4}{}}
36 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.1.5}Saving to HTML}{4}{subsection.1.1.5}\protected@file@percent }
37 | \newlabel{tutorial:saving-to-html}{{1.1.5}{4}{Saving to HTML}{subsection.1.1.5}{}}
38 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.1.6}Saving to Faerun Data File}{4}{subsection.1.1.6}\protected@file@percent }
39 | \newlabel{tutorial:saving-to-faerun-data-file}{{1.1.6}{4}{Saving to Faerun Data File}{subsection.1.1.6}{}}
40 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.1.7}Complete Example}{5}{subsection.1.1.7}\protected@file@percent }
41 | \newlabel{tutorial:complete-example}{{1.1.7}{5}{Complete Example}{subsection.1.1.7}{}}
42 | \@writefile{toc}{\contentsline {section}{\numberline {1.2}Web}{5}{section.1.2}\protected@file@percent }
43 | \newlabel{host:web}{{1.2}{5}{Web}{section.1.2}{}}
44 | \newlabel{host::doc}{{1.2}{5}{Web}{section.1.2}{}}
45 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.2.1}Introduction}{5}{subsection.1.2.1}\protected@file@percent }
46 | \newlabel{host:introduction}{{1.2.1}{5}{Introduction}{subsection.1.2.1}{}}
47 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.2.2}Creating Faerun Data Files}{5}{subsection.1.2.2}\protected@file@percent }
48 | \newlabel{host:creating-faerun-data-files}{{1.2.2}{5}{Creating Faerun Data Files}{subsection.1.2.2}{}}
49 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.2.3}Starting a Faerun Web Server}{5}{subsection.1.2.3}\protected@file@percent }
50 | \newlabel{host:starting-a-faerun-web-server}{{1.2.3}{5}{Starting a Faerun Web Server}{subsection.1.2.3}{}}
51 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.2.4}Formatting Labels}{6}{subsection.1.2.4}\protected@file@percent }
52 | \newlabel{host:formatting-labels}{{1.2.4}{6}{Formatting Labels}{subsection.1.2.4}{}}
53 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.2.5}Adding Hyperlinks}{6}{subsection.1.2.5}\protected@file@percent }
54 | \newlabel{host:adding-hyperlinks}{{1.2.5}{6}{Adding Hyperlinks}{subsection.1.2.5}{}}
55 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.2.6}Searching}{7}{subsection.1.2.6}\protected@file@percent }
56 | \newlabel{host:searching}{{1.2.6}{7}{Searching}{subsection.1.2.6}{}}
57 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.2.7}Add Info / Documentation}{8}{subsection.1.2.7}\protected@file@percent }
58 | \newlabel{host:add-info-documentation}{{1.2.7}{8}{Add Info / Documentation}{subsection.1.2.7}{}}
59 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.2.8}Complete Example}{8}{subsection.1.2.8}\protected@file@percent }
60 | \newlabel{host:complete-example}{{1.2.8}{8}{Complete Example}{subsection.1.2.8}{}}
61 | \@writefile{toc}{\contentsline {section}{\numberline {1.3}Documentation}{9}{section.1.3}\protected@file@percent }
62 | \newlabel{documentation:documentation}{{1.3}{9}{Documentation}{section.1.3}{}}
63 | \newlabel{documentation::doc}{{1.3}{9}{Documentation}{section.1.3}{}}
64 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.3.1}Faerun}{9}{subsection.1.3.1}\protected@file@percent }
65 | \newlabel{documentation:faerun}{{1.3.1}{9}{Faerun}{subsection.1.3.1}{}}
66 | \newlabel{documentation:faerun.Faerun}{{1.3.1}{9}{Faerun}{section*.3}{}}
67 | \newlabel{documentation:faerun.Faerun.__init__}{{1.3.1}{9}{Faerun}{section*.4}{}}
68 | \newlabel{documentation:faerun.Faerun.add_scatter}{{1.3.1}{10}{Faerun}{section*.5}{}}
69 | \newlabel{documentation:faerun.Faerun.add_tree}{{1.3.1}{10}{Faerun}{section*.6}{}}
70 | \newlabel{documentation:faerun.Faerun.create_data}{{1.3.1}{11}{Faerun}{section*.7}{}}
71 | \newlabel{documentation:faerun.Faerun.create_python_data}{{1.3.1}{11}{Faerun}{section*.8}{}}
72 | \newlabel{documentation:faerun.Faerun.discrete_cmap}{{1.3.1}{11}{Faerun}{section*.9}{}}
73 | \newlabel{documentation:faerun.Faerun.get_min_max}{{1.3.1}{11}{Faerun}{section*.10}{}}
74 | \newlabel{documentation:faerun.Faerun.plot}{{1.3.1}{11}{Faerun}{section*.11}{}}
75 | \@writefile{toc}{\contentsline {subsection}{\numberline {1.3.2}Web}{12}{subsection.1.3.2}\protected@file@percent }
76 | \newlabel{documentation:web}{{1.3.2}{12}{Web}{subsection.1.3.2}{}}
77 | \newlabel{documentation:faerun.host}{{1.3.2}{12}{Web}{section*.12}{}}
78 | \@writefile{toc}{\contentsline {chapter}{Index}{13}{section*.13}\protected@file@percent }
79 |
--------------------------------------------------------------------------------
/doc/_build/latex/Faerun.idx:
--------------------------------------------------------------------------------
1 | \indexentry{Faerun (class in faerun)@\spxentry{Faerun}\spxextra{class in faerun}|hyperpage}{9}
2 | \indexentry{\_\_init\_\_() (faerun.Faerun method)@\spxentry{\_\_init\_\_()}\spxextra{faerun.Faerun method}|hyperpage}{9}
3 | \indexentry{add\_scatter() (faerun.Faerun method)@\spxentry{add\_scatter()}\spxextra{faerun.Faerun method}|hyperpage}{10}
4 | \indexentry{add\_tree() (faerun.Faerun method)@\spxentry{add\_tree()}\spxextra{faerun.Faerun method}|hyperpage}{10}
5 | \indexentry{create\_data() (faerun.Faerun method)@\spxentry{create\_data()}\spxextra{faerun.Faerun method}|hyperpage}{11}
6 | \indexentry{create\_python\_data() (faerun.Faerun method)@\spxentry{create\_python\_data()}\spxextra{faerun.Faerun method}|hyperpage}{11}
7 | \indexentry{discrete\_cmap() (faerun.Faerun static method)@\spxentry{discrete\_cmap()}\spxextra{faerun.Faerun static method}|hyperpage}{11}
8 | \indexentry{get\_min\_max() (faerun.Faerun method)@\spxentry{get\_min\_max()}\spxextra{faerun.Faerun method}|hyperpage}{11}
9 | \indexentry{plot() (faerun.Faerun method)@\spxentry{plot()}\spxextra{faerun.Faerun method}|hyperpage}{11}
10 | \indexentry{host() (in module faerun)@\spxentry{host()}\spxextra{in module faerun}|hyperpage}{12}
11 |
--------------------------------------------------------------------------------
/doc/_build/latex/Faerun.ilg:
--------------------------------------------------------------------------------
1 | This is makeindex, version 2.15 [TeX Live 2019/dev] (kpathsea + Thai support).
2 | Scanning style file ./python.ist.......done (7 attributes redefined, 0 ignored).
3 | Scanning input file Faerun.idx....done (10 entries accepted, 0 rejected).
4 | Sorting entries....done (34 comparisons).
5 | Generating output file Faerun.ind....done (40 lines written, 0 warnings).
6 | Output written in Faerun.ind.
7 | Transcript written in Faerun.ilg.
8 |
--------------------------------------------------------------------------------
/doc/_build/latex/Faerun.ind:
--------------------------------------------------------------------------------
1 | \begin{sphinxtheindex}
2 | \let\bigletter\sphinxstyleindexlettergroup
3 | \let\spxpagem \sphinxstyleindexpagemain
4 | \let\spxentry \sphinxstyleindexentry
5 | \let\spxextra \sphinxstyleindexextra
6 |
7 | \bigletter {\sphinxsymbolsname}
8 | \item \spxentry{\_\_init\_\_()}\spxextra{faerun.Faerun method}, \hyperpage{9}
9 |
10 | \indexspace
11 | \bigletter A
12 | \item \spxentry{add\_scatter()}\spxextra{faerun.Faerun method}, \hyperpage{10}
13 | \item \spxentry{add\_tree()}\spxextra{faerun.Faerun method}, \hyperpage{10}
14 |
15 | \indexspace
16 | \bigletter C
17 | \item \spxentry{create\_data()}\spxextra{faerun.Faerun method}, \hyperpage{11}
18 | \item \spxentry{create\_python\_data()}\spxextra{faerun.Faerun method}, \hyperpage{11}
19 |
20 | \indexspace
21 | \bigletter D
22 | \item \spxentry{discrete\_cmap()}\spxextra{faerun.Faerun static method}, \hyperpage{11}
23 |
24 | \indexspace
25 | \bigletter F
26 | \item \spxentry{Faerun}\spxextra{class in faerun}, \hyperpage{9}
27 |
28 | \indexspace
29 | \bigletter G
30 | \item \spxentry{get\_min\_max()}\spxextra{faerun.Faerun method}, \hyperpage{11}
31 |
32 | \indexspace
33 | \bigletter H
34 | \item \spxentry{host()}\spxextra{in module faerun}, \hyperpage{12}
35 |
36 | \indexspace
37 | \bigletter P
38 | \item \spxentry{plot()}\spxextra{faerun.Faerun method}, \hyperpage{11}
39 |
40 | \end{sphinxtheindex}
41 |
--------------------------------------------------------------------------------
/doc/_build/latex/Faerun.out:
--------------------------------------------------------------------------------
1 | \BOOKMARK [0][-]{chapter.1}{\376\377\000T\000a\000b\000l\000e\000\040\000o\000f\000\040\000C\000o\000n\000t\000e\000n\000t\000s}{}% 1
2 | \BOOKMARK [1][-]{section.1.1}{\376\377\000G\000e\000t\000t\000i\000n\000g\000\040\000S\000t\000a\000r\000t\000e\000d}{chapter.1}% 2
3 | \BOOKMARK [1][-]{section.1.2}{\376\377\000W\000e\000b}{chapter.1}% 3
4 | \BOOKMARK [1][-]{section.1.3}{\376\377\000D\000o\000c\000u\000m\000e\000n\000t\000a\000t\000i\000o\000n}{chapter.1}% 4
5 | \BOOKMARK [0][-]{section*.13}{\376\377\000I\000n\000d\000e\000x}{}% 5
6 |
--------------------------------------------------------------------------------
/doc/_build/latex/Faerun.pdf:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/latex/Faerun.pdf
--------------------------------------------------------------------------------
/doc/_build/latex/Faerun.toc:
--------------------------------------------------------------------------------
1 | \babel@toc {english}{}
2 | \contentsline {chapter}{\numberline {1}Table of Contents}{3}{chapter.1}%
3 | \contentsline {section}{\numberline {1.1}Getting Started}{3}{section.1.1}%
4 | \contentsline {subsection}{\numberline {1.1.1}Installation}{3}{subsection.1.1.1}%
5 | \contentsline {subsection}{\numberline {1.1.2}Create a Plot Document}{3}{subsection.1.1.2}%
6 | \contentsline {subsection}{\numberline {1.1.3}Preparing Data for Plotting}{3}{subsection.1.1.3}%
7 | \contentsline {subsection}{\numberline {1.1.4}Adding a Scatter Layer}{4}{subsection.1.1.4}%
8 | \contentsline {subsection}{\numberline {1.1.5}Saving to HTML}{4}{subsection.1.1.5}%
9 | \contentsline {subsection}{\numberline {1.1.6}Saving to Faerun Data File}{4}{subsection.1.1.6}%
10 | \contentsline {subsection}{\numberline {1.1.7}Complete Example}{5}{subsection.1.1.7}%
11 | \contentsline {section}{\numberline {1.2}Web}{5}{section.1.2}%
12 | \contentsline {subsection}{\numberline {1.2.1}Introduction}{5}{subsection.1.2.1}%
13 | \contentsline {subsection}{\numberline {1.2.2}Creating Faerun Data Files}{5}{subsection.1.2.2}%
14 | \contentsline {subsection}{\numberline {1.2.3}Starting a Faerun Web Server}{5}{subsection.1.2.3}%
15 | \contentsline {subsection}{\numberline {1.2.4}Formatting Labels}{6}{subsection.1.2.4}%
16 | \contentsline {subsection}{\numberline {1.2.5}Adding Hyperlinks}{6}{subsection.1.2.5}%
17 | \contentsline {subsection}{\numberline {1.2.6}Searching}{7}{subsection.1.2.6}%
18 | \contentsline {subsection}{\numberline {1.2.7}Add Info / Documentation}{8}{subsection.1.2.7}%
19 | \contentsline {subsection}{\numberline {1.2.8}Complete Example}{8}{subsection.1.2.8}%
20 | \contentsline {section}{\numberline {1.3}Documentation}{9}{section.1.3}%
21 | \contentsline {subsection}{\numberline {1.3.1}Faerun}{9}{subsection.1.3.1}%
22 | \contentsline {subsection}{\numberline {1.3.2}Web}{12}{subsection.1.3.2}%
23 | \contentsline {chapter}{Index}{13}{section*.13}%
24 |
--------------------------------------------------------------------------------
/doc/_build/latex/LICRcyr2utf8.xdy:
--------------------------------------------------------------------------------
1 | ;; -*- coding: utf-8; mode: Lisp; -*-
2 | ;; style file for xindy
3 | ;; filename: LICRcyr2utf8.xdy
4 | ;; description: style file for xindy which maps back LaTeX Internal
5 | ;; Character Representation of Cyrillic to utf-8
6 | ;; usage: for use with pdflatex produced .idx files.
7 | ;; Contributed by the Sphinx team, July 2018.
8 | (merge-rule "\IeC {\'\CYRG }" "Ѓ" :string)
9 | (merge-rule "\IeC {\'\CYRK }" "Ќ" :string)
10 | (merge-rule "\IeC {\'\cyrg }" "ѓ" :string)
11 | (merge-rule "\IeC {\'\cyrk }" "ќ" :string)
12 | (merge-rule "\IeC {\CYRA }" "А" :string)
13 | (merge-rule "\IeC {\CYRB }" "Б" :string)
14 | (merge-rule "\IeC {\CYRC }" "Ц" :string)
15 | (merge-rule "\IeC {\CYRCH }" "Ч" :string)
16 | (merge-rule "\IeC {\CYRD }" "Д" :string)
17 | (merge-rule "\IeC {\CYRDJE }" "Ђ" :string)
18 | (merge-rule "\IeC {\CYRDZE }" "Ѕ" :string)
19 | (merge-rule "\IeC {\CYRDZHE }" "Џ" :string)
20 | (merge-rule "\IeC {\CYRE }" "Е" :string)
21 | (merge-rule "\IeC {\CYREREV }" "Э" :string)
22 | (merge-rule "\IeC {\CYRERY }" "Ы" :string)
23 | (merge-rule "\IeC {\CYRF }" "Ф" :string)
24 | (merge-rule "\IeC {\CYRG }" "Г" :string)
25 | (merge-rule "\IeC {\CYRGUP }" "Ґ" :string)
26 | (merge-rule "\IeC {\CYRH }" "Х" :string)
27 | (merge-rule "\IeC {\CYRHRDSN }" "Ъ" :string)
28 | (merge-rule "\IeC {\CYRI }" "И" :string)
29 | (merge-rule "\IeC {\CYRIE }" "Є" :string)
30 | (merge-rule "\IeC {\CYRII }" "І" :string)
31 | (merge-rule "\IeC {\CYRISHRT }" "Й" :string)
32 | (merge-rule "\IeC {\CYRJE }" "Ј" :string)
33 | (merge-rule "\IeC {\CYRK }" "К" :string)
34 | (merge-rule "\IeC {\CYRL }" "Л" :string)
35 | (merge-rule "\IeC {\CYRLJE }" "Љ" :string)
36 | (merge-rule "\IeC {\CYRM }" "М" :string)
37 | (merge-rule "\IeC {\CYRN }" "Н" :string)
38 | (merge-rule "\IeC {\CYRNJE }" "Њ" :string)
39 | (merge-rule "\IeC {\CYRO }" "О" :string)
40 | (merge-rule "\IeC {\CYRP }" "П" :string)
41 | (merge-rule "\IeC {\CYRR }" "Р" :string)
42 | (merge-rule "\IeC {\CYRS }" "С" :string)
43 | (merge-rule "\IeC {\CYRSFTSN }" "Ь" :string)
44 | (merge-rule "\IeC {\CYRSH }" "Ш" :string)
45 | (merge-rule "\IeC {\CYRSHCH }" "Щ" :string)
46 | (merge-rule "\IeC {\CYRT }" "Т" :string)
47 | (merge-rule "\IeC {\CYRTSHE }" "Ћ" :string)
48 | (merge-rule "\IeC {\CYRU }" "У" :string)
49 | (merge-rule "\IeC {\CYRUSHRT }" "Ў" :string)
50 | (merge-rule "\IeC {\CYRV }" "В" :string)
51 | (merge-rule "\IeC {\CYRYA }" "Я" :string)
52 | (merge-rule "\IeC {\CYRYI }" "Ї" :string)
53 | (merge-rule "\IeC {\CYRYO }" "Ё" :string)
54 | (merge-rule "\IeC {\CYRYU }" "Ю" :string)
55 | (merge-rule "\IeC {\CYRZ }" "З" :string)
56 | (merge-rule "\IeC {\CYRZH }" "Ж" :string)
57 | (merge-rule "\IeC {\cyra }" "а" :string)
58 | (merge-rule "\IeC {\cyrb }" "б" :string)
59 | (merge-rule "\IeC {\cyrc }" "ц" :string)
60 | (merge-rule "\IeC {\cyrch }" "ч" :string)
61 | (merge-rule "\IeC {\cyrd }" "д" :string)
62 | (merge-rule "\IeC {\cyrdje }" "ђ" :string)
63 | (merge-rule "\IeC {\cyrdze }" "ѕ" :string)
64 | (merge-rule "\IeC {\cyrdzhe }" "џ" :string)
65 | (merge-rule "\IeC {\cyre }" "е" :string)
66 | (merge-rule "\IeC {\cyrerev }" "э" :string)
67 | (merge-rule "\IeC {\cyrery }" "ы" :string)
68 | (merge-rule "\IeC {\cyrf }" "ф" :string)
69 | (merge-rule "\IeC {\cyrg }" "г" :string)
70 | (merge-rule "\IeC {\cyrgup }" "ґ" :string)
71 | (merge-rule "\IeC {\cyrh }" "х" :string)
72 | (merge-rule "\IeC {\cyrhrdsn }" "ъ" :string)
73 | (merge-rule "\IeC {\cyri }" "и" :string)
74 | (merge-rule "\IeC {\cyrie }" "є" :string)
75 | (merge-rule "\IeC {\cyrii }" "і" :string)
76 | (merge-rule "\IeC {\cyrishrt }" "й" :string)
77 | (merge-rule "\IeC {\cyrje }" "ј" :string)
78 | (merge-rule "\IeC {\cyrk }" "к" :string)
79 | (merge-rule "\IeC {\cyrl }" "л" :string)
80 | (merge-rule "\IeC {\cyrlje }" "љ" :string)
81 | (merge-rule "\IeC {\cyrm }" "м" :string)
82 | (merge-rule "\IeC {\cyrn }" "н" :string)
83 | (merge-rule "\IeC {\cyrnje }" "њ" :string)
84 | (merge-rule "\IeC {\cyro }" "о" :string)
85 | (merge-rule "\IeC {\cyrp }" "п" :string)
86 | (merge-rule "\IeC {\cyrr }" "р" :string)
87 | (merge-rule "\IeC {\cyrs }" "с" :string)
88 | (merge-rule "\IeC {\cyrsftsn }" "ь" :string)
89 | (merge-rule "\IeC {\cyrsh }" "ш" :string)
90 | (merge-rule "\IeC {\cyrshch }" "щ" :string)
91 | (merge-rule "\IeC {\cyrt }" "т" :string)
92 | (merge-rule "\IeC {\cyrtshe }" "ћ" :string)
93 | (merge-rule "\IeC {\cyru }" "у" :string)
94 | (merge-rule "\IeC {\cyrushrt }" "ў" :string)
95 | (merge-rule "\IeC {\cyrv }" "в" :string)
96 | (merge-rule "\IeC {\cyrya }" "я" :string)
97 | (merge-rule "\IeC {\cyryi }" "ї" :string)
98 | (merge-rule "\IeC {\cyryo }" "ё" :string)
99 | (merge-rule "\IeC {\cyryu }" "ю" :string)
100 | (merge-rule "\IeC {\cyrz }" "з" :string)
101 | (merge-rule "\IeC {\cyrzh }" "ж" :string)
102 |
--------------------------------------------------------------------------------
/doc/_build/latex/LatinRules.xdy:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/latex/LatinRules.xdy
--------------------------------------------------------------------------------
/doc/_build/latex/Makefile:
--------------------------------------------------------------------------------
1 | # Makefile for Sphinx LaTeX output
2 |
3 | ALLDOCS = $(basename $(wildcard *.tex))
4 | ALLPDF = $(addsuffix .pdf,$(ALLDOCS))
5 | ALLDVI = $(addsuffix .dvi,$(ALLDOCS))
6 | ALLXDV =
7 | ALLPS = $(addsuffix .ps,$(ALLDOCS))
8 | ALLIMGS = $(wildcard *.png *.gif *.jpg *.jpeg)
9 |
10 | # Prefix for archive names
11 | ARCHIVEPREFIX =
12 | # Additional LaTeX options (passed via variables in latexmkrc/latexmkjarc file)
13 | export LATEXOPTS =
14 | # Additional latexmk options
15 | LATEXMKOPTS =
16 | # format: pdf or dvi (used only by archive targets)
17 | FMT = pdf
18 |
19 | LATEX = latexmk -dvi
20 | PDFLATEX = latexmk -pdf -dvi- -ps-
21 |
22 |
23 | %.png %.gif %.jpg %.jpeg: FORCE_MAKE
24 | extractbb '$@'
25 |
26 | %.dvi: %.tex FORCE_MAKE
27 | $(LATEX) $(LATEXMKOPTS) '$<'
28 |
29 | %.ps: %.dvi
30 | dvips '$<'
31 |
32 | %.pdf: %.tex FORCE_MAKE
33 | $(PDFLATEX) $(LATEXMKOPTS) '$<'
34 |
35 | all: $(ALLPDF)
36 |
37 | all-dvi: $(ALLDVI)
38 |
39 | all-ps: $(ALLPS)
40 |
41 | all-pdf: $(ALLPDF)
42 |
43 | zip: all-$(FMT)
44 | mkdir $(ARCHIVEPREFIX)docs-$(FMT)
45 | cp $(ALLPDF) $(ARCHIVEPREFIX)docs-$(FMT)
46 | zip -q -r -9 $(ARCHIVEPREFIX)docs-$(FMT).zip $(ARCHIVEPREFIX)docs-$(FMT)
47 | rm -r $(ARCHIVEPREFIX)docs-$(FMT)
48 |
49 | tar: all-$(FMT)
50 | mkdir $(ARCHIVEPREFIX)docs-$(FMT)
51 | cp $(ALLPDF) $(ARCHIVEPREFIX)docs-$(FMT)
52 | tar cf $(ARCHIVEPREFIX)docs-$(FMT).tar $(ARCHIVEPREFIX)docs-$(FMT)
53 | rm -r $(ARCHIVEPREFIX)docs-$(FMT)
54 |
55 | gz: tar
56 | gzip -9 < $(ARCHIVEPREFIX)docs-$(FMT).tar > $(ARCHIVEPREFIX)docs-$(FMT).tar.gz
57 |
58 | bz2: tar
59 | bzip2 -9 -k $(ARCHIVEPREFIX)docs-$(FMT).tar
60 |
61 | xz: tar
62 | xz -9 -k $(ARCHIVEPREFIX)docs-$(FMT).tar
63 |
64 | clean:
65 | rm -f *.log *.ind *.aux *.toc *.syn *.idx *.out *.ilg *.pla *.ps *.tar *.tar.gz *.tar.bz2 *.tar.xz $(ALLPDF) $(ALLDVI) $(ALLXDV) *.fls *.fdb_latexmk
66 |
67 | .PHONY: all all-pdf all-dvi all-ps clean zip tar gz bz2 xz
68 | .PHONY: FORCE_MAKE
--------------------------------------------------------------------------------
/doc/_build/latex/drugbank_2d_dark.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/latex/drugbank_2d_dark.png
--------------------------------------------------------------------------------
/doc/_build/latex/drugbank_2d_light.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/latex/drugbank_2d_light.png
--------------------------------------------------------------------------------
/doc/_build/latex/footnotehyper-sphinx.sty:
--------------------------------------------------------------------------------
1 | \NeedsTeXFormat{LaTeX2e}
2 | \ProvidesPackage{footnotehyper-sphinx}%
3 | [2017/10/27 v1.7 hyperref aware footnote.sty for sphinx (JFB)]
4 | %%
5 | %% Package: footnotehyper-sphinx
6 | %% Version: based on footnotehyper.sty 2017/03/07 v1.0
7 | %% as available at https://www.ctan.org/pkg/footnotehyper
8 | %% License: the one applying to Sphinx
9 | %%
10 | %% Refer to the PDF documentation at https://www.ctan.org/pkg/footnotehyper for
11 | %% the code comments.
12 | %%
13 | %% Differences:
14 | %% 1. a partial tabulary compatibility layer added (enough for Sphinx mark-up),
15 | %% 2. use of \spx@opt@BeforeFootnote from sphinx.sty,
16 | %% 3. use of \sphinxunactivateextrasandspace from sphinx.sty,
17 | %% 4. macro definition \sphinxfootnotemark,
18 | %% 5. macro definition \sphinxlongtablepatch
19 | %% 6. replaced an \undefined by \@undefined
20 | \DeclareOption*{\PackageWarning{footnotehyper-sphinx}{Option `\CurrentOption' is unknown}}%
21 | \ProcessOptions\relax
22 | \newbox\FNH@notes
23 | \newdimen\FNH@width
24 | \let\FNH@colwidth\columnwidth
25 | \newif\ifFNH@savingnotes
26 | \AtBeginDocument {%
27 | \let\FNH@latex@footnote \footnote
28 | \let\FNH@latex@footnotetext\footnotetext
29 | \let\FNH@H@@footnotetext \@footnotetext
30 | \newenvironment{savenotes}
31 | {\FNH@savenotes\ignorespaces}{\FNH@spewnotes\ignorespacesafterend}%
32 | \let\spewnotes \FNH@spewnotes
33 | \let\footnote \FNH@footnote
34 | \let\footnotetext \FNH@footnotetext
35 | \let\endfootnote \FNH@endfntext
36 | \let\endfootnotetext\FNH@endfntext
37 | \@ifpackageloaded{hyperref}
38 | {\ifHy@hyperfootnotes
39 | \let\FNH@H@@footnotetext\H@@footnotetext
40 | \else
41 | \let\FNH@hyper@fntext\FNH@nohyp@fntext
42 | \fi}%
43 | {\let\FNH@hyper@fntext\FNH@nohyp@fntext}%
44 | }%
45 | \def\FNH@hyper@fntext{\FNH@fntext\FNH@hyper@fntext@i}%
46 | \def\FNH@nohyp@fntext{\FNH@fntext\FNH@nohyp@fntext@i}%
47 | \def\FNH@fntext #1{%
48 | \ifx\ifmeasuring@\@undefined
49 | \expandafter\@secondoftwo\else\expandafter\@firstofone\fi
50 | % these two lines modified for Sphinx (tabulary compatibility):
51 | {\ifmeasuring@\expandafter\@gobbletwo\else\expandafter\@firstofone\fi}%
52 | {\ifx\equation$\expandafter\@gobbletwo\fi #1}%$
53 | }%
54 | \long\def\FNH@hyper@fntext@i#1{%
55 | \global\setbox\FNH@notes\vbox
56 | {\unvbox\FNH@notes
57 | \FNH@startnote
58 | \@makefntext
59 | {\rule\z@\footnotesep\ignorespaces
60 | \ifHy@nesting\expandafter\ltx@firstoftwo
61 | \else\expandafter\ltx@secondoftwo
62 | \fi
63 | {\expandafter\hyper@@anchor\expandafter{\Hy@footnote@currentHref}{#1}}%
64 | {\Hy@raisedlink
65 | {\expandafter\hyper@@anchor\expandafter{\Hy@footnote@currentHref}%
66 | {\relax}}%
67 | \let\@currentHref\Hy@footnote@currentHref
68 | \let\@currentlabelname\@empty
69 | #1}%
70 | \@finalstrut\strutbox
71 | }%
72 | \FNH@endnote
73 | }%
74 | }%
75 | \long\def\FNH@nohyp@fntext@i#1{%
76 | \global\setbox\FNH@notes\vbox
77 | {\unvbox\FNH@notes
78 | \FNH@startnote
79 | \@makefntext{\rule\z@\footnotesep\ignorespaces#1\@finalstrut\strutbox}%
80 | \FNH@endnote
81 | }%
82 | }%
83 | \def\FNH@startnote{%
84 | \hsize\FNH@colwidth
85 | \interlinepenalty\interfootnotelinepenalty
86 | \reset@font\footnotesize
87 | \floatingpenalty\@MM
88 | \@parboxrestore
89 | \protected@edef\@currentlabel{\csname p@\@mpfn\endcsname\@thefnmark}%
90 | \color@begingroup
91 | }%
92 | \def\FNH@endnote{\color@endgroup}%
93 | \def\FNH@savenotes{%
94 | \begingroup
95 | \ifFNH@savingnotes\else
96 | \FNH@savingnotestrue
97 | \let\@footnotetext \FNH@hyper@fntext
98 | \let\@mpfootnotetext \FNH@hyper@fntext
99 | \let\H@@mpfootnotetext\FNH@nohyp@fntext
100 | \FNH@width\columnwidth
101 | \let\FNH@colwidth\FNH@width
102 | \global\setbox\FNH@notes\box\voidb@x
103 | \let\FNH@thempfn\thempfn
104 | \let\FNH@mpfn\@mpfn
105 | \ifx\@minipagerestore\relax\let\@minipagerestore\@empty\fi
106 | \expandafter\def\expandafter\@minipagerestore\expandafter{%
107 | \@minipagerestore
108 | \let\thempfn\FNH@thempfn
109 | \let\@mpfn\FNH@mpfn
110 | }%
111 | \fi
112 | }%
113 | \def\FNH@spewnotes {%
114 | \endgroup
115 | \ifFNH@savingnotes\else
116 | \ifvoid\FNH@notes\else
117 | \begingroup
118 | \let\@makefntext\@empty
119 | \let\@finalstrut\@gobble
120 | \let\rule\@gobbletwo
121 | \FNH@H@@footnotetext{\unvbox\FNH@notes}%
122 | \endgroup
123 | \fi
124 | \fi
125 | }%
126 | \def\FNH@footnote@envname {footnote}%
127 | \def\FNH@footnotetext@envname{footnotetext}%
128 | \def\FNH@footnote{%
129 | % this line added for Sphinx:
130 | \spx@opt@BeforeFootnote
131 | \ifx\@currenvir\FNH@footnote@envname
132 | \expandafter\FNH@footnoteenv
133 | \else
134 | \expandafter\FNH@latex@footnote
135 | \fi
136 | }%
137 | \def\FNH@footnoteenv{%
138 | % this line added for Sphinx (footnotes in parsed literal blocks):
139 | \catcode13=5 \sphinxunactivateextrasandspace
140 | \@ifnextchar[%
141 | \FNH@footnoteenv@i %]
142 | {\stepcounter\@mpfn
143 | \protected@xdef\@thefnmark{\thempfn}%
144 | \@footnotemark
145 | \def\FNH@endfntext@fntext{\@footnotetext}%
146 | \FNH@startfntext}%
147 | }%
148 | \def\FNH@footnoteenv@i[#1]{%
149 | \begingroup
150 | \csname c@\@mpfn\endcsname #1\relax
151 | \unrestored@protected@xdef\@thefnmark{\thempfn}%
152 | \endgroup
153 | \@footnotemark
154 | \def\FNH@endfntext@fntext{\@footnotetext}%
155 | \FNH@startfntext
156 | }%
157 | \def\FNH@footnotetext{%
158 | \ifx\@currenvir\FNH@footnotetext@envname
159 | \expandafter\FNH@footnotetextenv
160 | \else
161 | \expandafter\FNH@latex@footnotetext
162 | \fi
163 | }%
164 | \def\FNH@footnotetextenv{%
165 | \@ifnextchar[%
166 | \FNH@footnotetextenv@i %]
167 | {\protected@xdef\@thefnmark{\thempfn}%
168 | \def\FNH@endfntext@fntext{\@footnotetext}%
169 | \FNH@startfntext}%
170 | }%
171 | \def\FNH@footnotetextenv@i[#1]{%
172 | \begingroup
173 | \csname c@\@mpfn\endcsname #1\relax
174 | \unrestored@protected@xdef\@thefnmark{\thempfn}%
175 | \endgroup
176 | \ifFNH@savingnotes
177 | \def\FNH@endfntext@fntext{\FNH@nohyp@fntext}%
178 | \else
179 | \def\FNH@endfntext@fntext{\FNH@H@@footnotetext}%
180 | \fi
181 | \FNH@startfntext
182 | }%
183 | \def\FNH@startfntext{%
184 | \setbox\z@\vbox\bgroup
185 | \FNH@startnote
186 | \FNH@prefntext
187 | \rule\z@\footnotesep\ignorespaces
188 | }%
189 | \def\FNH@endfntext {%
190 | \@finalstrut\strutbox
191 | \FNH@postfntext
192 | \FNH@endnote
193 | \egroup
194 | \begingroup
195 | \let\@makefntext\@empty\let\@finalstrut\@gobble\let\rule\@gobbletwo
196 | \FNH@endfntext@fntext {\unvbox\z@}%
197 | \endgroup
198 | }%
199 | \AtBeginDocument{%
200 | \let\FNH@@makefntext\@makefntext
201 | \ifx\@makefntextFB\@undefined
202 | \expandafter\@gobble\else\expandafter\@firstofone\fi
203 | {\ifFBFrenchFootnotes \let\FNH@@makefntext\@makefntextFB \else
204 | \let\FNH@@makefntext\@makefntextORI\fi}%
205 | \expandafter\FNH@check@a\FNH@@makefntext{1.2!3?4,}%
206 | \FNH@@@1.2!3?4,\FNH@@@\relax
207 | }%
208 | \long\def\FNH@check@a #11.2!3?4,#2\FNH@@@#3{%
209 | \ifx\relax#3\expandafter\@firstoftwo\else\expandafter\@secondoftwo\fi
210 | \FNH@bad@makefntext@alert
211 | {\def\FNH@prefntext{#1}\def\FNH@postfntext{#2}\FNH@check@b}%
212 | }%
213 | \def\FNH@check@b #1\relax{%
214 | \expandafter\expandafter\expandafter\FNH@check@c
215 | \expandafter\meaning\expandafter\FNH@prefntext
216 | \meaning\FNH@postfntext1.2!3?4,\FNH@check@c\relax
217 | }%
218 | \def\FNH@check@c #11.2!3?4,#2#3\relax{%
219 | \ifx\FNH@check@c#2\expandafter\@gobble\fi\FNH@bad@makefntext@alert
220 | }%
221 | % slight reformulation for Sphinx
222 | \def\FNH@bad@makefntext@alert{%
223 | \PackageWarningNoLine{footnotehyper-sphinx}%
224 | {Footnotes will be sub-optimal, sorry. This is due to the document class or^^J
225 | some package modifying macro \string\@makefntext.^^J
226 | You can try to report this incompatibility at^^J
227 | https://github.com/sphinx-doc/sphinx with this info:}%
228 | \typeout{\meaning\@makefntext}%
229 | \let\FNH@prefntext\@empty\let\FNH@postfntext\@empty
230 | }%
231 | % this macro from original footnote.sty is not used anymore by Sphinx
232 | % but for simplicity sake let's just keep it as is
233 | \def\makesavenoteenv{\@ifnextchar[\FNH@msne@ii\FNH@msne@i}%]
234 | \def\FNH@msne@i #1{%
235 | \expandafter\let\csname FNH$#1\expandafter\endcsname %$
236 | \csname #1\endcsname
237 | \expandafter\let\csname endFNH$#1\expandafter\endcsname %$
238 | \csname end#1\endcsname
239 | \FNH@msne@ii[#1]{FNH$#1}%$
240 | }%
241 | \def\FNH@msne@ii[#1]#2{%
242 | \expandafter\edef\csname#1\endcsname{%
243 | \noexpand\savenotes
244 | \expandafter\noexpand\csname#2\endcsname
245 | }%
246 | \expandafter\edef\csname end#1\endcsname{%
247 | \expandafter\noexpand\csname end#2\endcsname
248 | \noexpand\expandafter
249 | \noexpand\spewnotes
250 | \noexpand\if@endpe\noexpand\@endpetrue\noexpand\fi
251 | }%
252 | }%
253 | % end of footnotehyper 2017/02/16 v0.99
254 | % some extras for Sphinx :
255 | % \sphinxfootnotemark: usable in section titles and silently removed from TOCs.
256 | \def\sphinxfootnotemark [#1]%
257 | {\ifx\thepage\relax\else\protect\spx@opt@BeforeFootnote
258 | \protect\footnotemark[#1]\fi}%
259 | \AtBeginDocument{%
260 | % let hyperref less complain
261 | \pdfstringdefDisableCommands{\def\sphinxfootnotemark [#1]{}}%
262 | % to obtain hyperlinked footnotes in longtable environment we must replace
263 | % hyperref's patch of longtable's patch of \@footnotetext by our own
264 | \let\LT@p@ftntext\FNH@hyper@fntext
265 | % this *requires* longtable to be used always wrapped in savenotes environment
266 | }%
267 | \endinput
268 | %%
269 | %% End of file `footnotehyper-sphinx.sty'.
270 |
--------------------------------------------------------------------------------
/doc/_build/latex/latexmkjarc:
--------------------------------------------------------------------------------
1 | $latex = 'platex ' . $ENV{'LATEXOPTS'} . ' -kanji=utf8 %O %S';
2 | $dvipdf = 'dvipdfmx %O -o %D %S';
3 | $makeindex = 'internal mendex %S %B %D';
4 | sub mendex {
5 | my ($source, $basename, $destination) = @_;
6 | my $dictfile = $basename . ".dic";
7 | unlink($destination);
8 | system("mendex", "-U", "-f", "-d", $dictfile, "-s", "python.ist", $source);
9 | if ($? > 0) {
10 | print("mendex exited with error code $? (ignored)\n");
11 | }
12 | if (!-e $destination) {
13 | # create an empty .ind file if nothing
14 | open(FH, ">" . $destination);
15 | close(FH);
16 | }
17 | return 0;
18 | }
19 | add_cus_dep( "glo", "gls", 0, "makeglo" );
20 | sub makeglo {
21 | return system( "mendex -J -f -s gglo.ist -o '$_[0].gls' '$_[0].glo'" );
22 | }
23 |
--------------------------------------------------------------------------------
/doc/_build/latex/latexmkrc:
--------------------------------------------------------------------------------
1 | $latex = 'latex ' . $ENV{'LATEXOPTS'} . ' %O %S';
2 | $pdflatex = 'pdflatex ' . $ENV{'LATEXOPTS'} . ' %O %S';
3 | $lualatex = 'lualatex ' . $ENV{'LATEXOPTS'} . ' %O %S';
4 | $xelatex = 'xelatex --no-pdf ' . $ENV{'LATEXOPTS'} . ' %O %S';
5 | $makeindex = 'makeindex -s python.ist %O -o %D %S';
6 | add_cus_dep( "glo", "gls", 0, "makeglo" );
7 | sub makeglo {
8 | return system( "makeindex -s gglo.ist -o '$_[0].gls' '$_[0].glo'" );
9 | }
--------------------------------------------------------------------------------
/doc/_build/latex/make.bat:
--------------------------------------------------------------------------------
1 | @ECHO OFF
2 |
3 | REM Command file for Sphinx documentation
4 |
5 | pushd %~dp0
6 |
7 | set PDFLATEX=latexmk -pdf -dvi- -ps-
8 |
9 | set "LATEXOPTS= "
10 |
11 | if "%1" == "" goto all-pdf
12 |
13 | if "%1" == "all-pdf" (
14 | :all-pdf
15 | for %%i in (*.tex) do (
16 | %PDFLATEX% %LATEXMKOPTS% %%i
17 | )
18 | goto end
19 | )
20 |
21 | if "%1" == "all-pdf-ja" (
22 | goto all-pdf
23 | )
24 |
25 | if "%1" == "clean" (
26 | del /q /s *.dvi *.log *.ind *.aux *.toc *.syn *.idx *.out *.ilg *.pla *.ps *.tar *.tar.gz *.tar.bz2 *.tar.xz *.fls *.fdb_latexmk
27 | goto end
28 | )
29 |
30 | :end
31 | popd
--------------------------------------------------------------------------------
/doc/_build/latex/python.ist:
--------------------------------------------------------------------------------
1 | line_max 100
2 | headings_flag 1
3 | heading_prefix " \\bigletter "
4 |
5 | preamble "\\begin{sphinxtheindex}
6 | \\let\\bigletter\\sphinxstyleindexlettergroup
7 | \\let\\spxpagem \\sphinxstyleindexpagemain
8 | \\let\\spxentry \\sphinxstyleindexentry
9 | \\let\\spxextra \\sphinxstyleindexextra
10 |
11 | "
12 |
13 | postamble "\n\n\\end{sphinxtheindex}\n"
14 |
15 | symhead_positive "{\\sphinxsymbolsname}"
16 | numhead_positive "{\\sphinxnumbersname}"
17 |
--------------------------------------------------------------------------------
/doc/_build/latex/sphinx.xdy:
--------------------------------------------------------------------------------
1 | ;;; -*- mode: lisp; coding: utf-8; -*-
2 |
3 | ;; Unfortunately xindy is out-of-the-box hyperref-incompatible. This
4 | ;; configuration is a workaround, which requires to pass option
5 | ;; hyperindex=false to hyperref.
6 | ;; textit and emph not currently used, spxpagem replaces former textbf
7 | (define-attributes (("textbf" "textit" "emph" "spxpagem" "default")))
8 | (markup-locref :open "\textbf{\hyperpage{" :close "}}" :attr "textbf")
9 | (markup-locref :open "\textit{\hyperpage{" :close "}}" :attr "textit")
10 | (markup-locref :open "\emph{\hyperpage{" :close "}}" :attr "emph")
11 | (markup-locref :open "\spxpagem{\hyperpage{" :close "}}" :attr "spxpagem")
12 | (markup-locref :open "\hyperpage{" :close "}" :attr "default")
13 |
14 | (require "numeric-sort.xdy")
15 |
16 | ;; xindy base module latex.xdy loads tex.xdy and the latter instructs
17 | ;; xindy to ignore **all** TeX macros in .idx entries, except those
18 | ;; explicitely described in merge rule. But when after applying all
19 | ;; merge rules an empty string results, xindy raises an error:
20 |
21 | ;; ERROR: CHAR: index 0 should be less than the length of the string
22 |
23 | ;; For example when using pdflatex with utf-8 characters the index
24 | ;; file will contain \IeC macros and they will get ignored except if
25 | ;; suitable merge rules are loaded early. The texindy script coming
26 | ;; with xindy provides this, but only for Latin scripts. The texindy
27 | ;; man page says to use rather xelatex or lualatex in case of Cyrillic
28 | ;; scripts.
29 |
30 | ;; Sphinx contributes LICRcyr2utf8.xdy to provide support for Cyrillic
31 | ;; scripts for the pdflatex engine.
32 |
33 | ;; Another issue caused by xindy ignoring all TeX macros except those
34 | ;; explicitely declared reveals itself when attempting to index ">>>",
35 | ;; as the ">" is converted to "\textgreater{}" by Sphinx's LaTeX
36 | ;; escaping.
37 |
38 | ;; To fix this, Sphinx does **not** use texindy, and does not even
39 | ;; load the xindy latex.xdy base module.
40 |
41 | ;(require "latex.xdy")
42 |
43 | ;; Rather it incorporates some suitable extracts from latex.xdy and
44 | ;; tex.xdy with additional Sphinx contributed rules.
45 |
46 | ;; But, this means for pdflatex and Latin scripts that the xindy file
47 | ;; tex/inputenc/uf8.xdy is not usable because it refers to the macro
48 | ;; \IeC only sporadically, and as tex.xdy is not loaded, a rule such as
49 | ;; (merge-rule "\'e" "é" :string)
50 | ;; does not work, it must be
51 | ;; (merge-rule "\IeC {\'e}" "é" :string)
52 | ;; So Sphinx contributes LICRlatin2utf8.xdy to mitigate that problem.
53 |
54 | ;;;;;;;; extracts from tex.xdy (discarding most original comments):
55 |
56 | ;;;
57 | ;;; TeX conventions
58 | ;;;
59 |
60 | ;; Discard leading and trailing white space. Collapse multiple white
61 | ;; space characters to blank.
62 |
63 | (merge-rule "^ +" "" :eregexp)
64 | (merge-rule " +$" "" :eregexp)
65 | (merge-rule " +" " " :eregexp)
66 |
67 | ;; Handle TeX markup
68 |
69 | (merge-rule "\\([{}$%])" "\1" :eregexp)
70 |
71 | ;;;;;;;; end of extracts from xindy's tex.xdy
72 |
73 | ;;;;;;;; extracts from latex.xdy:
74 |
75 | ;; Standard location classes: arabic and roman numbers, and alphabets.
76 |
77 | (define-location-class "arabic-page-numbers" ("arabic-numbers"))
78 | (define-location-class "roman-page-numbers" ("roman-numbers-lowercase"))
79 | (define-location-class "Roman-page-numbers" ("roman-numbers-uppercase"))
80 | (define-location-class "alpha-page-numbers" ("alpha"))
81 | (define-location-class "Alpha-page-numbers" ("ALPHA"))
82 |
83 | ;; Output Markup
84 |
85 | (markup-letter-group-list :sep "~n~n \indexspace~n")
86 |
87 | (markup-indexentry :open "~n \item " :depth 0)
88 | (markup-indexentry :open "~n \subitem " :depth 1)
89 | (markup-indexentry :open "~n \subsubitem " :depth 2)
90 |
91 | (markup-locclass-list :open ", " :sep ", ")
92 | (markup-locref-list :sep ", ")
93 |
94 | ;;;;;;;; end of extracts from latex.xdy
95 |
96 | ;; The LaTeX \index command turns \ into normal character so the TeX macros
97 | ;; written to .idx files are not followed by a blank. This is different
98 | ;; from non-ascii letters which end up (with pdflatex) as \IeC macros in .idx
99 | ;; file, with a blank space after \IeC
100 |
101 | ;; Details of the syntax are explained at
102 | ;; http://xindy.sourceforge.net/doc/manual-3.html
103 | ;; In absence of :string, "xindy uses an auto-detection mechanism to decide,
104 | ;; if the pattern is a regular expression or not". But it is not obvious to
105 | ;; guess, for example "\\_" is not detected as RE but "\\P\{\}" is, so for
106 | ;; being sure we apply the :string switch everywhere and do not use \\ etc...
107 |
108 | ;; Go back from sphinx.util.texescape TeX macros to UTF-8
109 |
110 | (merge-rule "\sphinxleftcurlybrace{}" "{" :string)
111 | (merge-rule "\sphinxrightcurlybrace{}" "}" :string)
112 | (merge-rule "\_" "_" :string)
113 | (merge-rule "{[}" "[" :string)
114 | (merge-rule "{]}" "]" :string)
115 | (merge-rule "{}`" "`" :string)
116 | (merge-rule "\textbackslash{}" "\" :string) ; " for Emacs syntax highlighting
117 | (merge-rule "\textasciitilde{}" "~~" :string); the ~~ escape is needed here
118 | (merge-rule "\textless{}" "<" :string)
119 | (merge-rule "\textgreater{}" ">" :string)
120 | (merge-rule "\textasciicircum{}" "^" :string)
121 | (merge-rule "\P{}" "¶" :string)
122 | (merge-rule "\S{}" "§" :string)
123 | (merge-rule "\texteuro{}" "€" :string)
124 | (merge-rule "\(\infty\)" "∞" :string)
125 | (merge-rule "\(\pm\)" "±" :string)
126 | (merge-rule "\(\rightarrow\)" "→" :string)
127 | (merge-rule "\(\checkmark\)" "✓" :string)
128 | (merge-rule "\textendash{}" "–" :string)
129 | (merge-rule "\textbar{}" "|" :string)
130 | (merge-rule "\(\sp{\text{0}}\)" "⁰" :string)
131 | (merge-rule "\(\sp{\text{1}}\)" "¹" :string)
132 | (merge-rule "\(\sp{\text{2}}\)" "²" :string)
133 | (merge-rule "\(\sp{\text{3}}\)" "³" :string)
134 | (merge-rule "\(\sp{\text{4}}\)" "⁴" :string)
135 | (merge-rule "\(\sp{\text{5}}\)" "⁵" :string)
136 | (merge-rule "\(\sp{\text{6}}\)" "⁶" :string)
137 | (merge-rule "\(\sp{\text{7}}\)" "⁷" :string)
138 | (merge-rule "\(\sp{\text{8}}\)" "⁸" :string)
139 | (merge-rule "\(\sp{\text{9}}\)" "⁹" :string)
140 | (merge-rule "\(\sb{\text{0}}\)" "₀" :string)
141 | (merge-rule "\(\sb{\text{1}}\)" "₁" :string)
142 | (merge-rule "\(\sb{\text{2}}\)" "₂" :string)
143 | (merge-rule "\(\sb{\text{3}}\)" "₃" :string)
144 | (merge-rule "\(\sb{\text{4}}\)" "₄" :string)
145 | (merge-rule "\(\sb{\text{5}}\)" "₅" :string)
146 | (merge-rule "\(\sb{\text{6}}\)" "₆" :string)
147 | (merge-rule "\(\sb{\text{7}}\)" "₇" :string)
148 | (merge-rule "\(\sb{\text{8}}\)" "₈" :string)
149 | (merge-rule "\(\sb{\text{9}}\)" "₉" :string)
150 | (merge-rule "\(\alpha\)" "α" :string)
151 | (merge-rule "\(\beta\)" "β" :string)
152 | (merge-rule "\(\gamma\)" "γ" :string)
153 | (merge-rule "\(\delta\)" "δ" :string)
154 | (merge-rule "\(\epsilon\)" "ε" :string)
155 | (merge-rule "\(\zeta\)" "ζ" :string)
156 | (merge-rule "\(\eta\)" "η" :string)
157 | (merge-rule "\(\theta\)" "θ" :string)
158 | (merge-rule "\(\iota\)" "ι" :string)
159 | (merge-rule "\(\kappa\)" "κ" :string)
160 | (merge-rule "\(\lambda\)" "λ" :string)
161 | (merge-rule "\(\mu\)" "μ" :string)
162 | (merge-rule "\(\nu\)" "ν" :string)
163 | (merge-rule "\(\xi\)" "ξ" :string)
164 | (merge-rule "\(\pi\)" "π" :string)
165 | (merge-rule "\(\rho\)" "ρ" :string)
166 | (merge-rule "\(\sigma\)" "σ" :string)
167 | (merge-rule "\(\tau\)" "τ" :string)
168 | (merge-rule "\(\upsilon\)" "υ" :string)
169 | (merge-rule "\(\phi\)" "φ" :string)
170 | (merge-rule "\(\chi\)" "χ" :string)
171 | (merge-rule "\(\psi\)" "ψ" :string)
172 | (merge-rule "\(\omega\)" "ω" :string)
173 | (merge-rule "\(\Gamma\)" "Γ" :string)
174 | (merge-rule "\(\Delta\)" "Δ" :string)
175 | (merge-rule "\(\Theta\)" "Θ" :string)
176 | (merge-rule "\(\Lambda\)" "Λ" :string)
177 | (merge-rule "\(\Xi\)" "Ξ" :string)
178 | (merge-rule "\(\Pi\)" "Π" :string)
179 | (merge-rule "\(\Sigma\)" "Σ" :string)
180 | (merge-rule "\(\Upsilon\)" "Υ" :string)
181 | (merge-rule "\(\Phi\)" "Φ" :string)
182 | (merge-rule "\(\Psi\)" "Ψ" :string)
183 | (merge-rule "\(\Omega\)" "Ω" :string)
184 |
185 | ;; This xindy module provides some basic support for "see"
186 | (require "makeindex.xdy")
187 |
188 | ;; This creates one-letter headings and works fine with utf-8 letters.
189 | ;; For Cyrillic with pdflatex works thanks to LICRcyr2utf8.xdy
190 | (require "latin-lettergroups.xdy")
191 |
192 | ;; currently we don't (know how to easily) separate "Numbers" from
193 | ;; "Symbols" with xindy as is the case with makeindex.
194 | (markup-index :open "\begin{sphinxtheindex}
195 | \let\lettergroup\sphinxstyleindexlettergroup
196 | \let\lettergroupDefault\sphinxstyleindexlettergroupDefault
197 | \let\spxpagem\sphinxstyleindexpagemain
198 | \let\spxentry\sphinxstyleindexentry
199 | \let\spxextra\sphinxstyleindexextra
200 |
201 | "
202 | :close "
203 |
204 | \end{sphinxtheindex}
205 | "
206 | :tree)
207 |
208 |
--------------------------------------------------------------------------------
/doc/_build/latex/sphinxhighlight.sty:
--------------------------------------------------------------------------------
1 | \NeedsTeXFormat{LaTeX2e}[1995/12/01]
2 | \ProvidesPackage{sphinxhighlight}[2016/05/29 stylesheet for highlighting with pygments]
3 |
4 |
5 | \makeatletter
6 | \def\PYG@reset{\let\PYG@it=\relax \let\PYG@bf=\relax%
7 | \let\PYG@ul=\relax \let\PYG@tc=\relax%
8 | \let\PYG@bc=\relax \let\PYG@ff=\relax}
9 | \def\PYG@tok#1{\csname PYG@tok@#1\endcsname}
10 | \def\PYG@toks#1+{\ifx\relax#1\empty\else%
11 | \PYG@tok{#1}\expandafter\PYG@toks\fi}
12 | \def\PYG@do#1{\PYG@bc{\PYG@tc{\PYG@ul{%
13 | \PYG@it{\PYG@bf{\PYG@ff{#1}}}}}}}
14 | \def\PYG#1#2{\PYG@reset\PYG@toks#1+\relax+\PYG@do{#2}}
15 |
16 | \expandafter\def\csname PYG@tok@w\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.73,0.73}{##1}}}
17 | \expandafter\def\csname PYG@tok@c\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.56}{##1}}}
18 | \expandafter\def\csname PYG@tok@cp\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
19 | \expandafter\def\csname PYG@tok@cs\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.56}{##1}}\def\PYG@bc##1{\setlength{\fboxsep}{0pt}\colorbox[rgb]{1.00,0.94,0.94}{\strut ##1}}}
20 | \expandafter\def\csname PYG@tok@k\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
21 | \expandafter\def\csname PYG@tok@kp\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
22 | \expandafter\def\csname PYG@tok@kt\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.56,0.13,0.00}{##1}}}
23 | \expandafter\def\csname PYG@tok@o\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.40,0.40,0.40}{##1}}}
24 | \expandafter\def\csname PYG@tok@ow\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
25 | \expandafter\def\csname PYG@tok@nb\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
26 | \expandafter\def\csname PYG@tok@nf\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.02,0.16,0.49}{##1}}}
27 | \expandafter\def\csname PYG@tok@nc\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.05,0.52,0.71}{##1}}}
28 | \expandafter\def\csname PYG@tok@nn\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.05,0.52,0.71}{##1}}}
29 | \expandafter\def\csname PYG@tok@ne\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
30 | \expandafter\def\csname PYG@tok@nv\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.38,0.84}{##1}}}
31 | \expandafter\def\csname PYG@tok@no\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.38,0.68,0.84}{##1}}}
32 | \expandafter\def\csname PYG@tok@nl\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.13,0.44}{##1}}}
33 | \expandafter\def\csname PYG@tok@ni\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.84,0.33,0.22}{##1}}}
34 | \expandafter\def\csname PYG@tok@na\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
35 | \expandafter\def\csname PYG@tok@nt\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.02,0.16,0.45}{##1}}}
36 | \expandafter\def\csname PYG@tok@nd\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.33,0.33,0.33}{##1}}}
37 | \expandafter\def\csname PYG@tok@s\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
38 | \expandafter\def\csname PYG@tok@sd\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
39 | \expandafter\def\csname PYG@tok@si\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.44,0.63,0.82}{##1}}}
40 | \expandafter\def\csname PYG@tok@se\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
41 | \expandafter\def\csname PYG@tok@sr\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.14,0.33,0.53}{##1}}}
42 | \expandafter\def\csname PYG@tok@ss\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.32,0.47,0.09}{##1}}}
43 | \expandafter\def\csname PYG@tok@sx\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.78,0.36,0.04}{##1}}}
44 | \expandafter\def\csname PYG@tok@m\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.13,0.50,0.31}{##1}}}
45 | \expandafter\def\csname PYG@tok@gh\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.00,0.50}{##1}}}
46 | \expandafter\def\csname PYG@tok@gu\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.50,0.00,0.50}{##1}}}
47 | \expandafter\def\csname PYG@tok@gd\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.63,0.00,0.00}{##1}}}
48 | \expandafter\def\csname PYG@tok@gi\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.63,0.00}{##1}}}
49 | \expandafter\def\csname PYG@tok@gr\endcsname{\def\PYG@tc##1{\textcolor[rgb]{1.00,0.00,0.00}{##1}}}
50 | \expandafter\def\csname PYG@tok@ge\endcsname{\let\PYG@it=\textit}
51 | \expandafter\def\csname PYG@tok@gs\endcsname{\let\PYG@bf=\textbf}
52 | \expandafter\def\csname PYG@tok@gp\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.78,0.36,0.04}{##1}}}
53 | \expandafter\def\csname PYG@tok@go\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.20,0.20,0.20}{##1}}}
54 | \expandafter\def\csname PYG@tok@gt\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.27,0.87}{##1}}}
55 | \expandafter\def\csname PYG@tok@err\endcsname{\def\PYG@bc##1{\setlength{\fboxsep}{0pt}\fcolorbox[rgb]{1.00,0.00,0.00}{1,1,1}{\strut ##1}}}
56 | \expandafter\def\csname PYG@tok@kc\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
57 | \expandafter\def\csname PYG@tok@kd\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
58 | \expandafter\def\csname PYG@tok@kn\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
59 | \expandafter\def\csname PYG@tok@kr\endcsname{\let\PYG@bf=\textbf\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
60 | \expandafter\def\csname PYG@tok@bp\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.00,0.44,0.13}{##1}}}
61 | \expandafter\def\csname PYG@tok@fm\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.02,0.16,0.49}{##1}}}
62 | \expandafter\def\csname PYG@tok@vc\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.38,0.84}{##1}}}
63 | \expandafter\def\csname PYG@tok@vg\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.38,0.84}{##1}}}
64 | \expandafter\def\csname PYG@tok@vi\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.38,0.84}{##1}}}
65 | \expandafter\def\csname PYG@tok@vm\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.73,0.38,0.84}{##1}}}
66 | \expandafter\def\csname PYG@tok@sa\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
67 | \expandafter\def\csname PYG@tok@sb\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
68 | \expandafter\def\csname PYG@tok@sc\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
69 | \expandafter\def\csname PYG@tok@dl\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
70 | \expandafter\def\csname PYG@tok@s2\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
71 | \expandafter\def\csname PYG@tok@sh\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
72 | \expandafter\def\csname PYG@tok@s1\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.25,0.44,0.63}{##1}}}
73 | \expandafter\def\csname PYG@tok@mb\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.13,0.50,0.31}{##1}}}
74 | \expandafter\def\csname PYG@tok@mf\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.13,0.50,0.31}{##1}}}
75 | \expandafter\def\csname PYG@tok@mh\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.13,0.50,0.31}{##1}}}
76 | \expandafter\def\csname PYG@tok@mi\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.13,0.50,0.31}{##1}}}
77 | \expandafter\def\csname PYG@tok@il\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.13,0.50,0.31}{##1}}}
78 | \expandafter\def\csname PYG@tok@mo\endcsname{\def\PYG@tc##1{\textcolor[rgb]{0.13,0.50,0.31}{##1}}}
79 | \expandafter\def\csname PYG@tok@ch\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.56}{##1}}}
80 | \expandafter\def\csname PYG@tok@cm\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.56}{##1}}}
81 | \expandafter\def\csname PYG@tok@cpf\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.56}{##1}}}
82 | \expandafter\def\csname PYG@tok@c1\endcsname{\let\PYG@it=\textit\def\PYG@tc##1{\textcolor[rgb]{0.25,0.50,0.56}{##1}}}
83 |
84 | \def\PYGZbs{\char`\\}
85 | \def\PYGZus{\char`\_}
86 | \def\PYGZob{\char`\{}
87 | \def\PYGZcb{\char`\}}
88 | \def\PYGZca{\char`\^}
89 | \def\PYGZam{\char`\&}
90 | \def\PYGZlt{\char`\<}
91 | \def\PYGZgt{\char`\>}
92 | \def\PYGZsh{\char`\#}
93 | \def\PYGZpc{\char`\%}
94 | \def\PYGZdl{\char`\$}
95 | \def\PYGZhy{\char`\-}
96 | \def\PYGZsq{\char`\'}
97 | \def\PYGZdq{\char`\"}
98 | \def\PYGZti{\char`\~}
99 | % for compatibility with earlier versions
100 | \def\PYGZat{@}
101 | \def\PYGZlb{[}
102 | \def\PYGZrb{]}
103 | \makeatother
104 |
105 | \renewcommand\PYGZsq{\textquotesingle}
106 |
--------------------------------------------------------------------------------
/doc/_build/latex/sphinxhowto.cls:
--------------------------------------------------------------------------------
1 | %
2 | % sphinxhowto.cls for Sphinx (http://sphinx-doc.org/)
3 | %
4 |
5 | \NeedsTeXFormat{LaTeX2e}[1995/12/01]
6 | \ProvidesClass{sphinxhowto}[2018/12/22 v1.8.3 Document class (Sphinx howto)]
7 |
8 | % 'oneside' option overriding the 'twoside' default
9 | \newif\if@oneside
10 | \DeclareOption{oneside}{\@onesidetrue}
11 | % Pass remaining document options to the parent class.
12 | \DeclareOption*{\PassOptionsToClass{\CurrentOption}{\sphinxdocclass}}
13 | \ProcessOptions\relax
14 |
15 | % Default to two-side document
16 | \if@oneside
17 | % nothing to do (oneside is the default)
18 | \else
19 | \PassOptionsToClass{twoside}{\sphinxdocclass}
20 | \fi
21 |
22 | \LoadClass{\sphinxdocclass}
23 |
24 | % Set some sane defaults for section numbering depth and TOC depth. You can
25 | % reset these counters in your preamble.
26 | %
27 | \setcounter{secnumdepth}{2}
28 | \setcounter{tocdepth}{2}% i.e. section and subsection
29 |
30 | % Change the title page to look a bit better, and fit in with the fncychap
31 | % ``Bjarne'' style a bit better.
32 | %
33 | \newcommand{\sphinxmaketitle}{%
34 | \noindent\rule{\textwidth}{1pt}\par
35 | \begingroup % for PDF information dictionary
36 | \def\endgraf{ }\def\and{\& }%
37 | \pdfstringdefDisableCommands{\def\\{, }}% overwrite hyperref setup
38 | \hypersetup{pdfauthor={\@author}, pdftitle={\@title}}%
39 | \endgroup
40 | \begin{flushright}
41 | \sphinxlogo
42 | \py@HeaderFamily
43 | {\Huge \@title }\par
44 | {\itshape\large \py@release \releaseinfo}\par
45 | \vspace{25pt}
46 | {\Large
47 | \begin{tabular}[t]{c}
48 | \@author
49 | \end{tabular}}\par
50 | \vspace{25pt}
51 | \@date \par
52 | \py@authoraddress \par
53 | \end{flushright}
54 | \@thanks
55 | \setcounter{footnote}{0}
56 | \let\thanks\relax\let\maketitle\relax
57 | %\gdef\@thanks{}\gdef\@author{}\gdef\@title{}
58 | }
59 |
60 | \newcommand{\sphinxtableofcontents}{
61 | \begingroup
62 | \parskip = 0mm
63 | \tableofcontents
64 | \endgroup
65 | \rule{\textwidth}{1pt}
66 | \vspace{12pt}
67 | }
68 |
69 | \pagenumbering{arabic}
70 |
71 | % Fix the bibliography environment to add an entry to the Table of
72 | % Contents.
73 | % For an article document class this environment is a section,
74 | % so no page break before it.
75 | %
76 | \newenvironment{sphinxthebibliography}[1]{%
77 | % \phantomsection % not needed here since TeXLive 2010's hyperref
78 | \begin{thebibliography}{#1}%
79 | \addcontentsline{toc}{section}{\ifdefined\refname\refname\else\ifdefined\bibname\bibname\fi\fi}}{\end{thebibliography}}
80 |
81 |
82 | % Same for the indices.
83 | % The memoir class already does this, so we don't duplicate it in that case.
84 | %
85 | \@ifclassloaded{memoir}
86 | {\newenvironment{sphinxtheindex}{\begin{theindex}}{\end{theindex}}}
87 | {\newenvironment{sphinxtheindex}{%
88 | \phantomsection % needed because no chapter, section, ... is created by theindex
89 | \begin{theindex}%
90 | \addcontentsline{toc}{section}{\indexname}}{\end{theindex}}}
91 |
--------------------------------------------------------------------------------
/doc/_build/latex/sphinxmanual.cls:
--------------------------------------------------------------------------------
1 | %
2 | % sphinxmanual.cls for Sphinx (http://sphinx-doc.org/)
3 | %
4 |
5 | \NeedsTeXFormat{LaTeX2e}[1995/12/01]
6 | \ProvidesClass{sphinxmanual}[2018/12/22 v1.8.3 Document class (Sphinx manual)]
7 |
8 | % chapters starting at odd pages (overridden by 'openany' document option)
9 | \PassOptionsToClass{openright}{\sphinxdocclass}
10 |
11 | % 'oneside' option overriding the 'twoside' default
12 | \newif\if@oneside
13 | \DeclareOption{oneside}{\@onesidetrue}
14 | % Pass remaining document options to the parent class.
15 | \DeclareOption*{\PassOptionsToClass{\CurrentOption}{\sphinxdocclass}}
16 | \ProcessOptions\relax
17 |
18 | % Defaults two-side document
19 | \if@oneside
20 | % nothing to do (oneside is the default)
21 | \else
22 | \PassOptionsToClass{twoside}{\sphinxdocclass}
23 | \fi
24 |
25 | \LoadClass{\sphinxdocclass}
26 |
27 | % Set some sane defaults for section numbering depth and TOC depth. You can
28 | % reset these counters in your preamble.
29 | %
30 | \setcounter{secnumdepth}{2}
31 | \setcounter{tocdepth}{1}
32 |
33 | % Change the title page to look a bit better, and fit in with the fncychap
34 | % ``Bjarne'' style a bit better.
35 | %
36 | \newcommand{\sphinxmaketitle}{%
37 | \let\spx@tempa\relax
38 | \ifHy@pageanchor\def\spx@tempa{\Hy@pageanchortrue}\fi
39 | \hypersetup{pageanchor=false}% avoid duplicate destination warnings
40 | \begin{titlepage}%
41 | \let\footnotesize\small
42 | \let\footnoterule\relax
43 | \noindent\rule{\textwidth}{1pt}\par
44 | \begingroup % for PDF information dictionary
45 | \def\endgraf{ }\def\and{\& }%
46 | \pdfstringdefDisableCommands{\def\\{, }}% overwrite hyperref setup
47 | \hypersetup{pdfauthor={\@author}, pdftitle={\@title}}%
48 | \endgroup
49 | \begin{flushright}%
50 | \sphinxlogo
51 | \py@HeaderFamily
52 | {\Huge \@title \par}
53 | {\itshape\LARGE \py@release\releaseinfo \par}
54 | \vfill
55 | {\LARGE
56 | \begin{tabular}[t]{c}
57 | \@author
58 | \end{tabular}
59 | \par}
60 | \vfill\vfill
61 | {\large
62 | \@date \par
63 | \vfill
64 | \py@authoraddress \par
65 | }%
66 | \end{flushright}%\par
67 | \@thanks
68 | \end{titlepage}%
69 | \setcounter{footnote}{0}%
70 | \let\thanks\relax\let\maketitle\relax
71 | %\gdef\@thanks{}\gdef\@author{}\gdef\@title{}
72 | \clearpage
73 | \ifdefined\sphinxbackoftitlepage\sphinxbackoftitlepage\fi
74 | \if@openright\cleardoublepage\else\clearpage\fi
75 | \spx@tempa
76 | }
77 |
78 | \newcommand{\sphinxtableofcontents}{%
79 | \pagenumbering{roman}%
80 | \begingroup
81 | \parskip \z@skip
82 | \tableofcontents
83 | \endgroup
84 | % before resetting page counter, let's do the right thing.
85 | \if@openright\cleardoublepage\else\clearpage\fi
86 | \pagenumbering{arabic}%
87 | }
88 |
89 | % This is needed to get the width of the section # area wide enough in the
90 | % library reference. Doing it here keeps it the same for all the manuals.
91 | %
92 | \renewcommand*\l@section{\@dottedtocline{1}{1.5em}{2.6em}}
93 | \renewcommand*\l@subsection{\@dottedtocline{2}{4.1em}{3.5em}}
94 |
95 | % Fix the bibliography environment to add an entry to the Table of
96 | % Contents.
97 | % For a report document class this environment is a chapter.
98 | %
99 | \newenvironment{sphinxthebibliography}[1]{%
100 | \if@openright\cleardoublepage\else\clearpage\fi
101 | % \phantomsection % not needed here since TeXLive 2010's hyperref
102 | \begin{thebibliography}{#1}%
103 | \addcontentsline{toc}{chapter}{\bibname}}{\end{thebibliography}}
104 |
105 | % Same for the indices.
106 | % The memoir class already does this, so we don't duplicate it in that case.
107 | %
108 | \@ifclassloaded{memoir}
109 | {\newenvironment{sphinxtheindex}{\begin{theindex}}{\end{theindex}}}
110 | {\newenvironment{sphinxtheindex}{%
111 | \if@openright\cleardoublepage\else\clearpage\fi
112 | \phantomsection % needed as no chapter, section, ... created
113 | \begin{theindex}%
114 | \addcontentsline{toc}{chapter}{\indexname}}{\end{theindex}}}
115 |
--------------------------------------------------------------------------------
/doc/_build/latex/tutorial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/latex/tutorial.png
--------------------------------------------------------------------------------
/doc/_build/latex/tutorial_host_label.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/latex/tutorial_host_label.png
--------------------------------------------------------------------------------
/doc/_build/latex/tutorial_host_search.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/latex/tutorial_host_search.png
--------------------------------------------------------------------------------
/doc/_build/latex/tutorial_host_search_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_build/latex/tutorial_host_search_2.png
--------------------------------------------------------------------------------
/doc/_build/markdown/host.md:
--------------------------------------------------------------------------------
1 | # Web
2 |
3 | ## Introduction
4 |
5 | While small plots can easily be created and stored in a single HTML and JavaScript file, which are then loaded completely in the browsers memory, this is not possible for larger data sets due to browser limitations.
6 | In order to solve this problem, Faerun includes a small HTTP server (based on cherrypy) to serve the data to the browser.
7 |
8 | ## Creating Faerun Data Files
9 |
10 | As shown in Getting Started, Faerun can save data as `.faerun` data files using `pickle`.
11 |
12 | ```
13 | with open('helix.faerun', 'wb+') as handle:
14 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
15 | ```
16 |
17 | ## Starting a Faerun Web Server
18 |
19 | ```
20 | from faerun import host
21 |
22 | host('helix.faerun', label_type='default',
23 | theme='dark')
24 | ```
25 |
26 | ## Formatting Labels
27 |
28 | Labels can be formatted by defining a custom `label_formatter`. If no `label_formatter` is provided to the `host` function, the default is used:
29 |
30 | ```
31 | label_formatter = lambda label, index, name: label.split('__')[0]
32 | ```
33 |
34 | This default splits the label value on `'__'` to store different labels and enable search on different values the the displayed labels. See “Searching” for details. Defining a custom label formatter is straight forward. As an example, let’s prefix each label with a string and add their index and layer name:
35 |
36 | ```
37 | def custom_label_formatter(label, index, name):
38 | return f'Example: {label} ({index}, {name})'
39 |
40 | host('helix.faerun', label_type='default',
41 | theme='dark', label_formatter=custom_label_formatter)
42 | ```
43 |
44 | This function is then called whenever a label is requested from the server. In addition to the argument `label`, the arguments `index` and `name` can be used to further customize the displayed label and represent the integer index of the data point and the data layer they belong to (e.g. the name defined with `add_scatter`).
45 |
46 |
47 |
48 | 
49 |
50 | ## Adding Hyperlinks
51 |
52 | Faerun allows to link the data to an arbitrary URL which can be visited upon double-clicking a data point. In order to do this, a `link_formatter` has to be provided. This works similar to customizing the label.
53 |
54 | ```
55 | def custom_link_formatter(label, index, name):
56 | return f'https://www.google.com/search?q={label}'
57 |
58 | host('helix.faerun', label_type='default',
59 | theme='dark', link_formatter=custom_link_formatter)
60 | ```
61 |
62 | ## Searching
63 |
64 | The hosted version of a Faerun visualization also allows for searching. As a default, the search searches for exact matches in labels (substring or regex searches are not possible at this time).
65 |
66 |
67 |
68 | 
69 |
70 | However, the search can be customized. As described in “Formatting Labels”, additional label values can be added by separating them using `'__'`.
71 |
72 | ```
73 | c = np.random.randint(0, 2, len(x))
74 | labels = [''] * len(c)
75 |
76 | for i, e in enumerate(c):
77 | labels[i] = str(e) + '__' + str(i % 20)
78 |
79 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': labels}
80 | ```
81 |
82 | The above examples adds an additional label value and as default, the second label value is then used by the search.
83 |
84 |
85 |
86 | 
87 |
88 | If there are additional label values, the search index can be set using the `search_index` argument.
89 |
90 | ## Add Info / Documentation
91 |
92 | As the visualization is ready to be deployed to a publicly accessible web server, it might be of interest to add a documentation. The `host` method supports the argument `info` that accepts a (markdown formatted) string. This information is the desplayed on the generated web page.
93 |
94 | ```
95 | info = ('#Welcome to Fearun',
96 | 'This is a small Faerun example.'
97 | '',
98 | 'Yay markdown! This means that you can easily:',
99 | '- Add lists',
100 | '- Build tables',
101 | '- Insert images and links',
102 | '- Add code examples',
103 | '- ...'
104 | )
105 |
106 | host('helix.faerun', label_type='default', theme='dark',
107 | label_formatter=custom_label_formatter, link_formatter=custom_link_formatter,
108 | info='\n'.join(info))
109 | ```
110 |
111 | An info button is then shown next to the screenshot button, which upon click opens a window containing the info.
112 |
113 | ## Complete Example
114 |
115 | ```
116 | import pickle
117 | import numpy as np
118 | from faerun import Faerun, host
119 |
120 |
121 | def main():
122 | f = Faerun(title='faerun-example', clear_color='#222222', coords=False, view='free')
123 |
124 | x = np.linspace(0, 12.0, 326)
125 | y = np.sin(np.pi * x)
126 | z = np.cos(np.pi * x)
127 | c = np.random.randint(0, 2, len(x))
128 |
129 | labels = [''] * len(c)
130 |
131 | for i, e in enumerate(c):
132 | labels[i] = str(e) + '__' + str(i % 20)
133 |
134 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': labels}
135 |
136 | f.add_scatter('helix', data, shader='sphere', colormap='Dark2', point_scale=5.0,
137 | categorical=True, has_legend=True, legend_labels=[(0, 'Zero'), (1, 'One')])
138 |
139 | f.plot('helix')
140 |
141 | with open('helix.faerun', 'wb+') as handle:
142 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
143 |
144 | def custom_label_formatter(label, index, name):
145 | return f'Example: {label} ({index}, {name})'
146 |
147 | def custom_link_formatter(label, index, name):
148 | return f'https://www.google.com/search?q={label}'
149 |
150 | info = ('#Welcome to Fearun',
151 | 'This is a small Faerun example.'
152 | '',
153 | 'Yay markdown! This means that you can easily:',
154 | '- Add lists',
155 | '- Build tables',
156 | '- Insert images and links',
157 | '- Add code examples',
158 | '- ...'
159 | )
160 |
161 | host('helix.faerun', label_type='default', theme='dark',
162 | label_formatter=custom_label_formatter, link_formatter=custom_link_formatter,
163 | info='\n'.join(info))
164 |
165 |
166 | if __name__ == '__main__':
167 | main()
168 | ```
169 |
--------------------------------------------------------------------------------
/doc/_build/markdown/index.md:
--------------------------------------------------------------------------------
1 | # Welcome to Faerun’s documentation!
2 |
3 | Here are some teasers.
4 |
5 |
6 |
7 | 
8 |
9 |
10 |
11 | 
12 |
13 | ## Table of Contents
14 |
15 | * Getting Started
16 |
17 | * Installation
18 |
19 | * Create a Plot Document
20 |
21 | * Preparing Data for Plotting
22 |
23 | * Adding a Scatter Layer
24 |
25 | * Saving to HTML
26 |
27 | * Saving to Faerun Data File
28 |
29 | * Complete Example
30 |
31 | * Web
32 |
33 | * Introduction
34 |
35 | * Creating Faerun Data Files
36 |
37 | * Starting a Faerun Web Server
38 |
39 | * Formatting Labels
40 |
41 | * Adding Hyperlinks
42 |
43 | * Searching
44 |
45 | * Add Info / Documentation
46 |
47 | * Complete Example
48 |
49 | * Documentation
50 |
51 | * Faerun
52 |
53 | * Web
54 |
--------------------------------------------------------------------------------
/doc/_build/markdown/tutorial.md:
--------------------------------------------------------------------------------
1 | # Getting Started
2 |
3 | ## Installation
4 |
5 | Faerun can be installed using pip.
6 |
7 | ```
8 | pip install faerun
9 | ```
10 |
11 | In order to use it in a script, the class `Faerun` has to be imported from the package.
12 |
13 | ```
14 | from faerun import Faerun
15 | ```
16 |
17 | That’s it for the installation.
18 |
19 | ## Create a Plot Document
20 |
21 | In order to plot, a plot document has to be created. To do so, create an instance of the class `Faerun`
22 |
23 | ```
24 | from faerun import Faerun
25 |
26 | f = Faerun(title='faerun-example', clear_color='#222222', coords=False, view='free')
27 | ```
28 |
29 | Here, we set the `title` of the plot document. This will be used as the title of the HTML document. The clear color of the canvas, which is the background color of the plot, is set to `'#222222'` (which is the hex-code for a dark gray).
30 | The drawing of coordinate axes is disabled by setting `coords=False` and since we want to draw 3D data, the argument `view` is set to `'free'` to enable the user to pan and rotate the plot.
31 |
32 | ## Preparing Data for Plotting
33 |
34 | The next step is to prepare the data which is to be plotted. In the tutorial, we will just generate some nice looking data using `numpy`.
35 |
36 | ```
37 | import numpy as np
38 |
39 | x = np.linspace(0, 12.0, 326)
40 | y = np.sin(np.pi * x)
41 | z = np.cos(np.pi * x)
42 | c = np.random.randint(0, 6, len(x))
43 | ```
44 |
45 | This data can then be wrapped in a `dict`. In addition, `DataFrame` from the `pandas` package are also supported by faerun.
46 | In the example, the same values are used for the colors `c` and labels `labels`.
47 |
48 | ```
49 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': c}
50 | ```
51 |
52 | ## Adding a Scatter Layer
53 |
54 | Given the `Faerun` instance and the data, a scatter plot can be created using the method `add_scatter`.
55 |
56 | ```
57 | f.add_scatter('helix', data, shader='sphere', colormap='Dark2', point_scale=5.0,
58 | categorical=True, has_legend=True, legend_labels=[(0, 'Zero'), (1, 'One')])
59 | ```
60 |
61 | The data is added as a scatter layer named helix. The chose shader will render the data points as
62 | spheres (with diffuse and specular lighting) of size 5.0 with colors from the `matplotlib` colormap `'Dark2'`.
63 | As the `c` is categorical, the parameter `categorical` is set to `True`, otherwise `matplotlib` will mess up the values.
64 |
65 | Finally, `has_legend=True` adds the scatter layer to the legend and `legend_labels` is a `list` of `tuple`, associating values with a label.
66 |
67 | ## Saving to HTML
68 |
69 | The faerun document can the be plotted to an HTML document with an accompanying JavaScript data file.
70 |
71 | ```
72 | f.plot('helix')
73 | ```
74 |
75 | This saves the plot as `helix.html\` and \`\`helix.js`. The files can be opened locally or hosted on any web server.
76 |
77 |
78 |
79 | 
80 |
81 | ## Saving to Faerun Data File
82 |
83 | The faerun document can also be exported to a faerun data file, which in turn can then be hosted using the `web` module.
84 |
85 | ```
86 | import pickle
87 |
88 | with open('helix.faerun', 'wb+') as handle:
89 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
90 | ```
91 |
92 | ## Complete Example
93 |
94 | ```
95 | import pickle
96 | import numpy as np
97 | from faerun import Faerun
98 |
99 | def main():
100 | f = Faerun(title='faerun-example', clear_color='#222222', coords=False, view='free')
101 |
102 | x = np.linspace(0, 12.0, 326)
103 | y = np.sin(np.pi * x)
104 | z = np.cos(np.pi * x)
105 | c = np.random.randint(0, 2, len(x))
106 |
107 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': c}
108 |
109 | f.add_scatter('helix', data, shader='sphere', colormap='Dark2', point_scale=5.0,
110 | categorical=True, has_legend=True, legend_labels=[(0, 'Zero'), (1, 'One')])
111 |
112 | f.plot('helix')
113 |
114 | with open('helix.faerun', 'wb+') as handle:
115 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
116 |
117 | if __name__ == '__main__':
118 | main()
119 | ```
120 |
--------------------------------------------------------------------------------
/doc/_static/drugbank_2d_dark.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_static/drugbank_2d_dark.png
--------------------------------------------------------------------------------
/doc/_static/drugbank_2d_light.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_static/drugbank_2d_light.png
--------------------------------------------------------------------------------
/doc/_static/tutorial.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_static/tutorial.png
--------------------------------------------------------------------------------
/doc/_static/tutorial_host_label.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_static/tutorial_host_label.png
--------------------------------------------------------------------------------
/doc/_static/tutorial_host_search.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_static/tutorial_host_search.png
--------------------------------------------------------------------------------
/doc/_static/tutorial_host_search_2.png:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/doc/_static/tutorial_host_search_2.png
--------------------------------------------------------------------------------
/doc/conf.py:
--------------------------------------------------------------------------------
1 | # Configuration file for the Sphinx documentation builder.
2 | #
3 | # This file only contains a selection of the most common options. For a full
4 | # list see the documentation:
5 | # http://www.sphinx-doc.org/en/master/config
6 |
7 | # -- Path setup --------------------------------------------------------------
8 |
9 | # If extensions (or modules to document with autodoc) are in another directory,
10 | # add these directories to sys.path here. If the directory is relative to the
11 | # documentation root, use os.path.abspath to make it absolute, like shown here.
12 | #
13 | import os
14 | import sys
15 |
16 | import sphinx_rtd_theme
17 |
18 | sys.path.insert(0, os.path.abspath('..'))
19 |
20 |
21 | # -- Project information -----------------------------------------------------
22 |
23 | project = 'Faerun'
24 | copyright = '2019, Daniel Probst (Reymond Group, University of Bern)'
25 | author = 'Daniel Probst (Reymond Group, University of Bern)'
26 |
27 | # The full version, including alpha/beta/rc tags
28 | release = '1.0'
29 |
30 |
31 | # -- General configuration ---------------------------------------------------
32 |
33 | # Add any Sphinx extension module names here, as strings. They can be
34 | # extensions coming with Sphinx (named 'sphinx.ext.*') or your custom
35 | # ones.
36 | extensions = [
37 | 'sphinx.ext.autodoc',
38 | 'sphinx.ext.coverage',
39 | 'sphinx.ext.napoleon',
40 | 'sphinx.ext.autosummary',
41 | 'sphinx_markdown_builder'
42 | ]
43 |
44 | autoclass_content = 'both'
45 | autosummary_generate = True
46 |
47 | # Add any paths that contain templates here, relative to this directory.
48 | templates_path = ['_templates']
49 |
50 | # List of patterns, relative to source directory, that match files and
51 | # directories to ignore when looking for source files.
52 | # This pattern also affects html_static_path and html_extra_path.
53 | exclude_patterns = ['_build', 'Thumbs.db', '.DS_Store']
54 |
55 | master_doc = 'index'
56 |
57 | # -- Options for HTML output -------------------------------------------------
58 |
59 | # The theme to use for HTML and HTML Help pages. See the documentation for
60 | # a list of builtin themes.
61 | #
62 | # pip install sphinx_rtd_theme
63 | html_theme = 'sphinx_rtd_theme'
64 | html_theme_path = [sphinx_rtd_theme.get_html_theme_path()]
65 |
66 | # Add any paths that contain custom static files (such as style sheets) here,
67 | # relative to this directory. They are copied after the builtin static files,
68 | # so a file named "default.css" will overwrite the builtin "default.css".
69 | html_static_path = ['_static']
70 | htmlhelp_basename = 'faerun-doc'
71 |
72 |
73 | # -- Extension configuration -------------------------------------------------
74 | def skip(app, what, name, obj, would_skip, options):
75 | if name == "__init__":
76 | return False
77 | return would_skip
78 |
79 | def setup(app):
80 | app.connect("autodoc-skip-member", skip)
81 |
--------------------------------------------------------------------------------
/doc/documentation.rst:
--------------------------------------------------------------------------------
1 | Documentation
2 | -------------
3 |
4 | Faerun
5 | ^^^^^^
6 | .. autoclass:: faerun.Faerun
7 | :members:
8 |
9 | Web
10 | ^^^
11 | .. autofunction:: faerun.host
12 |
--------------------------------------------------------------------------------
/doc/host.rst:
--------------------------------------------------------------------------------
1 | Web
2 | ---
3 |
4 | Introduction
5 | ^^^^^^^^^^^^
6 | While small plots can easily be created and stored in a single HTML and JavaScript file, which are then loaded completely in the browsers memory, this is not possible for larger data sets due to browser limitations.
7 | In order to solve this problem, Faerun includes a small HTTP server (based on cherrypy) to serve the data to the browser.
8 |
9 | Creating Faerun Data Files
10 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
11 | As shown in :doc:`tutorial`, Faerun can save data as ``.faerun`` data files using ``pickle``.
12 |
13 | .. code-block:: python
14 |
15 | with open('helix.faerun', 'wb+') as handle:
16 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
17 |
18 | Starting a Faerun Web Server
19 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^^
20 | .. code-block:: python
21 |
22 | from faerun import host
23 |
24 | host('helix.faerun', label_type='default',
25 | theme='dark')
26 |
27 | Formatting Labels
28 | ^^^^^^^^^^^^^^^^^
29 | Labels can be formatted by defining a custom ``label_formatter``. If no ``label_formatter`` is provided to the ``host`` function, the default is used:
30 |
31 | .. code-block:: python
32 |
33 | label_formatter = lambda label, index, name: label.split('__')[0]
34 |
35 | This default splits the label value on ``'__'`` to store different labels and enable search on different values the the displayed labels. See "Searching" for details. Defining a custom label formatter is straight forward. As an example, let's prefix each label with a string and add their index and layer name:
36 |
37 | .. code-block:: python
38 |
39 | def custom_label_formatter(label, index, name):
40 | return f'Example: {label} ({index}, {name})'
41 |
42 | host('helix.faerun', label_type='default',
43 | theme='dark', label_formatter=custom_label_formatter)
44 |
45 | This function is then called whenever a label is requested from the server. In addition to the argument ``label``, the arguments ``index`` and ``name`` can be used to further customize the displayed label and represent the integer index of the data point and the data layer they belong to (e.g. the name defined with ``add_scatter``).
46 |
47 | .. image:: _static/tutorial_host_label.png
48 | :alt: Example of a custom label formatter.
49 |
50 | Adding Hyperlinks
51 | ^^^^^^^^^^^^^^^^^
52 | Faerun allows to link the data to an arbitrary URL which can be visited upon double-clicking a data point. In order to do this, a ``link_formatter`` has to be provided. This works similar to customizing the label.
53 |
54 | .. code-block:: python
55 |
56 | def custom_link_formatter(label, index, name):
57 | return f'https://www.google.com/search?q={label}'
58 |
59 | host('helix.faerun', label_type='default',
60 | theme='dark', link_formatter=custom_link_formatter)
61 |
62 |
63 | Searching
64 | ^^^^^^^^^
65 | The hosted version of a Faerun visualization also allows for searching. As a default, the search searches for exact matches in labels (substring or regex searches are not possible at this time).
66 |
67 | .. image:: _static/tutorial_host_search.png
68 | :alt: The result of a search.
69 |
70 | However, the search can be customized. As described in "Formatting Labels", additional label values can be added by separating them using ``'__'``.
71 |
72 | .. code-block:: python
73 |
74 | c = np.random.randint(0, 2, len(x))
75 | labels = [''] * len(c)
76 |
77 | for i, e in enumerate(c):
78 | labels[i] = str(e) + '__' + str(i % 20)
79 |
80 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': labels}
81 |
82 | The above examples adds an additional label value and as default, the second label value is then used by the search.
83 |
84 | .. image:: _static/tutorial_host_search_2.png
85 | :alt: The result of a custom search.
86 |
87 | If there are additional label values, the search index can be set using the ``search_index`` argument.
88 |
89 | Add Info / Documentation
90 | ^^^^^^^^^^^^^^^^^^^^^^^^
91 | As the visualization is ready to be deployed to a publicly accessible web server, it might be of interest to add a documentation. The ``host`` method supports the argument ``info`` that accepts a (markdown formatted) string. This information is the desplayed on the generated web page.
92 |
93 | .. code-block:: python
94 |
95 | info = ('#Welcome to Fearun',
96 | 'This is a small Faerun example.'
97 | '',
98 | 'Yay markdown! This means that you can easily:',
99 | '- Add lists',
100 | '- Build tables',
101 | '- Insert images and links',
102 | '- Add code examples',
103 | '- ...'
104 | )
105 |
106 | host('helix.faerun', label_type='default', theme='dark',
107 | label_formatter=custom_label_formatter, link_formatter=custom_link_formatter,
108 | info='\n'.join(info))
109 |
110 | An info button is then shown next to the screenshot button, which upon click opens a window containing the info.
111 |
112 | Complete Example
113 | ^^^^^^^^^^^^^^^^
114 |
115 | .. code-block:: python
116 |
117 | import pickle
118 | import numpy as np
119 | from faerun import Faerun, host
120 |
121 |
122 | def main():
123 | f = Faerun(title='faerun-example', clear_color='#222222', coords=False, view='free')
124 |
125 | x = np.linspace(0, 12.0, 326)
126 | y = np.sin(np.pi * x)
127 | z = np.cos(np.pi * x)
128 | c = np.random.randint(0, 2, len(x))
129 |
130 | labels = [''] * len(c)
131 |
132 | for i, e in enumerate(c):
133 | labels[i] = str(e) + '__' + str(i % 20)
134 |
135 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': labels}
136 |
137 | f.add_scatter('helix', data, shader='sphere', colormap='Dark2', point_scale=5.0,
138 | categorical=True, has_legend=True, legend_labels=[(0, 'Zero'), (1, 'One')])
139 |
140 | f.plot('helix')
141 |
142 | with open('helix.faerun', 'wb+') as handle:
143 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
144 |
145 | def custom_label_formatter(label, index, name):
146 | return f'Example: {label} ({index}, {name})'
147 |
148 | def custom_link_formatter(label, index, name):
149 | return f'https://www.google.com/search?q={label}'
150 |
151 | info = ('#Welcome to Fearun',
152 | 'This is a small Faerun example.'
153 | '',
154 | 'Yay markdown! This means that you can easily:',
155 | '- Add lists',
156 | '- Build tables',
157 | '- Insert images and links',
158 | '- Add code examples',
159 | '- ...'
160 | )
161 |
162 | host('helix.faerun', label_type='default', theme='dark',
163 | label_formatter=custom_label_formatter, link_formatter=custom_link_formatter,
164 | info='\n'.join(info))
165 |
166 |
167 | if __name__ == '__main__':
168 | main()
169 |
170 |
--------------------------------------------------------------------------------
/doc/index.rst:
--------------------------------------------------------------------------------
1 | Welcome to Faerun's documentation!
2 | ==================================
3 | Here are some teasers.
4 |
5 | .. image:: _static/drugbank_2d_light.png
6 | :alt: Example of Drugbank compounds in 2d with the light theme.
7 |
8 | .. image:: _static/drugbank_2d_dark.png
9 | :alt: Example of Drugbank compounds in 2d with the dark theme.
10 |
11 | Table of Contents
12 | -----------------
13 |
14 | .. toctree::
15 |
16 | tutorial
17 | host
18 | documentation
19 |
--------------------------------------------------------------------------------
/doc/make.bat:
--------------------------------------------------------------------------------
1 | @ECHO OFF
2 |
3 | pushd %~dp0
4 |
5 | REM Command file for Sphinx documentation
6 |
7 | if "%SPHINXBUILD%" == "" (
8 | set SPHINXBUILD=sphinx-build
9 | )
10 | set SOURCEDIR=.
11 | set BUILDDIR=_build
12 |
13 | if "%1" == "" goto help
14 |
15 | %SPHINXBUILD% >NUL 2>NUL
16 | if errorlevel 9009 (
17 | echo.
18 | echo.The 'sphinx-build' command was not found. Make sure you have Sphinx
19 | echo.installed, then set the SPHINXBUILD environment variable to point
20 | echo.to the full path of the 'sphinx-build' executable. Alternatively you
21 | echo.may add the Sphinx directory to PATH.
22 | echo.
23 | echo.If you don't have Sphinx installed, grab it from
24 | echo.http://sphinx-doc.org/
25 | exit /b 1
26 | )
27 |
28 | %SPHINXBUILD% -M %1 %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
29 | goto end
30 |
31 | :help
32 | %SPHINXBUILD% -M help %SOURCEDIR% %BUILDDIR% %SPHINXOPTS% %O%
33 |
34 | :end
35 | popd
36 |
--------------------------------------------------------------------------------
/doc/tutorial.rst:
--------------------------------------------------------------------------------
1 | Getting Started
2 | ---------------
3 |
4 | Installation
5 | ^^^^^^^^^^^^
6 | Faerun can be installed using pip.
7 |
8 | .. code-block:: bash
9 |
10 | pip install faerun
11 |
12 | In order to use it in a script, the class ``Faerun`` has to be imported from the package.
13 |
14 | .. code-block:: python
15 |
16 | from faerun import Faerun
17 |
18 | That's it for the installation.
19 |
20 | Create a Plot Document
21 | ^^^^^^^^^^^^^^^^^^^^^^
22 | In order to plot, a plot document has to be created. To do so, create an instance of the class ``Faerun``
23 |
24 | .. code-block:: python
25 |
26 | from faerun import Faerun
27 |
28 | f = Faerun(title='faerun-example', clear_color='#222222', coords=False, view='free')
29 |
30 | Here, we set the ``title`` of the plot document. This will be used as the title of the HTML document. The clear color of the canvas, which is the background color of the plot, is set to ``'#222222'`` (which is the hex-code for a dark gray).
31 | The drawing of coordinate axes is disabled by setting ``coords=False`` and since we want to draw 3D data, the argument ``view`` is set to ``'free'`` to enable the user to pan and rotate the plot.
32 |
33 | Preparing Data for Plotting
34 | ^^^^^^^^^^^^^^^^^^^^^^^^^^^
35 | The next step is to prepare the data which is to be plotted. In the tutorial, we will just generate some nice looking data using ``numpy``.
36 |
37 | .. code-block:: python
38 |
39 | import numpy as np
40 |
41 | x = np.linspace(0, 12.0, 326)
42 | y = np.sin(np.pi * x)
43 | z = np.cos(np.pi * x)
44 | c = np.random.randint(0, 6, len(x))
45 |
46 | This data can then be wrapped in a ``dict``. In addition, ``DataFrame`` from the ``pandas`` package are also supported by faerun.
47 | In the example, the same values are used for the colors ``c`` and labels ``labels``.
48 |
49 | .. code-block:: python
50 |
51 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': c}
52 |
53 | Adding a Scatter Layer
54 | ^^^^^^^^^^^^^^^^^^^^^^
55 | Given the ``Faerun`` instance and the data, a scatter plot can be created using the method ``add_scatter``.
56 |
57 | .. code-block:: python
58 |
59 | f.add_scatter('helix', data, shader='sphere', colormap='Dark2', point_scale=5.0,
60 | categorical=True, has_legend=True, legend_labels=[(0, 'Zero'), (1, 'One')])
61 |
62 | The data is added as a scatter layer named helix. The chose shader will render the data points as
63 | spheres (with diffuse and specular lighting) of size 5.0 with colors from the ``matplotlib`` colormap ``'Dark2'``.
64 | As the ``c`` is categorical, the parameter ``categorical`` is set to ``True``, otherwise ``matplotlib`` will mess up the values.
65 |
66 | Finally, ``has_legend=True`` adds the scatter layer to the legend and ``legend_labels`` is a ``list`` of ``tuple``, associating values with a label.
67 |
68 | Saving to HTML
69 | ^^^^^^^^^^^^^^
70 | The faerun document can the be plotted to an HTML document with an accompanying JavaScript data file.
71 |
72 | .. code-block:: python
73 |
74 | f.plot('helix')
75 |
76 | This saves the plot as ``helix.html` and ``helix.js``. The files can be opened locally or hosted on any web server.
77 |
78 | .. image:: _static/tutorial.png
79 | :alt: A helix drawn using faerun.
80 |
81 | Saving to Faerun Data File
82 | ^^^^^^^^^^^^^^^^^^^^^^^^^^
83 | The faerun document can also be exported to a faerun data file, which in turn can then be hosted using the ``web`` module.
84 |
85 | .. code-block:: python
86 |
87 | import pickle
88 |
89 | with open('helix.faerun', 'wb+') as handle:
90 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
91 |
92 | Complete Example
93 | ^^^^^^^^^^^^^^^^
94 | .. code-block:: python
95 |
96 | import pickle
97 | import numpy as np
98 | from faerun import Faerun
99 |
100 | def main():
101 | f = Faerun(title='faerun-example', clear_color='#222222', coords=False, view='free')
102 |
103 | x = np.linspace(0, 12.0, 326)
104 | y = np.sin(np.pi * x)
105 | z = np.cos(np.pi * x)
106 | c = np.random.randint(0, 2, len(x))
107 |
108 | data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': c}
109 |
110 | f.add_scatter('helix', data, shader='sphere', colormap='Dark2', point_scale=5.0,
111 | categorical=True, has_legend=True, legend_labels=[(0, 'Zero'), (1, 'One')])
112 |
113 | f.plot('helix')
114 |
115 | with open('helix.faerun', 'wb+') as handle:
116 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
117 |
118 | if __name__ == '__main__':
119 | main()
120 |
121 |
--------------------------------------------------------------------------------
/examples/example.py:
--------------------------------------------------------------------------------
1 | import numpy as np
2 | import pandas as pd
3 | import tmap as tm
4 | from faerun import Faerun, FaerunPlot
5 | from rdkit.Chem import AllChem
6 | from rdkit.Chem import rdMolDescriptors as Descriptors
7 | from sklearn.decomposition import PCA
8 |
9 |
10 | def get_fingerprint(in_smiles):
11 | results = []
12 | smiles = []
13 | for s in in_smiles:
14 | mol = AllChem.MolFromSmiles(s)
15 | if mol is not None:
16 | if mol.GetNumAtoms() > 100:
17 | continue
18 | mqn = Descriptors.MQNs_(mol)
19 | results.append(np.array(mqn))
20 | smiles.append(s)
21 |
22 | return results, smiles
23 |
24 |
25 | def load():
26 | drugbank = []
27 | with open("drugbank.smi") as f:
28 | for line in f.readlines():
29 | drugbank.append(line.split()[0].strip())
30 |
31 | mqns, smiles = get_fingerprint(drugbank)
32 | mqns = np.array(mqns)
33 |
34 | pca = PCA(n_components=3)
35 | result = pca.fit_transform(mqns)
36 | return result, mqns, smiles
37 |
38 |
39 | def load_tmap():
40 | drugbank = []
41 | with open("drugbank.smi") as f:
42 | for line in f.readlines():
43 | drugbank.append(line.split()[0].strip())
44 |
45 | mqns, smiles = get_fingerprint(drugbank)
46 | mqns = np.array(mqns)
47 |
48 | return tm.embed(mqns)
49 |
50 |
51 | coords, mqns, smiles = load()
52 | smiles = [s + "__This is a Test" for s in smiles]
53 |
54 | data = {"x": [], "y": [], "z": [], "c": [], "labels": smiles}
55 |
56 | for i, e in enumerate(coords):
57 | data["x"].append(coords[i][0])
58 | data["y"].append(coords[i][1])
59 | data["z"].append(coords[i][2])
60 | data["c"].append(mqns[i][0])
61 |
62 | df = pd.DataFrame.from_dict(data)
63 |
64 | # plot = FaerunPlot()
65 | # plot.add_series(x=df.x, y=df.y, z=df.z, c=df.c, labels=df.labels)
66 | # plot.save("test", "smiles")
67 |
68 | te = load_tmap()
69 |
70 | plot = FaerunPlot(view="front")
71 | plot.add_tmap_series(te, c=df.c)
72 | plot.save("test", "smiles")
73 |
--------------------------------------------------------------------------------
/examples/example_sin.py:
--------------------------------------------------------------------------------
1 | import numpy as np
2 | import pandas as pd
3 | from faerun import Faerun
4 | import pickle
5 |
6 |
7 | faerun = Faerun(view="free", clear_color="#222222")
8 |
9 | t = np.linspace(0, 12.0, 326)
10 | s = np.sin(np.pi * t)
11 | c = np.cos(np.pi * t)
12 | sizes = np.linspace(0.1, 2.0, 326)
13 |
14 | data = {"x": t, "y": s, "z": c, "c": t / max(t) * 100.0, "s": sizes}
15 |
16 | data2 = {"x": t, "y": c, "z": s, "c": t / max(t), "s": sizes, "labels": sizes}
17 |
18 | x = np.linspace(0, 12.0, 326)
19 | c = np.random.randint(0, 6, len(x))
20 | data3 = {
21 | "x": x,
22 | "y": np.random.rand(len(x)) - 0.5,
23 | "z": np.random.rand(len(x)) - 0.5,
24 | "c": [c, x],
25 | "cs": np.random.rand(len(x)),
26 | "s": [np.random.rand(len(x)), np.random.rand(len(x))],
27 | "labels": c,
28 | }
29 |
30 | legend_labels = [(0, "A"), (1, "B"), (2, "C"), (3, "D"), (4, "E"), (5, "F")]
31 |
32 | df = pd.DataFrame.from_dict(data)
33 | df2 = pd.DataFrame.from_dict(data2)
34 |
35 | faerun.add_scatter(
36 | "sinus",
37 | df,
38 | shader="circle",
39 | point_scale=5.0,
40 | has_legend=True,
41 | legend_labels=[(0.0, "Low"), (50.0, "Inbetween"), (df["c"].max(), "High")],
42 | )
43 | faerun.add_scatter(
44 | "cosinus", df2, shader="sphere", point_scale=5.0, colormap="jet", has_legend=True
45 | )
46 | faerun.add_scatter(
47 | "categorical",
48 | data3,
49 | shader="sphere",
50 | point_scale=5.0,
51 | colormap=["Set1", "viridis"],
52 | has_legend=True,
53 | categorical=[True, False],
54 | legend_labels=legend_labels,
55 | series_title=["A", "B"],
56 | ondblclick=["console.log(labels[0])", "console.log('B:' + labels[0])"],
57 | )
58 |
59 | with open("index.pickle", "wb+") as handle:
60 | pickle.dump(faerun.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
61 |
62 | file = open("index.pickle", "rb")
63 | obj = pickle.load(file)
64 | file.close()
65 |
66 | faerun.plot(template="default")
67 |
--------------------------------------------------------------------------------
/examples/example_web.py:
--------------------------------------------------------------------------------
1 | import pickle
2 | import random
3 | import numpy as np
4 | import pandas as pd
5 | from faerun import Faerun, host
6 | from rdkit.Chem import AllChem
7 | from rdkit.Chem import rdMolDescriptors as Descriptors
8 | from sklearn.decomposition import PCA
9 |
10 |
11 | def get_fingerprint(in_smiles):
12 | results = []
13 | smiles = []
14 | for s in in_smiles:
15 | mol = AllChem.MolFromSmiles(s)
16 | if mol is not None:
17 | if mol.GetNumAtoms() > 100:
18 | continue
19 | mqn = Descriptors.MQNs_(mol)
20 | results.append(np.array(mqn))
21 | smiles.append(s)
22 |
23 | return results, smiles
24 |
25 |
26 | def load():
27 | drugbank = []
28 | with open("drugbank.smi") as f:
29 | for line in f.readlines():
30 | drugbank.append(line.split()[0].strip())
31 |
32 | mqns, smiles = get_fingerprint(drugbank)
33 | mqns = np.array(mqns)
34 |
35 | pca = PCA(n_components=2)
36 | result = pca.fit_transform(mqns)
37 | return result, mqns, smiles
38 |
39 |
40 | def main():
41 | coords, mqns, smiles = load()
42 |
43 | data = {"x": [], "y": [], "c": [], "s": [], "labels": smiles}
44 |
45 | for i, _ in enumerate(coords):
46 | data["x"].append(coords[i][0])
47 | data["y"].append(coords[i][1])
48 | data["c"].append(mqns[i][0])
49 | data["s"].append(random.randint(1, 5))
50 |
51 | df = pd.DataFrame.from_dict(data)
52 |
53 | faerun = Faerun()
54 | faerun.add_scatter(
55 | "drugbank",
56 | df,
57 | shader="smoothCircle",
58 | point_scale=2.0,
59 | colormap="jet",
60 | has_legend=True,
61 | categorical=False,
62 | )
63 |
64 | with open("example.faerun", "wb+") as f:
65 | pickle.dump(faerun.create_python_data(), f, protocol=pickle.HIGHEST_PROTOCOL)
66 |
67 | info = (
68 | "#Welcome to Fearun",
69 | "This is a small demonstration visualising drugs stored in [Drugbank](http://drugbank.ca) using coordinates generated by a PCA projection."
70 | "",
71 | "By the way, this info was generated using markdown, this means that you can easily:",
72 | "- Add lists",
73 | "- Build tables",
74 | "- Insert images and links",
75 | "- Add code examples",
76 | "- ...",
77 | )
78 |
79 | host(
80 | "example.faerun",
81 | label_type="smiles",
82 | legend=True,
83 | theme="light",
84 | info="\n".join(info),
85 | )
86 |
87 |
88 | if __name__ == "__main__":
89 | main()
90 |
--------------------------------------------------------------------------------
/examples/example_web_3d.py:
--------------------------------------------------------------------------------
1 | import pickle
2 | import numpy as np
3 | import pandas as pd
4 | from faerun import Faerun, host
5 | from rdkit.Chem import AllChem
6 | from rdkit.Chem import rdMolDescriptors as Descriptors
7 | from sklearn.decomposition import PCA
8 |
9 |
10 | def get_fingerprint(in_smiles):
11 | results = []
12 | smiles = []
13 | for s in in_smiles:
14 | mol = AllChem.MolFromSmiles(s)
15 | if mol is not None:
16 | if mol.GetNumAtoms() > 100:
17 | continue
18 | mqn = Descriptors.MQNs_(mol)
19 | results.append(np.array(mqn))
20 | smiles.append(s)
21 |
22 | return results, smiles
23 |
24 |
25 | def load():
26 | drugbank = []
27 | with open('drugbank.smi') as f:
28 | for line in f.readlines():
29 | drugbank.append(line.split()[0].strip())
30 |
31 | mqns, smiles = get_fingerprint(drugbank)
32 | mqns = np.array(mqns)
33 |
34 | pca = PCA(n_components=3)
35 | result = pca.fit_transform(mqns)
36 | return result, mqns, smiles
37 |
38 | def main():
39 | coords, mqns, smiles = load()
40 |
41 | data = {
42 | 'x': [], 'y': [], 'z': [],
43 | 'c': [],
44 | 'labels': smiles
45 | }
46 |
47 | for i, _ in enumerate(coords):
48 | data['x'].append(coords[i][0])
49 | data['y'].append(coords[i][1])
50 | data['z'].append(coords[i][2])
51 | data['c'].append(mqns[i][0])
52 |
53 | df = pd.DataFrame.from_dict(data)
54 |
55 | faerun = Faerun()
56 | faerun.add_scatter('drugbank', df, shader='sphere', point_scale=5.0, colormap='jet', has_legend=True, categorical=False)
57 |
58 | with open('example.faerun', 'wb+') as f:
59 | pickle.dump(faerun.create_python_data(), f, protocol=pickle.HIGHEST_PROTOCOL)
60 |
61 | info = ('#Welcome to Fearun',
62 | 'This is a small demonstration visualising drugs stored in [Drugbank](http://drugbank.ca) using coordinates generated by a PCA projection.'
63 | '',
64 | 'By the way, this info was generated using markdown, this means that you can easily:',
65 | '- Add lists',
66 | '- Build tables',
67 | '- Insert images and links',
68 | '- Add code examples',
69 | '- ...'
70 | )
71 |
72 | host('example.faerun', label_type='default', legend=True, theme='dark',
73 | info='\n'.join(info), view='free')
74 |
75 | if __name__ == '__main__':
76 | main()
77 |
--------------------------------------------------------------------------------
/examples/index.pickle:
--------------------------------------------------------------------------------
https://raw.githubusercontent.com/reymond-group/faerun-python/f656b8d04bedd00f3f7943dfbe4b882f7bb72a6c/examples/index.pickle
--------------------------------------------------------------------------------
/examples/tutorial.py:
--------------------------------------------------------------------------------
1 | import pickle
2 | import numpy as np
3 | from faerun import Faerun
4 |
5 |
6 | def main():
7 | f = Faerun(clear_color="#222222", coords=True, view="front")
8 |
9 | x = np.linspace(0, 12.0, 326)
10 | y = np.sin(np.pi * x)
11 | z = np.cos(np.pi * x)
12 | c = np.random.randint(0, 2, len(x))
13 |
14 | labels = [str(l) + "__Test" for l in c]
15 |
16 | data = {"x": x, "y": y, "z": z, "c": c, "labels": labels}
17 |
18 | f.add_scatter(
19 | "helix",
20 | data,
21 | shader="smoothCircle",
22 | colormap="Dark2",
23 | point_scale=5.0,
24 | categorical=True,
25 | has_legend=True,
26 | legend_labels=[(0, "Zero"), (1, "One")],
27 | selected_labels=["None", "Just a Small Test"],
28 | )
29 |
30 | f.add_tree(
31 | "helixtree", {"from": [1, 5, 6, 7], "to": [2, 7, 8, 9]}, point_helper="helix"
32 | )
33 |
34 | f.plot("helix")
35 |
36 | with open("helix.faerun", "wb+") as handle:
37 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
38 |
39 |
40 | if __name__ == "__main__":
41 | main()
42 |
--------------------------------------------------------------------------------
/examples/tutorial_host.py:
--------------------------------------------------------------------------------
1 | import pickle
2 | import numpy as np
3 | from faerun import Faerun, host
4 |
5 |
6 | def main():
7 | f = Faerun(title="faerun-example", clear_color="#222222", coords=False, view="free")
8 |
9 | x = np.linspace(0, 12.0, 326)
10 | y = np.sin(np.pi * x)
11 | z = np.cos(np.pi * x)
12 | c = np.random.randint(0, 2, len(x))
13 |
14 | labels = [""] * len(c)
15 |
16 | for i, e in enumerate(c):
17 | labels[i] = str(e) + "__" + str(i % 20)
18 |
19 | data = {"x": x, "y": y, "z": z, "c": c, "labels": labels}
20 |
21 | f.add_scatter(
22 | "helix",
23 | data,
24 | shader="sphere",
25 | colormap="Dark2",
26 | point_scale=5.0,
27 | categorical=True,
28 | has_legend=True,
29 | legend_labels=[(0, "Zero"), (1, "One")],
30 | )
31 |
32 | f.plot("helix")
33 |
34 | with open("helix.faerun", "wb+") as handle:
35 | pickle.dump(f.create_python_data(), handle, protocol=pickle.HIGHEST_PROTOCOL)
36 |
37 | def custom_label_formatter(label, index, name):
38 | return f"Example: {label} ({index}, {name})"
39 |
40 | def custom_link_formatter(label, index, name):
41 | return f"https://www.google.com/search?q={label}"
42 |
43 | info = (
44 | "#Welcome to Fearun",
45 | "This is a small Faerun example." "",
46 | "Yay markdown! This means that you can easily:",
47 | "- Add lists",
48 | "- Build tables",
49 | "- Insert images and links",
50 | "- Add code examples",
51 | "- ...",
52 | )
53 |
54 | host(
55 | "helix.faerun",
56 | label_type="default",
57 | title="Helix",
58 | theme="dark",
59 | label_formatter=custom_label_formatter,
60 | link_formatter=custom_link_formatter,
61 | info="\n".join(info),
62 | )
63 |
64 |
65 | if __name__ == "__main__":
66 | main()
67 |
--------------------------------------------------------------------------------
/faerun/__init__.py:
--------------------------------------------------------------------------------
1 | import os
2 | from faerun.faerun import Faerun
3 | from faerun.web import host
4 |
5 | try:
6 | from .plot import FaerunPlot
7 | except:
8 | ...
9 |
10 | _ROOT = os.path.abspath(os.path.dirname(__file__))
11 |
12 |
13 | def get_asset(path):
14 | """Gets the path to the assets folder
15 |
16 | Arguments:
17 | path {str} -- The path of the asset within the asset folder
18 |
19 | Returns:
20 | str -- The full path to the asset
21 | """
22 | return os.path.join(_ROOT, "assets", path)
23 |
--------------------------------------------------------------------------------
/faerun/plot.py:
--------------------------------------------------------------------------------
1 | from cProfile import label
2 | from typing import Union, List, Iterable, Optional
3 | from tmap.core import TMAPEmbedding
4 | from faerun import Faerun
5 | from matplotlib.colors import Colormap
6 |
7 |
8 | class FaerunPlot:
9 | def __init__(
10 | self,
11 | clear_color: str = "#222222",
12 | coords: bool = False,
13 | view: str = "front",
14 | thumbnail_fixed: bool = False,
15 | impress: Optional[str] = None,
16 | ):
17 | if impress is None:
18 | impress = 'made with tmap
and faerun
source'
19 |
20 | self.f = Faerun(
21 | clear_color=clear_color,
22 | coords=coords,
23 | view=view,
24 | impress=impress,
25 | thumbnail_fixed=thumbnail_fixed,
26 | )
27 |
28 | def add_series(
29 | self,
30 | x: Iterable,
31 | y: Iterable,
32 | c: Union[List, List[List]],
33 | z: Optional[Iterable] = None,
34 | labels: Optional[List] = None,
35 | cmap: Union[Union[str, Colormap], List[Union[str, Colormap]]] = "viridis",
36 | categorical: Union[bool, List[bool]] = False,
37 | shader: str = "smoothCircle",
38 | point_scale: float = 2.0,
39 | title: Optional[Union[str, List[str]]] = None,
40 | show_legend: bool = True,
41 | legend_title: str = "",
42 | name: Optional[str] = None,
43 | ) -> str:
44 | multiple_c = any(isinstance(el, list) for el in c)
45 | n_c = 1
46 |
47 | if multiple_c:
48 | n_c = len(c)
49 |
50 | if title is None:
51 | if multiple_c:
52 | title = [str(i + 1) for i in range(n_c)]
53 | else:
54 | title = "1"
55 |
56 | if name is None:
57 | name = "Series" + str(len(self.f.scatters) + 1)
58 |
59 | data = {
60 | "x": x,
61 | "y": y,
62 | "c": c,
63 | }
64 |
65 | if z is not None:
66 | data["z"] = z
67 |
68 | if labels is not None:
69 | data["labels"] = labels
70 |
71 | self.f.add_scatter(
72 | name,
73 | data,
74 | shader=shader,
75 | colormap=cmap,
76 | point_scale=point_scale,
77 | categorical=categorical,
78 | has_legend=show_legend,
79 | # legend_labels=[],
80 | # selected_labels=["SMILES", "Drugbank ID", "Name"],
81 | series_title=title,
82 | # max_legend_label=[
83 | # None,
84 | # None,
85 | # None,
86 | # None,
87 | # None,
88 | # str(round(max(tpsa))),
89 | # str(round(max(logp))),
90 | # str(round(max(mw))),
91 | # str(round(max(h_acceptors))),
92 | # str(round(max(h_donors))),
93 | # str(round(max(ring_count))),
94 | # ],
95 | # min_legend_label=[
96 | # None,
97 | # None,
98 | # None,
99 | # None,
100 | # None,
101 | # str(round(min(tpsa))),
102 | # str(round(min(logp))),
103 | # str(round(min(mw))),
104 | # str(round(min(h_acceptors))),
105 | # str(round(min(h_donors))),
106 | # str(round(min(ring_count))),
107 | # ],
108 | # title_index=2,
109 | legend_title=legend_title,
110 | )
111 |
112 | return name
113 |
114 | def add_tree(self, target: str, s: Iterable, t: Iterable, color: str = "#666666"):
115 | self.f.add_tree(
116 | target + "Tree", {"from": s, "to": t}, point_helper=target, color=color
117 | )
118 |
119 | def add_tmap_series(
120 | self,
121 | tmap_embedding: TMAPEmbedding,
122 | c: Union[List, List[List]],
123 | z: Optional[Iterable] = None,
124 | labels: Optional[List] = None,
125 | cmap: Union[str, Colormap] = "viridis",
126 | categorical: bool = False,
127 | shader: str = "smoothCircle",
128 | point_scale: float = 2.0,
129 | title: str = None,
130 | show_legend: bool = True,
131 | legend_title: str = "",
132 | name: Optional[str] = None,
133 | add_tree: bool = True,
134 | tree_color: str = "#888888",
135 | ):
136 |
137 | series_name = self.add_series(
138 | tmap_embedding.x,
139 | tmap_embedding.y,
140 | c=c,
141 | z=z,
142 | labels=labels,
143 | cmap=cmap,
144 | categorical=categorical,
145 | shader=shader,
146 | point_scale=point_scale,
147 | title=title,
148 | show_legend=show_legend,
149 | legend_title=legend_title,
150 | name=name,
151 | )
152 |
153 | if add_tree:
154 | self.add_tree(series_name, tmap_embedding.s, tmap_embedding.t, tree_color)
155 |
156 | def save(self, name, template="default"):
157 | self.f.plot(name, template=template)
158 |
--------------------------------------------------------------------------------
/notebook/faerun.ipynb:
--------------------------------------------------------------------------------
1 | {
2 | "cells": [
3 | {
4 | "cell_type": "code",
5 | "execution_count": 1,
6 | "metadata": {},
7 | "outputs": [
8 | {
9 | "data": {
10 | "text/html": [
11 | "\n",
12 | " \n",
19 | " "
20 | ],
21 | "text/plain": [
22 | ""
23 | ]
24 | },
25 | "metadata": {},
26 | "output_type": "display_data"
27 | },
28 | {
29 | "data": {
30 | "text/html": [
31 | "./sine.html
"
32 | ],
33 | "text/plain": [
34 | "/home/daenu/Code/faerun-python/notebook/sine.html"
35 | ]
36 | },
37 | "metadata": {},
38 | "output_type": "display_data"
39 | }
40 | ],
41 | "source": [
42 | "import numpy as np\n",
43 | "from faerun import Faerun\n",
44 | "from IPython.core.display import HTML\n",
45 | "from IPython.display import IFrame\n",
46 | "\n",
47 | "f = Faerun(view='front', clear_color='#fff')\n",
48 | "\n",
49 | "x = np.linspace(0, 12.0, 326)\n",
50 | "y = np.sin(np.pi * x)\n",
51 | "c = np.sin(np.pi * x)\n",
52 | "\n",
53 | "data = {'x': x, 'y': y, 'c': c, 'labels': c}\n",
54 | "\n",
55 | "f.add_scatter('Sine', data, shader='smoothCircle', colormap='viridis', point_scale=2.5,\n",
56 | " has_legend=True)\n",
57 | "\n",
58 | "f.plot('sine')"
59 | ]
60 | },
61 | {
62 | "cell_type": "code",
63 | "execution_count": 2,
64 | "metadata": {
65 | "scrolled": false
66 | },
67 | "outputs": [
68 | {
69 | "data": {
70 | "text/html": [
71 | "\n",
72 | " \n",
79 | " "
80 | ],
81 | "text/plain": [
82 | ""
83 | ]
84 | },
85 | "metadata": {},
86 | "output_type": "display_data"
87 | },
88 | {
89 | "data": {
90 | "text/html": [
91 | "./helix.html
"
92 | ],
93 | "text/plain": [
94 | "/home/daenu/Code/faerun-python/notebook/helix.html"
95 | ]
96 | },
97 | "metadata": {},
98 | "output_type": "display_data"
99 | }
100 | ],
101 | "source": [
102 | "f = Faerun(view='free', clear_color='#262626')\n",
103 | "\n",
104 | "x = np.linspace(0, 12.0, 326)\n",
105 | "y = np.sin(np.pi * x)\n",
106 | "z = np.cos(np.pi * x)\n",
107 | "c = np.random.randint(0, 2, len(x))\n",
108 | "\n",
109 | "data = {'x': x, 'y': y, 'z': z, 'c': c, 'labels': c}\n",
110 | "\n",
111 | "f.add_scatter('Helix', data, shader='sphere', colormap='Dark2', point_scale=5.0,\n",
112 | " categorical=True, has_legend=True, legend_labels=[(1, 'One'), (0, 'Zero')])\n",
113 | "\n",
114 | "f.plot('helix')"
115 | ]
116 | },
117 | {
118 | "cell_type": "code",
119 | "execution_count": null,
120 | "metadata": {
121 | "scrolled": true
122 | },
123 | "outputs": [],
124 | "source": []
125 | },
126 | {
127 | "cell_type": "code",
128 | "execution_count": null,
129 | "metadata": {},
130 | "outputs": [],
131 | "source": []
132 | }
133 | ],
134 | "metadata": {
135 | "kernelspec": {
136 | "display_name": "Python 3",
137 | "language": "python",
138 | "name": "python3"
139 | },
140 | "language_info": {
141 | "codemirror_mode": {
142 | "name": "ipython",
143 | "version": 3
144 | },
145 | "file_extension": ".py",
146 | "mimetype": "text/x-python",
147 | "name": "python",
148 | "nbconvert_exporter": "python",
149 | "pygments_lexer": "ipython3",
150 | "version": "3.7.3"
151 | }
152 | },
153 | "nbformat": 4,
154 | "nbformat_minor": 2
155 | }
156 |
--------------------------------------------------------------------------------
/notebook/requirements.txt:
--------------------------------------------------------------------------------
1 | matplotlib>=3.0.2
2 | Jinja2>=2.10
3 | ujson>=1.35
4 | numpy>=1.15.4
5 | colour>=0.1.5
6 | CherryPy>=18.1.0
7 | pandas>=0.24.2
8 | faerun>=0.2.4
--------------------------------------------------------------------------------
/notebook/runtime.txt:
--------------------------------------------------------------------------------
1 | python-3.6
--------------------------------------------------------------------------------
/requirements.txt:
--------------------------------------------------------------------------------
1 | matplotlib>=3.0.2
2 | Jinja2>=2.10
3 | ujson>=1.35
4 | numpy>=1.15.4
5 | colour>=0.1.5
6 | CherryPy>=18.1.0
7 | Sphinx>=1.8.3
8 | autodoc>=0.5.0
9 | sphinx-markdown-builder>=0.4.1
10 | sphinx-rtd-theme>=0.4.3
11 | pandas>=0.24.2
12 | tmap-viz>=1.0.16
--------------------------------------------------------------------------------
/setup.py:
--------------------------------------------------------------------------------
1 | import sys
2 | import os
3 | from setuptools import setup
4 | from setuptools import Command
5 | from setuptools.command.test import test as TestCommand
6 | from datetime import datetime
7 |
8 |
9 | with open("README.md", "r") as fh:
10 | LONG_DESCRIPTION = fh.read()
11 |
12 | NAME = "faerun"
13 | VERSION = "0.4.6"
14 | AUTHOR = "Daniel Probst"
15 | DESCRIPTION = "A python package for generating interactive views of chemical spaces."
16 | URL = "https://github.com/reymond-group/faerun-python"
17 | REQUIRED_PYTHON_VERSION = (3, 0)
18 | PACKAGES = ["faerun"]
19 | INSTALL_DEPENDENCIES = [
20 | "matplotlib>=3.0.2",
21 | "Jinja2>=2.10",
22 | "ujson>=1.35",
23 | "numpy>=1.15.4",
24 | "colour>=0.1.5",
25 | "CherryPy>=18.1.0",
26 | "pandas>=0.24.2",
27 | ]
28 | SETUP_DEPENDENCIES = []
29 | TEST_DEPENDENCIES = ["pytest"]
30 | EXTRA_DEPENDENCIES = {"dev": ["pytest"]}
31 |
32 | if sys.version_info < REQUIRED_PYTHON_VERSION:
33 | sys.exit("Python >= 3.0 is required. Your version:\n" + sys.version)
34 |
35 |
36 | class PyTest(TestCommand):
37 | """
38 | Use pytest to run tests
39 | """
40 |
41 | user_options = [("pytest-args=", "a", "Arguments to pass into py.test")]
42 |
43 | def initialize_options(self):
44 | TestCommand.initialize_options(self)
45 | self.pytest_args = []
46 |
47 | def finalize_options(self):
48 | TestCommand.finalize_options(self)
49 | self.test_args = []
50 | self.test_suite = True
51 |
52 | def run_tests(self):
53 | import pytest
54 |
55 | errno = pytest.main(self.pytest_args)
56 | sys.exit(errno)
57 |
58 |
59 | setup(
60 | name=NAME,
61 | description=DESCRIPTION,
62 | long_description=LONG_DESCRIPTION,
63 | long_description_content_type="text/markdown",
64 | url=URL,
65 | version=VERSION,
66 | author=AUTHOR,
67 | packages=PACKAGES,
68 | include_package_data=True,
69 | python_requires=">=3",
70 | install_requires=INSTALL_DEPENDENCIES,
71 | setup_requires=SETUP_DEPENDENCIES,
72 | tests_require=TEST_DEPENDENCIES,
73 | extras_require=EXTRA_DEPENDENCIES,
74 | cmdclass={"test": PyTest},
75 | )
76 |
--------------------------------------------------------------------------------