|
| 1 | +Preface |
| 2 | +=============================================================================== |
| 3 | + |
| 4 | +.. contents:: . |
| 5 | + :local: |
| 6 | + :depth: 2 |
| 7 | + :class: toc preface |
| 8 | + |
| 9 | + |
| 10 | +This book is open-access (i.e. it's free to read at `this address |
| 11 | +<http://www.labri.fr/perso/nrougier/python+opengl>`_) because I believe |
| 12 | +knowledge should be free. However, *if you think the book is worth a few |
| 13 | +dollars* (`5€ <https://www.paypal.me/NicolasPRougier/5>`_ or `10€ |
| 14 | +<https://www.paypal.me/NicolasPRougier/10>`_), you can use `Paypal |
| 15 | +<https://www.paypal.me/NicolasPRougier/>`_ to make payment. This money will |
| 16 | +help me to travel to Python conferences and to write other books as well. If |
| 17 | +you don't have money, it's fine as well, just enjoy the book and spread the |
| 18 | +word about it. The teaser image above comes from the `artwork section |
| 19 | +<http://www.labri.fr/perso/nrougier/artwork/index.html>`_ of my website. It has |
| 20 | +been made some years ago using the `Povray <http://www.povray.org>`_ |
| 21 | +(Persistence of Vision) raytracer. I like it very much because it is a kind of |
| 22 | +résumé of my `research |
| 23 | +<http://www.labri.fr/perso/nrougier/research/index.html>`_. |
| 24 | + |
| 25 | + |
| 26 | +About the author |
| 27 | +------------------------------------------------------------------------------- |
| 28 | + |
| 29 | +I am a full-time research scientist at Inria_ which is the French national |
| 30 | +institute for research in computer science and control. This is a public |
| 31 | +scientific and technological establishment (EPST) under the double supervision |
| 32 | +of the Research & Education Ministry, and the Ministry of Economy Finance and |
| 33 | +Industry. I'm working within the Mnemosyne_ project which lies at the frontier |
| 34 | +between integrative and computational neuroscience in association with the |
| 35 | +`Institute of Neurodegenerative Diseases`_, the Bordeaux laboratory for |
| 36 | +research in computer science (LaBRI_), the `University of Bordeaux`_ and the |
| 37 | +national center for scientific research (CNRS_). |
| 38 | + |
| 39 | +I've been using Python for more than 15 years and numpy for more than 10 years |
| 40 | +for modeling in neuroscience, machine learning and for advanced visualization |
| 41 | +(OpenGL). I'm the author of several online resources and tutorials (Matplotlib, |
| 42 | +numpy, OpenGL) and he's teaching Python, numpy and scientific visualization at |
| 43 | +the University of Bordeaux and in various conferences and schools worldwide |
| 44 | +(SciPy, EuroScipy, etc). He's also the author of the popular article `Ten |
| 45 | +Simple Rules for Better Figures`_ , a popular `matplotlib tutorial`_ and an |
| 46 | +open access book `From Python To Numpy`_. |
| 47 | + |
| 48 | + |
| 49 | + |
| 50 | +About this book |
| 51 | +------------------------------------------------------------------------------- |
| 52 | + |
| 53 | +This book has been written in |ReST|_ format and generated using a `customized |
| 54 | +version <rst2html.py>`_ of the docutils rst2html.py command line (available from |
| 55 | +the docutils_ python package) and a custom `template <book-template.txt>`_. |
| 56 | + |
| 57 | +If you want to rebuild the html output, from the top directory, type: |
| 58 | + |
| 59 | +.. code-block:: |
| 60 | +
|
| 61 | + $ ./rst2html.py --link-stylesheet \ |
| 62 | + --cloak-email-addresses \ |
| 63 | + --toc-top-backlinks \ |
| 64 | + --stylesheet book.css \ |
| 65 | + --template book-template.txt \ |
| 66 | + --stylesheet-dirs . \ |
| 67 | + book.rst book.html |
| 68 | +
|
| 69 | +Or you use the provided `make.sh <make.sh>`_ shell script. |
| 70 | + |
| 71 | +The sources are available from https://github.com/rougier/python+opengl. |
| 72 | + |
| 73 | +Last point, I wrote the book in a kind of modern `Kerouac |
| 74 | +<https://en.wikipedia.org/wiki/Jack_Kerouac>`_'s style such that you can |
| 75 | +download it once and continue reading it offline. Initial loading may be |
| 76 | +slow though. |
| 77 | + |
| 78 | + |
| 79 | +.. |ReST| replace:: restructured text |
| 80 | +.. _ReST: http://docutils.sourceforge.net/rst.html |
| 81 | +.. _docutils: http://docutils.sourceforge.net/ |
| 82 | + |
| 83 | +Prerequisites |
| 84 | ++++++++++++++ |
| 85 | + |
| 86 | +This is not a Python nor a NumpPy beginner guide and you should have an |
| 87 | +intermediate level in both Python and NumPy. No prior knowledge of OpenGL is |
| 88 | +necessary because I'll explain everything. |
| 89 | + |
| 90 | +Conventions |
| 91 | ++++++++++++ |
| 92 | + |
| 93 | +I will use usual naming conventions. If not stated explicitly, each script |
| 94 | +should import numpy, scipy and glumpy as: |
| 95 | + |
| 96 | +.. code-block:: python |
| 97 | + |
| 98 | + import numpy as np |
| 99 | + import scipy as sp |
| 100 | + import glumpy as gp |
| 101 | +
|
| 102 | +
|
| 103 | +We'll use up-to-date versions (at the date of writing, i.e. August, 2017) of the |
| 104 | +different packages: |
| 105 | + |
| 106 | +=========== ========= |
| 107 | +Packages Version |
| 108 | +=========== ========= |
| 109 | +Python 3.6.0 |
| 110 | +----------- --------- |
| 111 | +Numpy 1.12.0 |
| 112 | +----------- --------- |
| 113 | +Scipy 0.18.1 |
| 114 | +----------- --------- |
| 115 | +Cython 0.25.2 |
| 116 | +----------- --------- |
| 117 | +Triangle 20170106 |
| 118 | +----------- --------- |
| 119 | +Glumpy 1.0.6 |
| 120 | +=========== ========= |
| 121 | + |
| 122 | +How to contribute |
| 123 | ++++++++++++++++++ |
| 124 | + |
| 125 | +If you want to contribute to this book, you can: |
| 126 | + |
| 127 | +* Report issues (https://github.com/rougier/python+opengl/issues) |
| 128 | +* Suggest improvements (https://github.com/rougier/python+opengl/pulls) |
| 129 | +* Correct English (https://github.com/rougier/python+opengl/issues) |
| 130 | +* Star the project (https://github.com/rougier/python+opengl) |
| 131 | +* Suggest a more responvise design for the HTML Book |
| 132 | +* Design a nice latex template for a PDF version |
| 133 | + |
| 134 | +Publishing |
| 135 | +++++++++++ |
| 136 | + |
| 137 | +If you're an editor interested in publishing this book, you can `contact me |
| 138 | +<mailto:[email protected]>`_ if you agree to have this version and all |
| 139 | +subsequent versions open access (i.e. online at `this address |
| 140 | +<http://www.labri.fr/perso/nrougier/python+opengl>`_), you know how to deal |
| 141 | +with `restructured text`_ (Word is not an option), you provide a real |
| 142 | +added-value as well as supporting services, and more importantly, you have a |
| 143 | +truly amazing latex book template (and be warned that I'm a bit picky about |
| 144 | +typography & design: `Edward Tufte <https://www.edwardtufte.com/tufte/>`_ is my |
| 145 | +hero). Still here? |
| 146 | + |
| 147 | + |
| 148 | +License |
| 149 | +------------------------------------------------------------------------------- |
| 150 | + |
| 151 | +Book |
| 152 | +++++ |
| 153 | + |
| 154 | +This work is licensed under a `Creative Commons Attribution-Non Commercial-Share |
| 155 | +Alike 4.0 International License <https://creativecommons.org/licenses/by-nc-sa/4.0/>`_. You are free to: |
| 156 | + |
| 157 | +* **Share** — copy and redistribute the material in any medium or format |
| 158 | +* **Adapt** — remix, transform, and build upon the material |
| 159 | + |
| 160 | +The licensor cannot revoke these freedoms as long as you follow the license terms. |
| 161 | + |
| 162 | +Code |
| 163 | +++++ |
| 164 | + |
| 165 | +The code is licensed under the `OSI-approved BSD 2-Clause License |
| 166 | +<LICENSE-code.txt>`_. |
| 167 | + |
| 168 | + |
| 169 | +.. --- Links ------------------------------------------------------------------ |
| 170 | +.. _Nicolas P. Rougier: |
| 171 | + http://www.labri.fr/perso/nrougier/ |
| 172 | +.. _Inria: |
| 173 | + http://www.inria.fr/en |
| 174 | +.. _Mnemosyne: |
| 175 | + http://www.inria.fr/en/teams/mnemosyne |
| 176 | +.. _LaBRI: |
| 177 | + https://www.labri.fr/ |
| 178 | +.. _CNRS: |
| 179 | + http://www.cnrs.fr/index.php |
| 180 | +.. _University of Bordeaux: |
| 181 | + http://www.u-bordeaux.com/ |
| 182 | +.. _Institute of Neurodegenerative Diseases: |
| 183 | + http://www.imn-bordeaux.org/en/ |
| 184 | +.. _Ten Simple Rules for Better Figures: |
| 185 | + http://dx.doi.org/10.1371/journal.pcbi.1003833 |
| 186 | +.. _matplotlib tutorial: |
| 187 | + http://www.labri.fr/perso/nrougier/teaching/matplotlib/matplotlib.html |
| 188 | +.. _From Python To Numpy: |
| 189 | + http://www.labri.fr/perso/nrougier/from-python-to-numpy/ |
| 190 | +.. ---------------------------------------------------------------------------- |
0 commit comments