{ "info": { "author": "Thiago P. Bueno", "author_email": "thiago.pbueno@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 3 - Alpha", "Environment :: Console", "Intended Audience :: Science/Research", "License :: OSI Approved :: GNU General Public License v3 (GPLv3)", "Natural Language :: English", "Operating System :: OS Independent", "Programming Language :: Python :: 3", "Topic :: Scientific/Engineering :: Artificial Intelligence" ], "description": "MDP-ProbLog\n===========\n\n MDP-ProbLog is a Python3 framework to represent and solve (infinite-horizon)\n MDPs using Probabilistic Logic Programming.\n\nInstall\n-------\n\nIt is required to have Python3 installed.\n\n::\n\n $ pip3 install mdpproblog\n\nUsage\n-----\n\n::\n\n $ mdp-problog --help\n usage: mdp-problog {list, show, simulate, solve} [-m DOMAIN INSTANCE] [OPTIONS]\n\n MDP-ProbLog is a Python3 framework to represent and solve Markovian Decision\n Processes by Probabilistic Logic Programming. This project is free software.\n Please check the documentation at http://pythonhosted.org/mdpproblog/.\n\n positional arguments:\n {list,show,solve,simulate}\n available commands: list examples, show and solve\n models or simulate optimal policy\n\n optional arguments:\n -h, --help show this help message and exit\n -m MODEL MODEL, --model MODEL MODEL\n list of domain and instance files\n -x EXAMPLE, --example EXAMPLE\n select model from examples\n -g GAMMA, --gamma GAMMA\n discount factor (default=0.9)\n -e EPSILON, --epsilon EPSILON\n maximum error (default=0.1)\n -t TRIALS, --trials TRIALS\n number of trials (default=100)\n -z HORIZON, --horizon HORIZON\n simulation horizon (default=30)\n\nInput\n-----\n\nDomain specification for the sysadmin planning problem\n(models/sysadmin/domain.pl).\n\n.. code:: prolog\n\n\n % Network topology properties\n accTotal([],A,A).\n accTotal([_|T],A,X) :- B is A+1, accTotal(T,B,X).\n total(L,T) :- accTotal(L,0,T).\n total_connected(C,T) :- connected(C,L),\n total(L,T).\n\n accAlive([],A,A).\n accAlive([H|T],A,X) :- running(H,0), B is A+1, accAlive(T,B,X).\n accAlive([H|T],A,X) :- not(running(H,0)), B is A, accAlive(T,B,X).\n alive(L,A) :- accAlive(L,0,A).\n total_running(C,R) :- connected(C,L),\n alive(L,R).\n\n % State fluents\n state_fluent(running(C)) :- computer(C).\n\n % Actions\n action(reboot(C)) :- computer(C).\n action(reboot(none)).\n\n % Transition model\n 1.00::running(C,1) :- reboot(C).\n 0.05::running(C,1) :- not(reboot(C)), not(running(C,0)).\n P::running(C,1) :- not(reboot(C)), running(C,0),\n total_connected(C,T), total_running(C,R), P is 0.45+0.50*R/T.\n\n % Utility attributes\n\n % costs\n utility(reboot(C), -0.75) :- computer(C).\n utility(reboot(none), 0.00).\n\n % rewards\n utility(running(C,0), 1.00) :- computer(C).\n\nExample\n-------\n\n::\n\n $ mdp-problog simulate -x sysadmin1\n\n Value(running(c1,0)=0, running(c2,0)=0, running(c3,0)=0) = 16.829\n Value(running(c1,0)=1, running(c2,0)=0, running(c3,0)=0) = 19.171\n Value(running(c1,0)=0, running(c2,0)=1, running(c3,0)=0) = 19.205\n Value(running(c1,0)=1, running(c2,0)=1, running(c3,0)=0) = 23.028\n Value(running(c1,0)=0, running(c2,0)=0, running(c3,0)=1) = 19.206\n Value(running(c1,0)=1, running(c2,0)=0, running(c3,0)=1) = 23.029\n Value(running(c1,0)=0, running(c2,0)=1, running(c3,0)=1) = 21.392\n Value(running(c1,0)=1, running(c2,0)=1, running(c3,0)=1) = 25.607\n\n Policy(running(c1,0)=0, running(c2,0)=0, running(c3,0)=0) = reboot(c1)\n Policy(running(c1,0)=1, running(c2,0)=0, running(c3,0)=0) = reboot(c3)\n Policy(running(c1,0)=0, running(c2,0)=1, running(c3,0)=0) = reboot(c1)\n Policy(running(c1,0)=1, running(c2,0)=1, running(c3,0)=0) = reboot(c3)\n Policy(running(c1,0)=0, running(c2,0)=0, running(c3,0)=1) = reboot(c1)\n Policy(running(c1,0)=1, running(c2,0)=0, running(c3,0)=1) = reboot(c2)\n Policy(running(c1,0)=0, running(c2,0)=1, running(c3,0)=1) = reboot(c1)\n Policy(running(c1,0)=1, running(c2,0)=1, running(c3,0)=1) = reboot(none)\n\n >> Value iteration converged in 0.196sec after 40 iterations.\n >> Average time per iteration = 0.005sec.\n\n Expectation(running(c1,0)=0, running(c2,0)=0, running(c3,0)=0) = 16.733\n Expectation(running(c1,0)=1, running(c2,0)=0, running(c3,0)=0) = 19.433\n Expectation(running(c1,0)=0, running(c2,0)=1, running(c3,0)=0) = 19.108\n Expectation(running(c1,0)=1, running(c2,0)=1, running(c3,0)=0) = 23.377\n Expectation(running(c1,0)=0, running(c2,0)=0, running(c3,0)=1) = 19.546\n Expectation(running(c1,0)=1, running(c2,0)=0, running(c3,0)=1) = 23.287\n Expectation(running(c1,0)=0, running(c2,0)=1, running(c3,0)=1) = 21.785\n Expectation(running(c1,0)=1, running(c2,0)=1, running(c3,0)=1) = 25.849\n\nLicense\n-------\n\nCopyright (c) 2016-2017 Thiago Pereira Bueno All Rights Reserved.\n\nMDPProbLog is free software: you can redistribute it and/or modify it\nunder the terms of the GNU Lesser General Public License as published by\nthe Free Software Foundation, either version 3 of the License, or (at\nyour option) any later version.\n\nMDPProbLog is distributed in the hope that it will be useful, but\nWITHOUT ANY WARRANTY; without even the implied warranty of\nMERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the GNU Lesser\nGeneral Public License for more details.\n\nYou should have received a copy of the GNU Lesser General Public License\nalong with MDPProbLog. If not, see http://www.gnu.org/licenses/.", "description_content_type": null, "docs_url": "https://pythonhosted.org/mdpproblog/", "download_url": "UNKNOWN", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/thiagopbueno/mdp-problog", "keywords": "planning,mdp,problog,probabilistic logic programming", "license": "GNU General Public License v3.0", "maintainer": null, "maintainer_email": null, "name": "mdpproblog", "package_url": "https://pypi.org/project/mdpproblog/", "platform": "UNKNOWN", "project_url": "https://pypi.org/project/mdpproblog/", "project_urls": { "Download": "UNKNOWN", "Homepage": "https://github.com/thiagopbueno/mdp-problog" }, "release_url": "https://pypi.org/project/mdpproblog/0.3.0/", "requires_dist": null, "requires_python": null, "summary": "A probabilistic logic programming framework to represent and solve MDPs.", "version": "0.3.0" }, "last_serial": 2739439, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "497db6f6fb1e1b9e8ddfb603a8e06206", "sha256": "8740e6a111e9be5e8ab3952bf311d90af04041e5ad0fc72b07e1b2dd86010520" }, "downloads": -1, "filename": "mdpproblog-0.1.0.tar.gz", "has_sig": false, "md5_digest": "497db6f6fb1e1b9e8ddfb603a8e06206", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 22320, "upload_time": "2017-03-08T00:53:59", "url": "https://files.pythonhosted.org/packages/d9/a8/f755b1d8f933cbed44410287800586356d0ec6d33f8ecdcd3a9f040d279b/mdpproblog-0.1.0.tar.gz" } ], "0.2.0": [ { "comment_text": "", "digests": { "md5": "a01cbe39a4cef8654a5735d29269f5ef", "sha256": "aee3706b66b7881a1610e2a751a73af58688b7647b3dc0f844b5560610a1702f" }, "downloads": -1, "filename": "mdpproblog-0.2.0.tar.gz", "has_sig": false, "md5_digest": "a01cbe39a4cef8654a5735d29269f5ef", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 24718, "upload_time": "2017-03-08T17:43:18", "url": "https://files.pythonhosted.org/packages/72/43/0214e0553b70cfe1de3db43069b91b81288b629784b84f558b0ac54588ee/mdpproblog-0.2.0.tar.gz" } ], "0.3.0": [ { "comment_text": "", "digests": { "md5": "9b115e799f487b125fc16323d1fc1e2c", "sha256": "ec0549ea215f510cc99725a6261787703ef469765b196af4f0bbfa5102309d9e" }, "downloads": -1, "filename": "mdpproblog-0.3.0.tar.gz", "has_sig": false, "md5_digest": "9b115e799f487b125fc16323d1fc1e2c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 28085, "upload_time": "2017-03-29T18:37:32", "url": "https://files.pythonhosted.org/packages/95/ec/086cd0b32fe5b99b85a032ec9aedd5a72bd4b38e0af7f0f7a15ac0170646/mdpproblog-0.3.0.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "9b115e799f487b125fc16323d1fc1e2c", "sha256": "ec0549ea215f510cc99725a6261787703ef469765b196af4f0bbfa5102309d9e" }, "downloads": -1, "filename": "mdpproblog-0.3.0.tar.gz", "has_sig": false, "md5_digest": "9b115e799f487b125fc16323d1fc1e2c", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 28085, "upload_time": "2017-03-29T18:37:32", "url": "https://files.pythonhosted.org/packages/95/ec/086cd0b32fe5b99b85a032ec9aedd5a72bd4b38e0af7f0f7a15ac0170646/mdpproblog-0.3.0.tar.gz" } ] }