@@ -6,60 +6,88 @@ Installation
66
77.. tip ::
88 For Windows users with relatively little experience with Python, we warmly
9- recommend to use the `Anaconda distribution <https://www.anaconda.com/products/distribution >`_.
10- Anaconda is an all-in-one package containing the Python compiler,
11- an integrated desktop environment (Spyder) and plenty of useful Python
12- packages such as numpy and matplotlib.
9+ recommend the `Anaconda distribution <https://www.anaconda.com/products/distribution >`_.
10+ Anaconda provides Python, an integrated desktop environment (Spyder), and
11+ widely used packages such as NumPy and Matplotlib.
1312
14- :program: `PyQInt ` is distributed via both Anaconda package as well as PyPI. For
15- Windows, it is recommended to install :program: `PyQInt ` via Anaconda, while
16- for Linux, we recommend to use PyPI.
13+ :program: `PyQInt ` is available via both Conda and PyPI. We recommend **using an
14+ isolated environment ** rather than installing into the global Python or Conda
15+ ``base `` environment. This avoids package conflicts and makes your setup easier
16+ to reproduce.
1717
18- Windows / Anaconda
19- ------------------
18+ Why environments?
19+ -----------------
20+ An environment keeps the packages for a project separate from the rest of your
21+ system (and from other projects). This prevents accidental upgrades or conflicts
22+ that can break existing setups. It also makes it easy to remove the environment
23+ later without touching your system-wide Python. For these reasons, installing
24+ into Conda’s ``base `` environment is discouraged.
2025
21- To install :program: ` PyQInt ` under Windows, open an Anaconda Prompt window
22- and run::
26+ Windows / Conda (recommended)
27+ -----------------------------
2328
24- conda install -c ifilot pyqint
29+ Create and activate a fresh Conda environment, then install :program: `PyQInt `::
30+
31+ conda create -n eoesc-env -c ifilot pyqint
32+ conda activate eoesc-env
2533
2634.. note ::
27- Sometimes Anaconda is unable to resolve the package dependencies. This can
28- be caused by a broken environment. An easy solution is to create a new
29- environment. See the "Troubleshooting" section at the end of this page
30- for more information.
35+ If you would like to use :program: `PyQInt `’s **isosurface functionality **,
36+ you will also need the optional package ``pytessel ``. You can install it
37+ together with :program: `PyQInt `::
3138
32- Linux / PyPI
33- ------------
39+ conda create -n eoesc-env -c ifilot pyqint pytessel
40+ conda activate eoesc-env
3441
35- To install :program: ` PyQInt ` systemwide, run ::
42+ or add it later with ::
3643
37- sudo pip install pyqint
44+ conda install -c ifilot pytessel
3845
39- or to install :program: `PyQInt ` only for the current user, run::
46+ Optionally install the Spyder IDE and common scientific packages::
47+
48+ conda install spyder matplotlib scipy pandas openpyxl
4049
50+ Linux / macOS / PyPI (recommended via virtual environment)
51+ ----------------------------------------------------------
52+
53+ Use Python’s built-in virtual environments to isolate your installation::
54+
55+ python3 -m venv venv
56+ source venv/bin/activate
57+ pip install --upgrade pip
4158 pip install pyqint
4259
43- Troubleshooting
44- ---------------
60+ Optional extra for **isosurface functionality **::
4561
46- The Anaconda packaging system can sometimes be quite finicky and sometimes
47- packages conflict with each other. A way to work around this issue is to create
48- a separate environment and only use that environment for the electronic
49- resources associated with this project.
62+ pip install pytessel
5063
51- To create the new environment (called eoesc-env) , run::
64+ To leave the environment, run::
5265
53- conda create -n eoesc-env python=3.11
66+ deactivate
5467
55- Next, open the environment with::
68+ Alternative (single-user install without a virtual environment)
69+ ---------------------------------------------------------------
5670
57- conda activate eoesc-env
71+ If you prefer not to create a virtual environment, you can install for the
72+ current user only (no system-wide changes)::
5873
59- and install the required packages::
74+ pip install --user pyqint
6075
61- conda install -c ifilot pyqint pytessel
76+ .. warning ::
77+ We **do not recommend ** using ``sudo pip install ... ``. Installing packages
78+ with administrative privileges can overwrite or conflict with system Python
79+ components and may break tools your operating system relies on.
6280
63- Finally, you can install the IDE Spyder using::
81+ Troubleshooting
82+ ---------------
6483
65- conda install spyder matplotlib scipy pandas openpyxl
84+ - If Conda reports conflicts during installation, it usually means the active
85+ environment has incompatible packages. Creating a fresh environment (as shown
86+ above) is the most reliable fix.
87+
88+ - If ``pip `` cannot find the package or fails due to permissions, ensure your
89+ virtual environment is activated, or use ``--user `` for a local user install.
90+
91+ - If Spyder does not see the environment, launch Spyder **from within ** the
92+ activated environment (``conda activate eoesc-env `` then ``spyder ``), or
93+ configure the interpreter path in Spyder’s preferences.
0 commit comments