Skip to content

Commit fa99ff3

Browse files
committed
updating docs
1 parent f4dd9b8 commit fa99ff3

1 file changed

Lines changed: 15 additions & 16 deletions

File tree

docsrc/workflow.rst

Lines changed: 15 additions & 16 deletions
Original file line numberDiff line numberDiff line change
@@ -39,18 +39,21 @@ managing the resulting inference for a single model and set of inputs.
3939
Compile the Stan model
4040
^^^^^^^^^^^^^^^^^^^^^^
4141

42-
The: :class:`CmdStanModel` class manages the Stan program and its corresponding compiled executable and
43-
provides properties and functions to inspect the model code and filepaths.
44-
45-
A model object can be instantiated by specifying either the Stan program file path
46-
or the compiled executable file path or both.
47-
If only the Stan program file is specified, by default,
48-
CmdStanPy will try to compile the model.
49-
If both the model and executable file are specified,
50-
the constructor will compare the filesystem timestamps and
51-
will only compile the program if the Stan file has a later timestamp which
52-
indicates that the program may have been edited.
53-
The constructor argument ``compile=False`` will override the default behavoir.
42+
The: :class:`CmdStanModel` class provides methods
43+
to compile and run the Stan program.
44+
A CmdStanModel object can be instantiated by specifying
45+
either a Stan file or the executable file.
46+
47+
By default, when a CmdStanModel object is instantiated from a Stan file,
48+
CmdStanPy will automatically compile the model if:
49+
50+
- CmdStanPy cannot find a corresponding executable file in the same directory, or
51+
- The timestamp on the executable is older than the Stan file.
52+
53+
The argument `compile` controls this behavoir.
54+
When ``False`` the model object doesn't try to compile the Stan file.
55+
When ``True`` the model compiles the Stan file only if the timestamp is older than the Stan file.
56+
When ``Force`` the model always compiles or recompiles the mode.
5457

5558
.. code-block:: python
5659
@@ -64,10 +67,6 @@ The constructor argument ``compile=False`` will override the default behavoir.
6467
my_model.exe_file
6568
my_model.code()
6669
67-
The method :meth:`~CmdStanModel.compile` is used to compile the model as needed.
68-
When the argument ``force=True`` is present, CmdStanPy will always compile the model,
69-
even if the existing executable file is newer than the Stan program file.
70-
7170
Model compilation is carried out via the GNU Make build tool.
7271
The CmdStan ``makefile`` contains a set of general rules which
7372
specify the dependencies between the Stan program and the

0 commit comments

Comments
 (0)