{ "info": { "author": "Willem Meints", "author_email": "willem.meints@gmail.com", "bugtrack_url": null, "classifiers": [ "Development Status :: 1 - Planning", "Intended Audience :: Developers", "License :: OSI Approved :: Apache Software License", "Programming Language :: Python", "Programming Language :: Python :: 3", "Programming Language :: Python :: 3.6", "Programming Language :: Python :: Implementation :: CPython", "Programming Language :: Python :: Implementation :: PyPy" ], "description": "torchagent - A reinforcement learning library based on PyTorch\n==============================================================\nWelcome to the torchagent repository. This repository contains the sources\nfor the torchagent library.\n\n.. contents::\n\nWhat is it?\n-----------\n:code:`torchagent` is a library that implements various reinforcement learning algorithms for PyTorch.\nYou can use this library in combination with openAI Gym to implement reinforcement learning solutions.\n\nWhich algorithms are included?\n------------------------------\nCurrently the following algorithms are implemented:\n\n- Deep Q Learning \n- Double Q Learning\n\nInstallation\n------------\nYou can install the library using the following command:\n\n.. code::\n\n pip install torchagent\n\nUsage\n-----\nThe following code shows a basic agent that uses Deep Q Learning.\n\n.. code:: python\n\n from torchagent.memory import SequentialMemory\n from torchagent.agents import DQNAgent\n\n import torch\n import torch.nn as nn\n import torch.optim as optim\n\n class PolicyNetwork(nn.Module):\n def __init__(self):\n self.linear = nn.Linear(210 * 160, 3)\n\n def forward(self, x):\n return self.linear(x)\n\n policy_network = PolicyNetwork()\n memory = SequentialMemory(20)\n agent = DQNAgent(2, policy_network, nn.MSELoss(), optim.Adam(policy_network.parameters()), memory)\n\n env = gym.make('Assault-v0')\n\n for _ in range(50):\n state = env.reset()\n\n for t in count():\n action = agent.act(state)\n next_state, reward, done, _ = env.step(agent.act(state))\n\n agent.record(state, action, next_state, reward, done)\n agent.train()\n\n state = next_state\n\n if done:\n break\n\n\n", "description_content_type": "", "docs_url": null, "download_url": "", "downloads": { "last_day": -1, "last_month": -1, "last_week": -1 }, "home_page": "https://github.com/wmeints/torchagent", "keywords": "", "license": "Apache-2.0", "maintainer": "", "maintainer_email": "", "name": "torchagent", "package_url": "https://pypi.org/project/torchagent/", "platform": "", "project_url": "https://pypi.org/project/torchagent/", "project_urls": { "Homepage": "https://github.com/wmeints/torchagent" }, "release_url": "https://pypi.org/project/torchagent/0.2.3/", "requires_dist": null, "requires_python": ">=3.5.0", "summary": "Reinforcement learning extensions for PyTorch", "version": "0.2.3" }, "last_serial": 5306042, "releases": { "0.1.0": [ { "comment_text": "", "digests": { "md5": "a0b73e62e282f5851bf4ca858e1ee16a", "sha256": "5748c172c613ffb5f35c1a798d33795105b63d82210f342f72f1008ad9d0c19d" }, "downloads": -1, "filename": "torchagent-0.1.0-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "a0b73e62e282f5851bf4ca858e1ee16a", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": null, "size": 1534, "upload_time": "2019-05-07T22:56:43", "url": "https://files.pythonhosted.org/packages/ab/3c/f209da6c6c64b515ecd99a32de4532076fa0507c3ac4747419a2c0558635/torchagent-0.1.0-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "73abdcb7c160340f6685d199c0b98713", "sha256": "df63fe22fab1d3c43fd98c755877d0b82715b9745fa3dd1f92bec229ac6c2161" }, "downloads": -1, "filename": "torchagent-0.1.0.tar.gz", "has_sig": false, "md5_digest": "73abdcb7c160340f6685d199c0b98713", "packagetype": "sdist", "python_version": "source", "requires_python": null, "size": 1967, "upload_time": "2019-05-07T22:56:46", "url": "https://files.pythonhosted.org/packages/92/56/f1febc393050c86778c4b97fb276dd40102d8dad394ce5e3ed6aa358f66d/torchagent-0.1.0.tar.gz" } ], "0.1.1": [ { "comment_text": "", "digests": { "md5": "dab26335d4419af01708348712d0f206", "sha256": "4b61e64e451668c5eca47e36e8fd50c0ece67749a23336838e5639fb56188397" }, "downloads": -1, "filename": "torchagent-0.1.1-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "dab26335d4419af01708348712d0f206", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=3.5.0", "size": 1548, "upload_time": "2019-05-07T22:59:46", "url": "https://files.pythonhosted.org/packages/5c/8f/de96da5f7a6fc171e39be8e16cd157fb4201d9c760ef14356746fc6091ae/torchagent-0.1.1-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "5ca0a43af5f75e80e8be0cd7ea296cd0", "sha256": "e52844e417c9bd0523a4fe6f747af78a622f3a49897a71ff5eccf6cd329374d2" }, "downloads": -1, "filename": "torchagent-0.1.1.tar.gz", "has_sig": false, "md5_digest": "5ca0a43af5f75e80e8be0cd7ea296cd0", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5.0", "size": 2023, "upload_time": "2019-05-07T22:59:49", "url": "https://files.pythonhosted.org/packages/3c/aa/e8c1dac7f500acbc84d468260a13cfc033b3d1ce9d15463b3053b94ef4a2/torchagent-0.1.1.tar.gz" } ], "0.2.3": [ { "comment_text": "", "digests": { "md5": "2b7a4b04a98128a3187452723c766c10", "sha256": "5ce3acc09b15e3dd2a3786e2ad6762e4e2b91dfbf2083de9c9df8d4c9029e98e" }, "downloads": -1, "filename": "torchagent-0.2.3-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "2b7a4b04a98128a3187452723c766c10", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=3.5.0", "size": 8421, "upload_time": "2019-05-23T06:31:55", "url": "https://files.pythonhosted.org/packages/24/48/7a8ca95ae4164b031538862ef77ab58a817222db2dd4ba647b383c33f45d/torchagent-0.2.3-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "09a9386391b4367a2595844e3cce8d82", "sha256": "9511ee7a365ee9de41e06a84a8069c8d6397700d94fb3606f7dde04e9937fa03" }, "downloads": -1, "filename": "torchagent-0.2.3.tar.gz", "has_sig": false, "md5_digest": "09a9386391b4367a2595844e3cce8d82", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5.0", "size": 6078, "upload_time": "2019-05-23T06:31:56", "url": "https://files.pythonhosted.org/packages/04/26/36aa1c3fad96a9a2ba25dc7c2e1fe678be61f52aa09a2ef5c8b0b9751a73/torchagent-0.2.3.tar.gz" } ] }, "urls": [ { "comment_text": "", "digests": { "md5": "2b7a4b04a98128a3187452723c766c10", "sha256": "5ce3acc09b15e3dd2a3786e2ad6762e4e2b91dfbf2083de9c9df8d4c9029e98e" }, "downloads": -1, "filename": "torchagent-0.2.3-py2.py3-none-any.whl", "has_sig": false, "md5_digest": "2b7a4b04a98128a3187452723c766c10", "packagetype": "bdist_wheel", "python_version": "py2.py3", "requires_python": ">=3.5.0", "size": 8421, "upload_time": "2019-05-23T06:31:55", "url": "https://files.pythonhosted.org/packages/24/48/7a8ca95ae4164b031538862ef77ab58a817222db2dd4ba647b383c33f45d/torchagent-0.2.3-py2.py3-none-any.whl" }, { "comment_text": "", "digests": { "md5": "09a9386391b4367a2595844e3cce8d82", "sha256": "9511ee7a365ee9de41e06a84a8069c8d6397700d94fb3606f7dde04e9937fa03" }, "downloads": -1, "filename": "torchagent-0.2.3.tar.gz", "has_sig": false, "md5_digest": "09a9386391b4367a2595844e3cce8d82", "packagetype": "sdist", "python_version": "source", "requires_python": ">=3.5.0", "size": 6078, "upload_time": "2019-05-23T06:31:56", "url": "https://files.pythonhosted.org/packages/04/26/36aa1c3fad96a9a2ba25dc7c2e1fe678be61f52aa09a2ef5c8b0b9751a73/torchagent-0.2.3.tar.gz" } ] }