File tree Expand file tree Collapse file tree
Expand file tree Collapse file tree Original file line number Diff line number Diff line change @@ -50,6 +50,7 @@ def _cleanup_tmpdir() -> None:
5050from .utils import set_cmdstan_path # noqa
5151from .utils import (
5252 cmdstan_path ,
53+ cmdstan_version ,
5354 install_cmdstan ,
5455 set_make_env ,
5556 show_versions ,
@@ -71,4 +72,5 @@ def _cleanup_tmpdir() -> None:
7172 'write_stan_json' ,
7273 'show_versions' ,
7374 'rebuild_cmdstan' ,
75+ 'cmdstan_version' ,
7476]
Original file line number Diff line number Diff line change 2424from typing import Any , Dict , List
2525
2626from cmdstanpy import _DOT_CMDSTAN
27- from cmdstanpy .utils import (
28- pushd ,
29- validate_dir ,
30- wrap_url_progress_hook ,
31- )
27+ from cmdstanpy .utils import pushd , validate_dir , wrap_url_progress_hook
3228
3329EXTENSION = '.exe' if platform .system () == 'Windows' else ''
3430IS_64BITS = sys .maxsize > 2 ** 32
Original file line number Diff line number Diff line change @@ -1163,6 +1163,7 @@ def show_versions(output: bool = True) -> str:
11631163
11641164 try :
11651165 deps_info .append (('cmdstan_folder' , cmdstan_path ()))
1166+ deps_info .append (('cmdstan' , str (cmdstan_version ())))
11661167 # pylint: disable=broad-except
11671168 except Exception :
11681169 deps_info .append (('cmdstan' , 'NOT FOUND' ))
Original file line number Diff line number Diff line change 44API Reference
55#############
66
7+ The following documents the public API of CmdStanPy. It is expected to be stable between versions,
8+ with backwards compatibility between minor versions and deprecation warnings preceeding breaking changes.
9+ There is also the `internal API <internal_api.rst >`__, which is makes no such guarantees.
10+
11+ .. toctree ::
12+ :hidden:
13+
14+ internal_api.rst
15+
716*******
817Classes
918*******
@@ -54,22 +63,15 @@ CmdStanVB
5463 :members:
5564
5665
57- InferenceMetadata
58- =================
59-
60- .. autoclass :: cmdstanpy.InferenceMetadata
61- :members:
62-
63- RunSet
64- ======
65-
66- .. autoclass :: cmdstanpy.stanfit.RunSet
67- :members:
68-
6966*********
7067Functions
7168*********
7269
70+ show_versions
71+ =============
72+
73+ .. autofunction :: cmdstanpy.show_versions
74+
7375cmdstan_path
7476============
7577
@@ -85,6 +87,11 @@ set_cmdstan_path
8587
8688.. autofunction :: cmdstanpy.set_cmdstan_path
8789
90+ cmdstan_version
91+ ================
92+
93+ .. autofunction :: cmdstanpy.cmdstan_version
94+
8895set_make_env
8996============
9097
Original file line number Diff line number Diff line change 1313# serve to show the default.
1414
1515import os
16- import sys
1716import subprocess
17+ import sys
1818
1919# debug info
2020print ("python exec:" , sys .executable )
Original file line number Diff line number Diff line change @@ -3,7 +3,7 @@ channels:
33 - conda-forge
44 - nodefaults
55dependencies :
6- - python=3.7
6+ - python=3.9
77 - ipykernel
88 - ipython
99 - ipywidgets
Original file line number Diff line number Diff line change 1+ .. py :currentmodule :: cmdstanpy
2+
3+ ######################
4+ Internal API Reference
5+ ######################
6+
7+ The following documents the internal API of CmdStanPy. No guarantees are made about backwards compatibility between
8+ minor versions and refactors are expected. If you find yourself needing something exposed here, please
9+ `open an issue <https://github.com/stan-dev/cmdstanpy/issues >`__ requesting it be added to the `public API <api.rst >`__.
10+
11+ *******
12+ Classes
13+ *******
14+
15+ InferenceMetadata
16+ =================
17+
18+ .. autoclass :: cmdstanpy.InferenceMetadata
19+ :members:
20+
21+ RunSet
22+ ======
23+
24+ .. autoclass :: cmdstanpy.stanfit.RunSet
25+ :members:
26+
27+ CompilerOptions
28+ ===============
29+
30+ .. autoclass :: cmdstanpy.compiler_opts.CompilerOptions
31+ :members:
32+
33+ CmdStanArgs
34+ ===========
35+
36+ .. autoclass :: cmdstanpy.cmdstan_args.CmdStanArgs
37+ :members:
38+
39+ SamplerArgs
40+ ===========
41+
42+ .. autoclass :: cmdstanpy.cmdstan_args.SamplerArgs
43+ :members:
44+
45+ OptimizeArgs
46+ ============
47+
48+ .. autoclass :: cmdstanpy.cmdstan_args.OptimizeArgs
49+ :members:
50+
51+ VariationalArgs
52+ ===============
53+
54+ .. autoclass :: cmdstanpy.cmdstan_args.VariationalArgs
55+ :members:
56+
Original file line number Diff line number Diff line change 88from cmdstanpy .stanfit import RunSet
99from cmdstanpy .utils import EXTENSION
1010
11-
1211HERE = os .path .dirname (os .path .abspath (__file__ ))
1312DATAFILES_PATH = os .path .join (HERE , 'data' )
1413
You can’t perform that action at this time.
0 commit comments