Commit graph

6102 commits

Author SHA1 Message Date
Alexandre Duret-Lutz
5dfa039a48 * doc/org/compile.org: Fix instructions to uses -std=c++17. 2021-11-16 09:56:37 +01:00
Alexandre Duret-Lutz
a5f080338c Python 3.5 is now needed
* NEWS, README, HACKING, doc/org/install.org, m4/pypath.m4: Adjust.
2021-11-16 09:51:59 +01:00
Alexandre Duret-Lutz
bc063b13f3 * spot/bricks/brick-hash: Add missing include. 2021-11-16 09:47:42 +01:00
Alexandre Duret-Lutz
186d206302 ltsmin-pml: work around newer jupyter versions
Newer Jupyter version are able to capture the system's stdout and
stderr to display it in the notebook.  This is done asynchronously,
with a thread polling those file descriptor.  While this will help us
debug (finaly we can see the tracing code we put in C++) this causes
two issues for testing.  One is the asynchronous behaviour, which
makes it very hard to reproduce notebooks.  The second issue is that
older version of Jupyter used to hide some of the prints from the
notebook, so it is hard to accommodate both.

In the case of the ltsmin-pml notebook, loading the PML file from
a filename used to trigger a compilation silently (with output on the
console, but not in the notebook).  The newer version had the output
of that compilation spread into two cells.

* python/spot/ltsmin.i: Work around the issue by triggering the
compilation from Python, and capturing its output explicitly, so it
work with all Jupyter versions.  Also adjust to use the more recent
and simpler subprocess.run() interface, available since Python 3.5.
* tests/python/ltsmin-pml.ipynb: Adjust expected output.
* tests/python/ipnbdoctest.py (canonicalize): Adjust patterns.
2021-11-15 23:37:08 +01:00
Alexandre Duret-Lutz
aeb05f0ff0 * doc/org/index.org: Fix link to zlktree.html. 2021-11-14 22:17:15 +01:00
Alexandre Duret-Lutz
dd8373e788 * NEWS, configure.ac: Bump version to 2.10.0.dev. 2021-11-13 21:43:57 +01:00
Alexandre Duret-Lutz
37de3470b8 Release Spot 2.10
* NEWS, configure.ac, doc/org/setup.org: Bump version.
2021-11-13 21:43:57 +01:00
Alexandre Duret-Lutz
0706887e62 * doc/Makefile.am (svgo): preserve the IDs in oaut-dot4.svg. 2021-11-13 21:43:57 +01:00
Alexandre Duret-Lutz
8d91aa4267 * doc/org/index.org: Advertise more features. 2021-11-13 11:08:12 +01:00
Alexandre Duret-Lutz
9d81e9cf8f * tests/python/split.py: Simplify. 2021-11-12 22:44:56 +01:00
Alexandre Duret-Lutz
1443d45ac7 synthesis: minor typos
* spot/twaalgos/game.cc, spot/twaalgos/mealy_machine.cc,
spot/twaalgos/synthesis.cc, spot/twaalgos/synthesis.hh: Here.
2021-11-12 22:44:08 +01:00
Alexandre Duret-Lutz
6555af1f44 python: fix support for std::vector<const_twa_graph_ptr>
* spot/twaalgos/aiger.hh, spot/twaalgos/aiger.cc: Fix prototypes, as
well as several error messages.
* python/spot/impl.i: Implement an ad-hoc conversion for
std::vector<const_twa_graph_ptr>.
* tests/python/synthesis.ipynb: Use it to simplify the example.
Adjust some comments.
2021-11-12 22:38:37 +01:00
philipp
98ebbea17e Renaming and clean up
"Strategy" was used for mealy machines and game strategies a like.
Introduced the notion of mealy machine in three different flavors:
mealy machine: twa_graph with synthesis-outputs
separated mealy machine: mealy machine and all transitions
have conditions of the form (bdd over inputs)&(bdd over outputs)
split mealy machine: mealy machine that alternates between
env and player states. Needs state-players

