Non-deterministic execution of Python functions
gitlab.inria.fr
Non-deterministic execution of Python functions
1–10 of 17 posts
Re: Non-deterministic execution of Python functions
#2Re: Non-deterministic execution of Python functions
#3Making this further relevant is that perhaps the most well known example of monadic programming of lists is: Python's list comprehensions. Which makes a bit surprised to see that not more explored/exploited in this library.
Interesting nonetheless!
Re: Non-deterministic execution of Python functions
#4Prolog does sunshine like this, no? You give it rules and then make a statement with a blank in it and it'll fill in the blank given the rules you've described.
Re: Non-deterministic execution of Python functions
#5Re: Non-deterministic execution of Python functions
#6The idea seems so similar to the classical AMB ambiguous operator introduced by John McCarthy [0]. The implementation seems similar to what I've done a while ago, too, just in Lisp and using Lisp primitives rather than function decorators. [0] http://www.randomhacks.net/2005/10/11/amb-operator/ [1] https://github.com/phoe/amb/
Re: Non-deterministic execution of Python functions
#7The idea seems so similar to the classical AMB ambiguous operator introduced by John McCarthy [0]. The implementation seems similar to what I've done a while ago, too, just in Lisp and using Lisp primitives rather than function decorators. [0] http://www.randomhacks.net/2005/10/11/amb-operator/ [1] https://github.com/phoe/amb/
Does Screamer also do something similar? http://nikodemus.github.io/screamer/
My implementation of AMB is purposefully small (70 LOC, not counting docstrings and tests and system definition), so that it can fit on a page of paper and be easily understood.
Re: Non-deterministic execution of Python functions
#8The idea seems so similar to the classical AMB ambiguous operator introduced by John McCarthy [0]. The implementation seems similar to what I've done a while ago, too, just in Lisp and using Lisp primitives rather than function decorators. [0] http://www.randomhacks.net/2005/10/11/amb-operator/ [1] https://github.com/phoe/amb/
Re: Non-deterministic execution of Python functions
#9Useful to explain non-determinism to students. I saw a similar idea before at https://github.com/aeporreca/nondeterminism which uses fork() to (inefficiently) explore all possible guesses concurrently
Re: Non-deterministic execution of Python functions
#10Useful to explain non-determinism to students. I saw a similar idea before at https://github.com/aeporreca/nondeterminism which uses fork() to (inefficiently) explore all possible guesses concurrently
It doesn't help that CS students will potentially end up hearing the term "nondeterminism" to mean different things in different contexts. In the context of the linked repo, it's used in the way they'll probably encounter it when learning about Turing machines, but in less formal contexts it also gets used a lot to describe stuff like "Heisenbugs" where running something more than once doesn't necessarily end up in t…
There are pretty formal contexts in which it also means things like that! It's not about formalism, it's just about context.