payload: {"action":"created","issue":{"url":"https://api.github.com/repos/nengo/nengo/issues/1387","repository_url":"https://api.github.com/repos/nengo/nengo","labels_url":"https://api.github.com/repos/nengo/nengo/issues/1387/labels{/name}","comments_url":"https://api.github.com/repos/nengo/nengo/issues/1387/comments","events_url":"https://api.github.com/repos/nengo/nengo/issues/1387/events","html_url":"https://github.com/nengo/nengo/pull/1387","id":276474611,"node_id":"MDExOlB1bGxSZXF1ZXN0MTU0NDQ3ODgx","number":1387,"title":"Pickleable simulator","user":{"login":"hunse","id":1952250,"node_id":"MDQ6VXNlcjE5NTIyNTA=","avatar_url":"https://avatars1.githubusercontent.com/u/1952250?v=4","gravatar_id":"","url":"https://api.github.com/users/hunse","html_url":"https://github.com/hunse","followers_url":"https://api.github.com/users/hunse/followers","following_url":"https://api.github.com/users/hunse/following{/other_user}","gists_url":"https://api.github.com/users/hunse/gists{/gist_id}","starred_url":"https://api.github.com/users/hunse/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hunse/subscriptions","organizations_url":"https://api.github.com/users/hunse/orgs","repos_url":"https://api.github.com/users/hunse/repos","events_url":"https://api.github.com/users/hunse/events{/privacy}","received_events_url":"https://api.github.com/users/hunse/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":11,"created_at":"2017-11-23T21:32:22Z","updated_at":"2019-05-29T17:06:41Z","closed_at":null,"author_association":"CONTRIBUTOR","pull_request":{"url":"https://api.github.com/repos/nengo/nengo/pulls/1387","html_url":"https://github.com/nengo/nengo/pull/1387","diff_url":"https://github.com/nengo/nengo/pull/1387.diff","patch_url":"https://github.com/nengo/nengo/pull/1387.patch"},"body":"**Motivation and context:**\r\n<!--- Why is this change required? What problem does it solve? -->\r\n<!--- If it addresses an open issue, please link to the issue here. -->\r\n\r\nThis allows a whole simulator to be pickled. My main motivation is to allow a simulator to be saved occasionally when doing a learning task.\r\n\r\nOnly the model, signal values, and probe values are pickled (as well as some attributes like whether the simulator has a progress bar or optimizer). The step functions can then be re-built from this (so no functions are pickled).\r\n\r\nThe better expm function (imported from Scipy) is not necessary for this PR, but I added it when I realized our current synapse building can be unstable e.g. for Lowpass or Alpha synapses with small tau.\r\n\r\n**Interactions with other PRs:**\r\n<!--- If this change depends on or conflicts with another PR please list it here. -->\r\n<!--- If this PR contains commits from another PR, describe what commits in this PR are unique. -->\r\n<!--- If this PR is independent, then remove this section. -->\r\n\r\nThis depends on/supersedes #1135.\r\n\r\n**How has this been tested?**\r\n<!--- Please describe in detail how you tested your changes. -->\r\n<!--- Reviewers will test your PR in at least this way. -->\r\n\r\nI've added one test each for pickling models and simulators. I also slightly extended the ``expm`` test (with another test matrix) so that the old ``expm`` fails but the new one passes.\r\n\r\n**How long should this take to review?**\r\n<!--- Please estimate if this PR is a quick, average, or lengthy PR. -->\r\n<!--- Take into account both the size and complexity of the changes. -->\r\n<!--- Also note if this is a timely PR that should be reviewed by a certain date. -->\r\n<!--- Leave only the line that applies below: -->\r\n\r\n- Lengthy (more than 150 lines changed or changes are complicated)\r\n\r\n**Where should a reviewer start?**\r\n<!--- If the PR warrants it, indicate where a reviewer should start reviewing. -->\r\n<!--- All lengthy PRs and complicated average PRs warrant this section. -->\r\n<!--- If the PR is quick or straightforward, remove this section. -->\r\n\r\nThe commits should be reviewed individually. Each one is relatively self-contained and straightforward. The most complicated is adding signals to synapses, since now all Processes can return a dictionary of arrays that gets turned into signals for use in the ``make_step`` function.\r\n\r\n**Types of changes:**\r\n<!--- What types of changes does your code introduce? -->\r\n<!--- Leave all lines that apply below: -->\r\n\r\n- New feature (non-breaking change which adds functionality)\r\n\r\nCurrently this is breaking nengo_ocl, though it shouldn't be.\r\n\r\n**Checklist:**\r\n<!--- Go over all the following points. Put an `x` in all the boxes that apply. -->\r\n<!--- If a box is not applicable, please justify below the checklist. -->\r\n<!--- If you're unsure about any of these, don't hesitate to ask. -->\r\n<!--- We're here to help! -->\r\n\r\n- [x] I have read the **CONTRIBUTING.rst** document.\r\n- [x] I have updated the documentation accordingly.\r\n- [ ] I have included a changelog entry.\r\n- [x] I have added tests to cover my changes.\r\n- [x] I have run the test suite locally and all tests passed.\r\n\r\n**Still to do:**\r\n<!--- If this is a work in progress, note below what you still plan to do. -->\r\n<!--- Use the task list syntax `- [ ]` so that progress can be tracked. -->\r\n\r\nWhy is this breaking nengo_ocl??"},"comment":{"url":"https://api.github.com/repos/nengo/nengo/issues/comments/497025156","html_url":"https://github.com/nengo/nengo/pull/1387#issuecomment-497025156","issue_url":"https://api.github.com/repos/nengo/nengo/issues/1387","id":497025156,"node_id":"MDEyOklzc3VlQ29tbWVudDQ5NzAyNTE1Ng==","user":{"login":"hunse","id":1952250,"node_id":"MDQ6VXNlcjE5NTIyNTA=","avatar_url":"https://avatars1.githubusercontent.com/u/1952250?v=4","gravatar_id":"","url":"https://api.github.com/users/hunse","html_url":"https://github.com/hunse","followers_url":"https://api.github.com/users/hunse/followers","following_url":"https://api.github.com/users/hunse/following{/other_user}","gists_url":"https://api.github.com/users/hunse/gists{/gist_id}","starred_url":"https://api.github.com/users/hunse/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/hunse/subscriptions","organizations_url":"https://api.github.com/users/hunse/orgs","repos_url":"https://api.github.com/users/hunse/repos","events_url":"https://api.github.com/users/hunse/events{/privacy}","received_events_url":"https://api.github.com/users/hunse/received_events","type":"User","site_admin":false},"created_at":"2019-05-29T17:06:41Z","updated_at":"2019-05-29T17:06:41Z","author_association":"CONTRIBUTOR","body":"I redid my timing script now that this is based of #1535, and found that it's no slower than that branch for either `Lowpass` or `Alpha` synapses. I think the reason for the initial slowdown was that I had switched the transfer function implementation to reduce the number of states. Now that we no longer use transfer functions, it's a non-issue."}}
other: {"actor":{"display_login":"hunse"}}