* bin/ltlsynt.cc: renaming
* python/spot/impl.i: Add vector for const_twa_graph_ptr
* spot/twaalgos/aiger.cc,
spot/twaalgos/aiger.hh: Adapting functions
* spot/twaalgos/mealy_machine.cc,
spot/twaalgos/mealy_machine.hh: Add test functions and
propagate properties correctly. Adjust for names
* spot/twaalgos/synthesis.cc,
spot/twaalgos/synthesis.hh: Removing unnecessary functions
and adapt to new names
* tests/python/aiger.py,
tests/python/_mealy.ipynb,
tests/python/mealy.py,
tests/python/synthesis.ipynb: Adjust
2021-11-11 00:38:14 +01:00
philipp
6ebe3d7447 Use generic split after obtaining direct strategy
* bin/ltlsynt.cc: Here
2021-11-11 00:38:14 +01:00
Alexandre Duret-Lutz
75b89db5ac zlktree: fix colored output of acd_transform_sbacc()
* spot/twaalgos/zlktree.cc (acd_transform_sbacc): Fix the
acceptance condition when colored is true.
* tests/python/zlktree.py: Add test case.
2021-11-10 15:51:13 +01:00
Alexandre Duret-Lutz
2f528c7190 * tests/python/streett_totgba.py: Remove superfluous comment. 2021-11-10 15:28:08 +01:00
Florian Renkin
d4967f20e9 Notebooks: correct typos
* tests/python/acc_cond.ipynb, tests/python/contains.ipynb,
tests/python/decompose.ipynb, tests/python/games.ipynb,
tests/python/randltl.ipynb, tests/python/synthesis.ipynb,
tests/python/testingaut.ipynb: here.
2021-11-06 11:56:05 +01:00
Alexandre Duret-Lutz
c72c285552 * doc/spot.bib: Add entries for multi-core emptiness-checks. 2021-11-05 17:06:20 +01:00
Alexandre Duret-Lutz
3c5928d216 tl: fix AST rendering of Star/FStar nodes
* spot/tl/dot.cc: Show the min/max argument for Star/FStar nodes.
* tests/python/formulas.ipynb: Adjust test.
2021-11-05 12:17:32 +01:00
Alexandre Duret-Lutz
9097eca81d * spot/twaalgos/ltl2tgba_fm.cc: Update some comments. 2021-11-05 12:17:32 +01:00
philipp
540b31dbd7 [buddy] Improve bdd_have_common_assignment
* src/bddop.c: Improve here
* src/bddtest.cxx: Tests here
2021-11-05 09:23:57 +01:00
philipp
c5a61da22b [buddy] Fix is_cube() and add tests
* src/bddop.c: Fix is_cube with bddtrue as input
* src/bddtest.cxx: Add tests here
2021-11-05 09:23:57 +01:00
Alexandre Duret-Lutz
ece7631e8c [buddy] fix a spurious failure
* examples/bddtest/bddtest.cxx: reset some global BDDs to avoid
issues when they are destroyed after BuDDy.
2021-11-04 23:19:31 +01:00
Alexandre Duret-Lutz
7ade97943b * NEWS: Some cleanup, in preparation for the release. 2021-11-04 17:37:20 +01:00
Alexandre Duret-Lutz
5a9c8aad0d [buddy] execute some of the tests during "make check"
* examples/bddtest/Makefile.am, src/Makefile.am (TESTS):
Add this variable.
* examples/bddtest/bddtest.cxx: Return non-zero on error.
2021-11-04 15:24:10 +01:00
Alexandre Duret-Lutz
f99ddef787 bin: use regexes to detect shorthands, and add support for owl-21.0
Fixes #480.

