Showing
5 changed files
with
136 additions
and
133 deletions
MANIFEST
0 → 100644
1 | +# file GENERATED by distutils, do NOT edit | ||
2 | +,let.png | ||
3 | +,let.py | ||
4 | +,net-with-colors.png | ||
5 | +,railroad.png | ||
6 | +,railroad.pnml | ||
7 | +,test-gv-circo.png | ||
8 | +,test-gv-dot.png | ||
9 | +,test-gv-fdp.png | ||
10 | +,test-gv-graph.png | ||
11 | +,test-gv-neato.png | ||
12 | +,test-gv-twopi.png | ||
13 | +.hgignore | ||
14 | +.hgtags | ||
15 | +BUGS | ||
16 | +MANIFEST.in | ||
17 | +Makefile | ||
18 | +NEWS | ||
19 | +README | ||
20 | +TODO | ||
21 | +VERSION | ||
22 | +dput.sh | ||
23 | +mkdeb.py | ||
24 | +mklang.py | ||
25 | +setup.py | ||
26 | +test.py | ||
27 | +bin/abcd | ||
28 | +bin/snkc | ||
29 | +bin/snkd | ||
30 | +doc/COPYING | ||
31 | +doc/abcd.txt | ||
32 | +doc/queries.txt | ||
33 | +doc/simple-coloured.pnml | ||
34 | +doc/simple-pt.pnml | ||
35 | +doc/snakes-pnml.txt | ||
36 | +doc/tutorial.png | ||
37 | +doc/tutorial.txt | ||
38 | +doc/examples/abcd/README | ||
39 | +doc/examples/abcd/philo.abcd | ||
40 | +doc/examples/abcd/prod-cons.abcd | ||
41 | +doc/examples/abcd/railroad.abcd | ||
42 | +doc/examples/abcd/railroad.py | ||
43 | +doc/examples/abcd/ns/dolev_yao.py | ||
44 | +doc/examples/abcd/ns/ns.abcd | ||
45 | +doc/examples/abcd/ns/ns.py | ||
46 | +snakes/__init__.py | ||
47 | +snakes/compat.py | ||
48 | +snakes/data.py | ||
49 | +snakes/hashables.py | ||
50 | +snakes/nets.py | ||
51 | +snakes/pnml.py | ||
52 | +snakes/typing.py | ||
53 | +snakes/lang/__init__.py | ||
54 | +snakes/lang/asdl.py | ||
55 | +snakes/lang/astjy25.py | ||
56 | +snakes/lang/astpy25.py | ||
57 | +snakes/lang/astpypy.py | ||
58 | +snakes/lang/pgen.py | ||
59 | +snakes/lang/unparse.py | ||
60 | +snakes/lang/abcd/__init__.py | ||
61 | +snakes/lang/abcd/asdl.py | ||
62 | +snakes/lang/abcd/parser.py | ||
63 | +snakes/lang/abcd/pgen.py | ||
64 | +snakes/lang/ctlstar/__init__.py | ||
65 | +snakes/lang/ctlstar/asdl.py | ||
66 | +snakes/lang/ctlstar/parser.py | ||
67 | +snakes/lang/ctlstar/pgen.py | ||
68 | +snakes/lang/pylib/__init__.py | ||
69 | +snakes/lang/pylib/asdl.py | ||
70 | +snakes/lang/pylib/spark.py | ||
71 | +snakes/lang/pylib/unparse.py | ||
72 | +snakes/lang/python/__init__.py | ||
73 | +snakes/lang/python/asdl.py | ||
74 | +snakes/lang/python/parser.py | ||
75 | +snakes/lang/python/pgen.py | ||
76 | +snakes/plugins/__init__.py | ||
77 | +snakes/plugins/clusters.py | ||
78 | +snakes/plugins/gv.py | ||
79 | +snakes/plugins/hello.py | ||
80 | +snakes/plugins/labels.py | ||
81 | +snakes/plugins/let.py | ||
82 | +snakes/plugins/modules.py | ||
83 | +snakes/plugins/ops.py | ||
84 | +snakes/plugins/pids.py | ||
85 | +snakes/plugins/pos.py | ||
86 | +snakes/plugins/query.py | ||
87 | +snakes/plugins/status.py | ||
88 | +snakes/plugins/synchro.py | ||
89 | +snakes/utils/__init__.py | ||
90 | +snakes/utils/apidoc.py | ||
91 | +snakes/utils/abcd/__init__.py | ||
92 | +snakes/utils/abcd/build.py | ||
93 | +snakes/utils/abcd/checker.py | ||
94 | +snakes/utils/abcd/main.py | ||
95 | +snakes/utils/abcd/simul.py | ||
96 | +snakes/utils/abcd/transform.py | ||
97 | +snakes/utils/ctlstar/__init__.py | ||
98 | +snakes/utils/ctlstar/build.py | ||
99 | +utils/abcd-mode.el |
1 | SNAKES is the Net Algebra Kit for Editors and Simulators | 1 | SNAKES is the Net Algebra Kit for Editors and Simulators |
2 | ======================================================== | 2 | ======================================================== |
3 | 3 | ||
4 | -//////////////////////////////////////////////////////////////// | 4 | +SNAKES is a Python library that provides all the necessary to define |
5 | -This file is formatted in order to be processed by AsciiDoc | 5 | +and execute many sorts of Petri nets, in particular algebras of Petri |
6 | -(http://www.methods.co.nz/asciidoc). It will be more comfortable | 6 | +nets. SNAKES' main aim is to be a general Petri net library, being |
7 | -to render it or to read the HTML version available at: | 7 | +able to cope with most Petri nets models, and providing the researcher |
8 | -http://www.univ-paris12.fr/pommereau/soft/snakes/index.html | 8 | +with a tool to quickly prototype new ideas. |
9 | -//////////////////////////////////////////////////////////////// | ||
10 | - | ||
11 | -SNAKES is a Python library that provides all then necessary to define | ||
12 | -and execute many sorts of Petri nets, in particular those of the PBC | ||
13 | -and M-nets family. Its main aim is to be a general Petri net library, | ||
14 | -being able to cope with most Petri nets models, and providing the | ||
15 | -researcher with a tool to quickly prototype its new ideas. SNAKES | ||
16 | -should be suitable to provide the data model for editors or | ||
17 | -simulators; actually, any editor that use SNAKES may also be a | ||
18 | -simulator as SNAKES can execute any net. | ||
19 | 9 | ||
20 | A key feature of SNAKES is the ability to use arbitrary Python objects | 10 | A key feature of SNAKES is the ability to use arbitrary Python objects |
21 | as tokens and arbitrary Python expressions in many points, for | 11 | as tokens and arbitrary Python expressions in many points, for |
22 | instance in transitions guards or arcs outgoing of transitions. This | 12 | instance in transitions guards or arcs outgoing of transitions. This |
23 | -is what makes SNAKES that general. This relies on the capability of | 13 | +provides out of the box a great flexibility. |
24 | -Python to run dynamically provided Python code (the $eval$ function). | ||
25 | -This feature may not be efficient enough for model-checking: speed is | ||
26 | -the price to pay for the wide generality. However, in the case of a | ||
27 | -new model, SNAKES may happen to be the only available tool. | ||
28 | 14 | ||
29 | Another important feature of SNAKES is the plugin system that allows | 15 | Another important feature of SNAKES is the plugin system that allows |
30 | -to extend the features and work with specialised classes of Petri | 16 | +to extend the features, for instance to work with specialised classes |
31 | -nets. Currently, the following plugins are provided: | 17 | +of Petri nets (e.g., plugins are provided to draw nets, or to compose |
32 | - | 18 | +them using the various control-flows operations). Plugins are another |
33 | -pos:: adds to nodes the capability of holding their position. Nodes | 19 | +way to introduce flexibility but requiring some involvement. |
34 | -can be moved or shifted, Petri nets can be shifted globally and their | ||
35 | -bounding box can be computed. | ||
36 | - | ||
37 | -gv:: adds a method to draw a Petri net or a state graph using the tool | ||
38 | -http://www.graphviz.org[GraphViz] (through the Python binding | ||
39 | -http://networkx.lanl.gov/wiki/pygraphviz[PyGraphViz]). This module | ||
40 | -replaces the previous plugin called _graphviz_ and provides more | ||
41 | -flexibility and security, _graphviz_ is still provided but deprecated. | ||
42 | - | ||
43 | -status:: extends the Petri net model by adding status to the nodes. | ||
44 | -This is similar to what is used in the models of the PBC or Mnets | ||
45 | -family. Nodes can then merged automatically according to their status. | ||
46 | - | ||
47 | -ops:: this plugins defines control flow operations on Petri nets | ||
48 | -usually found in the PBC and Mnets family. Nets can be composed in | ||
49 | -parallel, sequence, choice and iteration. These operations rely on the | ||
50 | -places status. | ||
51 | - | ||
52 | -labels:: allows to add arbitrary labels to most objects (places, | ||
53 | -transitions, nets, ...) | ||
54 | - | ||
55 | -posops:: combines the features of pos and ops plugins: the control | ||
56 | -flow operations are modified in order to rearrange the nodes position | ||
57 | -in order to provide well shaped nets. This plugin is deprecated | ||
58 | -because the new _gv_ does the work much better. | ||
59 | - | ||
60 | -synchro:: it defines the label-based transition synchronisation | ||
61 | -defined in the Mnets model. | ||
62 | - | ||
63 | -// export:: allows to save Petri nets objects in the format of the tools | ||
64 | -// http://pep.sourceforge.net[PEP], http://helena.cnam.fr[Helena] and | ||
65 | -// http://maria[Maria]. http://pnml[PNML] is also supported as it is | ||
66 | -// built-in SNAKES. | ||
67 | - | ||
68 | -lashdata:: allows to define data that is not handled in the places of | ||
69 | -the Petri net but stored instead in the special structures handled by | ||
70 | -the http://www.montefiore.ulg.ac.be/~boigelot/research/lash/[library | ||
71 | -Lash]. This allows in particular to aggregate possibly infinite states | ||
72 | -into one meta-state. | ||
73 | - | ||
74 | -clusters:: this is an auxiliary plugin that allows to group nodes in a | ||
75 | -Petri net. This feature is used by _ops_ in order to record how a net | ||
76 | -is constructed, which is exploited by _gv_ in order to build a nice | ||
77 | -layout of composed nets. | ||
78 | - | ||
79 | 20 | ||
80 | -Getting SNAKES and installing it | 21 | +Next step to use SNAKES should be to read the tutorial that describes installation and first steps. |
81 | --------------------------------- | ||
82 | 22 | ||
83 | -Download http://www.univ-paris12.fr/lacl/pommereau/soft/snakes/snakes-{VERSION}.tar.gz[$snakes-{VERSION}.tar.gz$] | 23 | +Useful links |
84 | -({sys:../stat snakes-{VERSION}.tar.gz}) | 24 | +------------ |
85 | 25 | ||
86 | -To install SNAKES, uncompress the archive and copy the directory | 26 | +- SNAKES homepage (documentation, tutorial, API reference, ...) |
87 | -snakes in a location where Python can find it (_i.e._, in a directory | 27 | + http://www.ibisc.univ-evry.fr/~fpommereau/SNAKES/ |
88 | -listed in your $PYTHONPATH$ environment variable). | 28 | +- SNAKES development page (source repository, history, bug reports, |
29 | + feature requests, ...) | ||
30 | + http://code.google.com/p/python-snakes | ||
31 | +- Ubuntu packages | ||
32 | + http://launchpad.net/~pommereau/+archive/ppa | ||
89 | 33 | ||
90 | -SNAKES should work with a Python version at least 2.5 but will _not_ | 34 | +Copyright |
91 | -work for an older version. Optionally, you may want to install | 35 | +--------- |
92 | -additional software required by some plugins: | ||
93 | 36 | ||
94 | -gv:: depends on http://www.graphviz.org[GraphViz] and its Python | 37 | +(C) 2007-2014 Franck Pommereau <franck.pommereau@ibisc.univ-evry.fr> |
95 | - binding http://networkx.lanl.gov/wiki/pygraphviz[PyGraphViz]. The | ||
96 | - plugin _graphviz_ depends on GraphViz only but is now deprecated. | ||
97 | - | ||
98 | -lashdata:: requires | ||
99 | - http://www.montefiore.ulg.ac.be/~boigelot/research/lash[Lash] and | ||
100 | - the | ||
101 | - http://www.univ-paris12.fr/lacl/pommereau/soft/index.html#PyLash[Python | ||
102 | - Lash binding]. | ||
103 | - | ||
104 | -[NOTE] | ||
105 | -===================== | ||
106 | -(C) 2007 Franck Pommereau <pommereau@univ-paris12.fr> | ||
107 | 38 | ||
108 | This library is free software; you can redistribute it and/or modify | 39 | This library is free software; you can redistribute it and/or modify |
109 | it under the terms of the GNU Lesser General Public License as | 40 | it under the terms of the GNU Lesser General Public License as |
... | @@ -119,34 +50,3 @@ You should have received a copy of the GNU Lesser General Public | ... | @@ -119,34 +50,3 @@ You should have received a copy of the GNU Lesser General Public |
119 | License along with this library; if not, write to the Free Software | 50 | License along with this library; if not, write to the Free Software |
120 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 | 51 | Foundation, Inc., 51 Franklin St, Fifth Floor, Boston, MA 02110-1301 |
121 | USA | 52 | USA |
122 | -===================== | ||
123 | - | ||
124 | - | ||
125 | -Contact | ||
126 | -------- | ||
127 | - | ||
128 | -Please feel free to send me comments, questions, bug reports or | ||
129 | -contributions by mailto:pommereau@univ-paris12.fr[email]. | ||
130 | - | ||
131 | -If you wish to be notified of the new releases of SNAKES, please | ||
132 | -register at the http://freshmeat.net/projects/snakes[FreshMeat page]. | ||
133 | - | ||
134 | -You may contribute to SNAKES by either send patches by email, or by | ||
135 | -using the https://launchpad.net/snakes[SNAKES Launchpad page]. | ||
136 | - | ||
137 | - | ||
138 | -Documentation | ||
139 | -------------- | ||
140 | - | ||
141 | -A good starting point may be the link:tutorial.html[tutorial]. Then, | ||
142 | -you may find the link:api/index.html[API reference manual] useful, it | ||
143 | -documents all the API and gives number of examples of how to use the | ||
144 | -various classes and functions. | ||
145 | - | ||
146 | -If you do not program Python, you can learn it in a few hours thanks | ||
147 | -to the very good http://docs.python.org/tut/tut.html[Python tutorial]. | ||
148 | - | ||
149 | -In order to know more about the PBC and M-nets family or the Petri net | ||
150 | -compositions defined in the plugins, you may read papers from | ||
151 | -http://www.univ-paris12.fr/lacl/pommereau/publis[my publications page] | ||
152 | -(in particular those with _calculus_ in the title). | ... | ... |
... | @@ -15,6 +15,15 @@ def doc_files() : | ... | @@ -15,6 +15,15 @@ def doc_files() : |
15 | result[target_dir].append(os.path.join(root, name)) | 15 | result[target_dir].append(os.path.join(root, name)) |
16 | return list(result.items()) | 16 | return list(result.items()) |
17 | 17 | ||
18 | +try : | ||
19 | + long_description=open("README").read() | ||
20 | +except : | ||
21 | + long_description="""SNAKES is a general purpose Petri net Python | ||
22 | +library allowing to define and execute most classes of Petri | ||
23 | +nets. It features a plugin system to allow its extension. In | ||
24 | +particular, plugins are provided to implement the operations | ||
25 | +usually found in the PBC and M-nets family.""" | ||
26 | + | ||
18 | if __name__ == "__main__" : | 27 | if __name__ == "__main__" : |
19 | print("Compiling Emacs files...") | 28 | print("Compiling Emacs files...") |
20 | if os.system("emacs -batch -f batch-byte-compile utils/abcd-mode.el") : | 29 | if os.system("emacs -batch -f batch-byte-compile utils/abcd-mode.el") : |
... | @@ -26,16 +35,12 @@ if __name__ == "__main__" : | ... | @@ -26,16 +35,12 @@ if __name__ == "__main__" : |
26 | setup(name="SNAKES", | 35 | setup(name="SNAKES", |
27 | version=open("VERSION").read().strip(), | 36 | version=open("VERSION").read().strip(), |
28 | description="SNAKES is the Net Algebra Kit for Editors and Simulators", | 37 | description="SNAKES is the Net Algebra Kit for Editors and Simulators", |
29 | - long_description="""SNAKES is a general purpose Petri net Python | 38 | + long_description=long_description, |
30 | - library allowing to define and execute most classes of Petri | ||
31 | - nets. It features a plugin system to allow its extension. In | ||
32 | - particular, plugins are provided to implement the operations | ||
33 | - usually found in the PBC and M-nets family.""", | ||
34 | author="Franck Pommereau", | 39 | author="Franck Pommereau", |
35 | - author_email="pommereau@univ-paris12.fr", | 40 | + author_email="franck.pommereau@ibisc.univ-evry.fr", |
36 | maintainer="Franck Pommereau", | 41 | maintainer="Franck Pommereau", |
37 | - maintainer_email="pommereau@univ-paris12.fr", | 42 | + maintainer_email="franck.pommereau@ibisc.univ-evry.fr", |
38 | - url="http://lacl.univ-paris12.fr/pommereau/soft/snakes", | 43 | + url="http://http://www.ibisc.univ-evry.fr/~fpommereau/SNAKES/", |
39 | scripts=["bin/abcd", | 44 | scripts=["bin/abcd", |
40 | "bin/snkc", | 45 | "bin/snkc", |
41 | "bin/snkd", | 46 | "bin/snkd", | ... | ... |
-
Please register or login to post a comment