glaserl / viasp Goto Github PK
View Code? Open in Web Editor NEWA visualization tool for clingo
License: MIT License
A visualization tool for clingo
License: MIT License
Workflow dispatch inputs are strings, although they are called boolean
. ๐
If gh fixes this, the publish workflow will break again, so keep an eye on this.
Refer to ec545c6
And see issue: actions/runner#1483
Simply highlight the node
It right now says Stable Models which is stupid in some cases.
Write Facts/Partial Model/Stable Model instead.
Draw a program such that a node contains more symbols that it's possible to display and the ...
get's shown. Then, toggle "show all" in the settings menu.
The ...
disappear if the symbols now fit.
The ...
do not disappear, although there would be enough space for the symbols now.
c+p How to build your own ASP system?
import sys
from clingo.application import clingo_main, Application
from clingo.script import enable_python
enable_python()
class App(Application):
def main(self, ctl, files):
for path in files:
ctl.load(path)
if not files:
ctl.load("-")
ctl.ground([("base", [])])
ctl.solve()
if __name__ == "__main__":
clingo_main(App(), sys.argv[1:])
The program displayed is not updating sometimes
Start viasp (viasp &
)
Run any program using quickstart.py
Change the program to {r}.
Run again
graph for {r}.
is shown
The graph for the previous program is shown
Maybe the program database doesn't get cleared correctly?
Maybe as entry point
Should look sth like this:
import sys
import clingo
options = ["0"]
ctl = clingo.Control(options)
for path in sys.argv[1:]:
ctl.load(path)
if not sys.argv[1:]:
ctl.load("-")
ctl.ground([("base", [])])
with ctl.solve(yield_=True) as handle:
for m in handle: print("Answer:\n{}".format(m))
print(handle.get())
$ echo "{a(1..2)}." | python minimal_clingo_input_files.py
Answer:
Answer:
a(2)
Answer:
a(1)
Answer:
a(1) a(2)
SAT
>>> ctl = viasp.Control([0])
200 OK
Registered ClingoMethodCall(name='__init__', kwargs={'arguments': [0]}, uuid=UUID('1a373d22-32cf-4b1b-893b-f5da79507956'))
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
File "/opt/miniconda3/envs/testpipy/lib/python3.7/site-packages/viasp/wrapper.py", line 70, in __init__
super().__init__(*args, **kwargs)
File "/opt/miniconda3/envs/testpipy/lib/python3.7/site-packages/clingo/control.py", line 157, in __init__
c_mem.append(_ffi.new("char[]", arg.encode()))
AttributeError: 'int' object has no attribute 'encode'
Right now, #show statements are simply ignored.
It might be helpful if they would somehow be stored and passed to the frontend to have them as active filters from the beginning.
Set program to
a(1). a(2).
b(X) :- a(X).
{c(X)} :- b(X).
{d(X)} :- c(X).
{e(X)} :- d(X).
#Expected behaviour
The edges don't overlap
Some edges overlap unnecessarily
E.g.
app.layout = html.Div([
viasp_dash.ViaspDash(
id="myID",
backend_url="foobar.com:port"
),
html.Div(id='output')
])
Everything gets redrawn.
Everything gets redrawn but the fact node.
Fix after #43
Try
{rain, sprinkler}.
wet:- rain.
wet:- sprinkler.
Looking at you GraphDataBaseKEKL
Try
{rain; sprinkler} 1.
wet :- rain.
wet :- sprinkler.
Signature filter applies for each model.
do not filter results in general
Remove the bandage on top and draw a node instead
Hi @glaserL,
a lot has happened to viASP since you last worked on it and I want to give you a little update. I also have a request in regards to publishing.
I recently finished my master's thesis on the project where I added features and made it easier to use overall. At this stage, Javier and I decided to move the repository (my fork of viasp) to the potassco organization. You can try out the current version on binder: https://mybinder.org/v2/gh/potassco/viasp/main?filepath=examples%2FIntroduction%20to%20viASP.ipynb.
Now we would like to publish the current version to pypi. Since you are the owner of the three viasp packages (viasp, viasp-dash, viasp-backend) on pypi.org, there are a couple of options on how to update those from the new repository location:
You can choose any of these three ways and I will let you know any infos you need to finish it.
I hope to hear back from you soon!
Best,
Stephan
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.