* bin/common_trans.cc (shorthands_ltl, shorthands_autproc): Write
those lists using regexes.  Add entries for Owl 21.0.
(show_shorthands, tool_spec): Adjust to use those regexes.
* doc/org/autcross.org, doc/org/ltlcross.org, doc/org/ltldo.org:
Update the list of shorthands.
* tests/core/ltldo.test: Add a couple of tests.
* NEWS: Mention this new feature.
2021-11-04 15:24:10 +01:00
Florian Renkin
97046ea263 Synthesis decomposition: Add a new rewriting and tests
* spot/twaalgos/synthesis.cc: add a new rewriting rule
* tests/core/ltlsynt.test: test rewritings
2021-11-04 15:10:07 +01:00
Florian Renkin
7947ffc930 ltlsynt: correct verbose when --aiger is used
* bin/ltlsynt.cc: here
* tests/core/ltlsynt.test: add test
2021-11-04 10:20:48 +01:00
Alexandre Duret-Lutz
553381bd6e aiger: improve parse errors and test them
* spot/twaalgos/aiger.cc, spot/twaalgos/aiger.hh (parse_aag_impl_): Do
not display source filename in user facing errors.  Use GNU-style
"file:line: " prefixes for locations.  Adjust all sscanf() calls
to check for ignored trailing data.  Add some missing checks about the
order of input and output names, checks that output names do no
intersect input names.  Fix incorrect line number for unexpected
input variable number, and avoid using std::stoi as that throws
an std::invalid_argument on parse error.
* tests/python/aiger.py: Add test cases for each error message.
2021-11-03 23:13:28 +01:00
Florian Renkin
aff04c2207 Aiger parser: correct input and output names
* spot/twaalgos/aiger.cc: here.
* tests/python/aiger.py: add tests
* tests/python/synthesis.ipynb: correct notebook
2021-11-03 13:10:27 +01:00
Florian Renkin
8aa9da7fc8 Synthesis: rewrite bypass
* spot/twaalgos/synthesis.cc: here
* spot/twaalgos/synthesis.hh: introduce a realizability_code
* bin/ltlsynt.cc, spot/twaalgos/aiger.cc: use this enum
* tests/core/ltlsynt.test: update tests
2021-11-02 10:22:40 +01:00
Alexandre Duret-Lutz
3be79ea476 print_dot: improve aiger rendering
* spot/twaalgos/dot.cc: Improve the aiger printer by using a more
traditional dot syntax, indenting the output, adding some hard-coded
colors, fixing a bug in the negation of latch inputs, and rotating the
triangles for horizontal output.
* tests/python/synthesis.ipynb: Adjust expected output, and add
an example of horizontal layout.
2021-10-29 23:21:54 +02:00
Alexandre Duret-Lutz
753d572e4d print_dot: improve the rendering of Mealy machines
* spot/twaalgos/dot.cc (print_dot): Add some detection of Mealy
machines, and some code to render its I/O in a <table>.
* tests/python/synthesis.ipynb: Adjust expected output.
* tests/python/_mealy.ipynb: New file.
* tests/Makefile.am: Add python/_mealy.ipynb.
* NEWS: Mention the new feature.
2021-10-29 16:45:35 +02:00
Alexandre Duret-Lutz
09b361712d python: make sure swig also work with --disable-dependency-tracking
Fixes #482, reported by Antoine Martin.

* python/Makefile.am: Do not pass -MF to Swig when AMDEP is false.
2021-10-29 11:41:09 +02:00
Alexandre Duret-Lutz
6464324a2c ltlsynt: fix a bug in split_2step_fast_here
* spot/twaalgos/synthesis.cc (split_2step_fast_here::get_ps): Fix the
state number recorded in the map.
* tests/core/ltlsynt.test: Add test case.
2021-10-24 22:34:06 +02:00
Alexandre Duret-Lutz
1df5f0e2c7 synthesis: simplify split_2step_fast_here
* spot/twaalgos/synthesis.cc (split_2step_fast_here): Do not use
a temporary vector to iterate over the original edges.
2021-10-23 01:23:24 +02:00
Alexandre Duret-Lutz
074678416f ltlsynt: improve error message in case of missing --ins and --outs
* bin/ltlsynt.cc: Here.
* tests/core/ltlsynt.test: Test the error.
2021-10-22 17:46:21 +02:00
Alexandre Duret-Lutz
c43712682f synthesis: rename create_game() to ltl_to_game()
* bin/ltlsynt.cc, spot/twaalgos/aiger.hh, spot/twaalgos/synthesis.cc,
spot/twaalgos/synthesis.hh, tests/python/synthesis.ipynb,
tests/python/synthesis.py: Here.
2021-10-18 09:17:40 +02:00
Alexandre Duret-Lutz
5fd4d94031 ltlsynt: replace some leftover throw by error()
* bin/ltlsynt.cc (solve_formula): Report errors with error().
2021-10-11 13:39:52 +02:00
Alexandre Duret-Lutz
1eb18f4b83 ltlsynt: fix --help output for common Input options
* bin/common_finput.cc (argp): Declare all options in section 1.
2021-10-11 13:39:52 +02:00
Alexandre Duret-Lutz
82d4fc8ed9 ltlsynt: report AP missing from --ins and --outs
* bin/ltlsynt.cc (process_formula): Add a check.
* tests/core/ltlsynt.test: Add test case.
2021-10-09 21:18:21 +02:00
Alexandre Duret-Lutz
0e5f2d4819 ltlsynt: --ins is optional but not its argument
Fixes #481, reported by Michaël Cadilhac.

