Skip to content

Commit 063c56f

Browse files
committed
Merge branch 'develop' of https://github.com/stan-dev/cmdstanpy into develop
2 parents b5a11fd + 7245892 commit 063c56f

5 files changed

Lines changed: 20 additions & 204 deletions

File tree

.dockerignore

Lines changed: 0 additions & 3 deletions
This file was deleted.

Dockerfile

Lines changed: 0 additions & 21 deletions
This file was deleted.

Jenkinsfile

Lines changed: 0 additions & 163 deletions
This file was deleted.

cmdstanpy/utils.py

Lines changed: 4 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -161,12 +161,14 @@ def cmdstan_path() -> str:
161161
cmdstan_dir = os.path.expanduser(os.path.join('~', _DOT_CMDSTAN))
162162
if not os.path.exists(cmdstan_dir):
163163
raise ValueError(
164-
'No CmdStan installation found, run "install_cmdstan".'
164+
'No CmdStan installation found, run "install_cmdstan" or'
165+
' (re)activate your conda environment!'
165166
)
166167
latest_cmdstan = get_latest_cmdstan(cmdstan_dir)
167168
if latest_cmdstan is None:
168169
raise ValueError(
169-
'No CmdStan installation found, run "install_cmdstan".'
170+
'No CmdStan installation found, run "install_cmdstan" or'
171+
' (re)activate your conda environment!'
170172
)
171173
cmdstan = os.path.join(cmdstan_dir, latest_cmdstan)
172174
os.environ['CMDSTAN'] = cmdstan

docsrc/installation.rst

Lines changed: 16 additions & 15 deletions
Original file line numberDiff line numberDiff line change
@@ -2,16 +2,16 @@ Installation
22
============
33

44
CmdStanPy is a pure-Python3 package, but it relies on CmdStan for all
5-
of its functionality. There are several ways to install CmdStan and CmdStanPy,
6-
which depend on the kind of user you are.
5+
of its functionality. There are several ways to install CmdStan and CmdStanPy,
6+
which depend on the kind of user you are.
77

88

99
Conda users (Recommended)
1010
-------------------------
1111

12-
If you use `conda <https://docs.conda.io/en/latest/>`__,
12+
If you use `conda <https://docs.conda.io/en/latest/>`__,
1313
installation of both can be done very simply. CmdStanPy
14-
and CmdStan are both available via the
14+
and CmdStan are both available via the
1515
`conda-forge <https://conda-forge.org/>`__ repository.
1616

1717
We recommend creating a new environment for CmdStan[Py]:
@@ -20,7 +20,8 @@ We recommend creating a new environment for CmdStan[Py]:
2020
2121
conda create -n cmdstan -c conda-forge cmdstanpy
2222
23-
but installation is possible in an existing environment:
23+
but installation is possible in an existing environment
24+
(Note: you must re-activate the environment after running this command!):
2425

2526
.. code-block:: bash
2627
@@ -33,13 +34,13 @@ or whichever name you used for your environment (following ``-n``
3334
above).
3435

3536
Note that CmdStan is only available on conda for versions
36-
2.27.0 and newer. If you require an older version, you must use
37+
2.26.1 and newer. If you require an older version, you must use
3738
one of the following methods to install it. If you require a
38-
version of CmdStan *newer* than 2.27.0, but not the latest,
39+
version of CmdStan *newer* than 2.26.1", but not the latest,
3940
you can install it in the standard conda way by specifying
4041
``cmdstan==VERSION`` in the install command.
4142

42-
Pip (non-Conda) users
43+
Pip (non-Conda) users
4344
-------------------------
4445

4546
CmdStan can also be installed from PyPI via URL: https://pypi.org/project/cmdstanpy/ or from the
@@ -67,13 +68,13 @@ To install the current develop branch from GitHub:
6768
6869
6970
If you install CmdStanPy from GitHub,
70-
**you must install CmdStan**. The recommended way for Pip users
71-
to do so is via the ``install_cmdstan`` function
71+
**you must install CmdStan**. The recommended way for Pip users
72+
to do so is via the ``install_cmdstan`` function
7273
:ref:`described below<install-cmdstan-fun>`
7374

74-
.. note::
75+
.. note::
7576

76-
**Note for PyStan & RTools users:** PyStan and CmdStanPy should be installed in
77+
**Note for PyStan & RTools users:** PyStan and CmdStanPy should be installed in
7778
separate environments if you are using the RTools toolchain (primarily Windows users).
7879
If you already have PyStan installed, you should take care to install CmdStanPy in its own
7980
virtual environment.
@@ -88,7 +89,7 @@ to do so is via the ``install_cmdstan`` function
8889
`ipywidgets installation instructions <https://ipywidgets.readthedocs.io/en/latest/user_install.html#>`_
8990
and `this tqdm GitHub issue <https://github.com/tqdm/tqdm/issues/394#issuecomment-384743637>`_.
9091

91-
92+
9293

9394
Installing CmdStan
9495
------------------
@@ -146,7 +147,7 @@ can be used to override these defaults:
146147
install_cmdstan -d my_local_cmdstan -v 2.20.0
147148
ls -F my_local_cmdstan
148149
149-
DIY Installation
150+
DIY Installation
150151
^^^^^^^^^^^^^^^^
151152

152153
If you with to install CmdStan yourself, follow the instructions
@@ -191,4 +192,4 @@ To use custom ``make``-tool use ``set_make_env`` function.
191192

192193
.. [1] In very early versions, this hidden directory was named ``.cmdstanpy``
193194
194-
195+

0 commit comments

Comments
 (0)