In this step, we collect information about the different "cases" we need to
present in the book. The actual cases are outlined in text/specs.py
. This is
a largely declarative listing of the use cases.
Execution of this script produces the following files:
- The
text/results/Makefile
which defines how to build all simulations and their associated results. - A
json
encoded representation of each case intext/results/json/<CaseId>-case.json
. - A script to build and simulation each individual case in
text/results/<CaseId>.mos
. - A Python script to generate the plots for each case in
text/plots/<CaseId>.py
.
NB: The hash of the text/specs.py
file is stored in the file
text/spec-hash
and is used in the Makefile to determine if this step can be
skipped because the generated files out be identical to a previous run.
This step uses the OpenModelica compiler to build the following files for each case defined in step 1.
- An executable for each case in
text/results/<CaseId>
. - An "info" file generated by OpenModelica about each case in
text/results/<CaseId>_info.json
- An initialization file in
text/results/<CaseId>_init.xml
- A simulation result in
text/results/<CaseId>_res.mat
The executables and init files are stored in exes.tar.gz
(which is also used
by the simulation server API).
NB: The hash of the ModelicaByExample
directory combined with the hash of
the text/specs.py
file are stored in the file text/results-hash
and is used
in the text/Makefile
to determine if this step can be skipped because the
generated files out be identical to a previous run.
I'm using now
to do the site deployment. Much simpler than all that mucking
about with AWS S3, IAM, permissions, keys, etc.