Skip to content

Commit 1700c46

Browse files
committed
content/installation: misc revisions
1 parent b976e57 commit 1700c46

File tree

1 file changed

+51
-30
lines changed

1 file changed

+51
-30
lines changed

content/installation.rst

Lines changed: 51 additions & 30 deletions
Original file line numberDiff line numberDiff line change
@@ -29,6 +29,8 @@ the command line for some lessons).
2929
*harder than it should be* and it helps to have someone guide you
3030
through it.
3131

32+
.. highlight:: console
33+
3234

3335

3436
Python
@@ -90,13 +92,16 @@ channel.**
9092
but can feel unfamiliar. See the `command line crash course
9193
<https://scicomp.aalto.fi/scicomp/shell/>`__ for an intro.
9294

93-
Linux/MacOS: Each time you start a new shell, you can activate
94-
Miniforge by running ``source ~/miniforge3/bin/activate``. This
95-
is not needed if you choose "Do you wish to update your shell
96-
profile to automatically initialize conda?".
95+
Linux/MacOS: Each time you start a new command line terminal,
96+
you can activate Miniforge by running::
97+
98+
$ source ~/miniforge3/bin/activate
99+
$ # This is not needed if you choose yes for "Do you wish
100+
$ # to update your shell profile to automatically initialize
101+
$ # conda?" during installation.
97102

98103
Windows: Use the "Miniforge Prompt" to start Miniforge. This
99-
will set up all the paths so that ``conda`` and ``mamba`` are
104+
will set up everything so that ``conda`` and ``mamba`` are
100105
available.
101106

102107
.. group-tab:: Anaconda
@@ -114,10 +119,10 @@ channel.**
114119

115120
.. group-tab:: Other options
116121

117-
Any other Python distribution which you can install libraries into
118-
would work, but because there are so many different ways to do this,
119-
we don't support them. You would need the extra libraries mentioned
120-
in the Miniforge instructions.
122+
There are many ways to install Python. Other methods can work,
123+
as long as you can install the libraries from the
124+
``environment.yml`` file mentioned in the Miniforge
125+
instructions.
121126

122127
We don't currently provide a ``requirements.txt`` for installing
123128
the required packages without Conda/Mamba, though.
@@ -130,18 +135,24 @@ Python for SciComp software environment
130135

131136
.. group-tab:: Miniforge
132137

133-
This `this environment file
138+
This `environment file
134139
<https://raw.githubusercontent.com/AaltoSciComp/python-for-scicomp/master/software/environment.yml>`__
135-
contains all packages needed, and can be installed with:
136-
137-
.. code:: console
140+
contains all packages needed for the course, and can be installed with::
138141

139142
$ mamba env create -f https://raw.githubusercontent.com/AaltoSciComp/python-for-scicomp/master/software/environment.yml
140143

141144
Each time you start a new command line, you need to activate
142-
miniforge (if you don't do run the ``conda init`` option), and
143-
then you need to activate the proper environment with ``conda
144-
activate python-for-scicomp``.
145+
miniforge and this environment.
146+
147+
Linux/MacOX::
148+
149+
$ source ~/miniforge3/bin/activate
150+
$ conda activate python-for-scicomp
151+
152+
Windows::
153+
154+
$ # Start the Miniforge Prompt.
155+
$ conda activate python-for-scicomp
145156

146157
.. group-tab:: Anaconda
147158

@@ -153,6 +164,9 @@ Python for SciComp software environment
153164
You'll have to download it and then `import it
154165
<https://docs.anaconda.com/navigator/tutorials/manage-environments/#importing-an-environment>`__.
155166

167+
When running this course's exercise, make sure the
168+
``python-for-scicomp`` environment is activated before starting
169+
Jupyter or any code.
156170

157171
.. group-tab:: Other options
158172

@@ -161,7 +175,9 @@ Python for SciComp software environment
161175

162176
Virtual environments: we don't currently provide a
163177
``requirements.txt`` but many package names can probably be
164-
copied from the ``environment.yml`` file.
178+
copied from the ``environment.yml`` file. We really recommend
179+
conda/mamba based systems: it's designed for complex scientific
180+
software.
165181

166182
Any other Python distribution which you can install libraries into
167183
would work, but because there are so many different ways to do this,
@@ -170,7 +186,6 @@ Python for SciComp software environment
170186

171187

172188

173-
174189
JupyterLab
175190
~~~~~~~~~~
176191

@@ -181,20 +196,30 @@ most of the other tools we need).
181196

182197
.. group-tab:: Miniforge
183198

184-
First, start the Miniforge command line interface.
199+
JupyterLab was instaled in the previous step. To run it, first,
200+
start the Miniforge command line interface.
201+
202+
Linux/MacOS: remember, you may need to activate Miniforge and
203+
the environment first::
185204

186-
Linux/MacOS: remember, you may need to activate it by running
187-
``source ~/miniforge3/bin/activate`` if you didn't update your
188-
shell profile to automatically initialize conda.
205+
$ source ~/miniforge3/bin/activate
206+
$ conda activate python-for-scicomp
207+
$ jupyter-lab
208+
209+
Windows::
210+
211+
$ # Start the Miniforge Prompt.
212+
$ conda activate python-for-scicomp
213+
$ jupyter-lab
189214

190215
.. group-tab:: Anaconda
191216

192217
If you install the full Anaconda distribution, this will be
193218
available and can be started either through Anaconda Navigator
194219
or command line.
195220

196-
Make sure the CodeRefinery environment is selected and you can
197-
start JupyterLab.
221+
Make sure the ``python-for-scicomp`` environment is selected and
222+
you can start JupyterLab.
198223

199224

200225

@@ -212,9 +237,7 @@ Verification of Python and JupyterLab
212237

213238
.. group-tab:: Miniforge
214239

215-
You can start JupyterLab from the command line:
216-
217-
.. code-block:: console
240+
You can start JupyterLab from the command line::
218241

219242
$ jupyter-lab
220243
(... Jupyter starts in a web browser)
@@ -230,9 +253,7 @@ Verification of Python and JupyterLab
230253

231254
Starting JupyterLab from the Anaconda Navigator.
232255

233-
... or you can start JupyterLab from the command line:
234-
235-
.. code-block:: console
256+
... or you can start JupyterLab from the command line::
236257

237258
$ jupyter-lab
238259
(... Jupyter starts in a web browser)

0 commit comments

Comments
 (0)