* bin/ltlsynt.cc (argp_option): Remove erroneous OPTION_ARG_OPTIONAL.
* tests/core/ltlsynt.test: Add test case.
2021-10-09 20:50:38 +02:00
Alexandre Duret-Lutz
b9a39c5576 aiger: fix forcing of input properties
* spot/twaalgos/aiger.cc: Here.
* tests/python/synthesis.ipynb: Adjust.
2021-10-07 14:08:29 +02:00
Alexandre Duret-Lutz
9b3956f892 zlktree: fix handling of automata with false acceptance
Reported by Florian.

* spot/twaalgos/zlktree.cc (zielonka_tree_transform, acd_transform):
Here.
* tests/python/zlktree.py: Add test cases.
2021-10-07 11:11:49 +02:00
Alexandre Duret-Lutz
0ec1ee6de3 move parts of games.ipynb into synthesis.ipynb
* tests/python/synthesis.ipynb: New file, with bits removed from...
* tests/python/games.ipynb: ... here.
* tests/Makefile.am: Add synthesis.ipynb.
* NEWS, doc/org/tut.org: Mention the new notebook.
2021-10-07 10:48:02 +02:00
Alexandre Duret-Lutz
7bc2c31043 game: teach solve_game to use solve_safety_game
* spot/twaalgos/game.cc, spot/twaalgos/game.hh: Here.
* doc/org/tut40.org: Adjust example.
2021-10-07 09:25:01 +02:00
Alexandre Duret-Lutz
bdd20bd1a1 rename game_info to synthesis_info; move it with the synthesis code
* spot/twaalgos/game.cc, spot/twaalgos/game.hh (game_info): Move...
* spot/twaalgos/synthesis.cc,
spot/twaalgos/synthesis.hh (synthesis_info): ... here, because this
structure contains only synthesis stuff.  Also rename "solver" to
"algo" to match the ltlsynt option.
(solve_game): Move the two argument version of this function here,
since that's the only game-related generic function that use
synthesis_info.
* bin/ltlsynt.cc, tests/core/ltlsynt.test, tests/python/games.ipynb,
tests/python/synthesis.py, NEWS: Adjust all uses and mentions.
2021-10-07 09:06:15 +02:00
Alexandre Duret-Lutz
0ac5bbc05d ltlsynt: replace -x minimization-lvl=N by --simplify
* bin/ltlsynt.cc: Implement the new option, and make it default
to bisimulation with output assignment (a.k.a. bwoa).
* NEWS, bin/spot-x.cc, doc/org/ltlsynt.org: Update the documentation.
* spot/twaalgos/game.hh: Make bwoa the default.
* tests/core/ltlsynt.test: Add and adjust test cases.
* tests/python/games.ipynb: Adjust.
2021-10-06 18:00:24 +02:00
Alexandre Duret-Lutz
af5474d791 ltlsynt: replace -x specification-decomposition by --decompose
* bin/ltlsynt.cc: Implement the option, and enable it by default.
* doc/org/ltlsynt.org, doc/org/ltlsynt.tex, bin/spot-x.cc, NEWS:
Document it.
* tests/core/ltlsynt.test: Adjust test cases.
2021-10-06 10:51:42 +02:00
Alexandre Duret-Lutz
5d722ca584 * doc/org/tut.org: Fix a title. 2021-10-06 10:46:22 +02:00