{"action":"created","comment":{"url":"https://api.github.com/repos/rlworkgroup/garage/pulls/comments/245122208","pull_request_review_id":189168805,"id":245122208,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDI0NTEyMjIwOA==","diff_hunk":"@@ -0,0 +1,118 @@\n+\"\"\"\n+ϵ-greedy policy.\n+\n+Random exploration according to the value of epsilon.\n+\"\"\"\n+import numpy as np\n+\n+from garage.core import Serializable\n+from garage.misc.overrides import overrides\n+from garage.tf.policies import Policy\n+from garage.tf.spaces import Box\n+\n+\n+class EpsilonGreedyPolicy(Policy, Serializable):\n+    \"\"\"\n+    ϵ-greedy policy.\n+\n+    Select action based on the value of ϵ. ϵ will decrease from\n+    max_epsilon to min_epsilon within decay_ratio * total_step.\n+\n+    At state s, with probability\n+    1 − ϵ: select action = argmax Q(s, a)\n+    ϵ    : select a random action","path":"garage/tf/policies/epsilon_greedy_policy.py","position":23,"original_position":23,"commit_id":"a08f77aa0fd77746f2a7dc5dee8e141949b31270","original_commit_id":"a08f77aa0fd77746f2a7dc5dee8e141949b31270","user":{"login":"ahtsan","id":10270515,"node_id":"MDQ6VXNlcjEwMjcwNTE1","avatar_url":"https://avatars1.githubusercontent.com/u/10270515?v=4","gravatar_id":"","url":"https://api.github.com/users/ahtsan","html_url":"https://github.com/ahtsan","followers_url":"https://api.github.com/users/ahtsan/followers","following_url":"https://api.github.com/users/ahtsan/following{/other_user}","gists_url":"https://api.github.com/users/ahtsan/gists{/gist_id}","starred_url":"https://api.github.com/users/ahtsan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ahtsan/subscriptions","organizations_url":"https://api.github.com/users/ahtsan/orgs","repos_url":"https://api.github.com/users/ahtsan/repos","events_url":"https://api.github.com/users/ahtsan/events{/privacy}","received_events_url":"https://api.github.com/users/ahtsan/received_events","type":"User","site_admin":false},"body":"I will change it to `np.random.uniform(...)` in choosing random actions so it will be from a uniform distribution.","created_at":"2019-01-03T20:23:06Z","updated_at":"2019-01-03T20:23:06Z","html_url":"https://github.com/rlworkgroup/garage/pull/457#discussion_r245122208","pull_request_url":"https://api.github.com/repos/rlworkgroup/garage/pulls/457","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/rlworkgroup/garage/pulls/comments/245122208"},"html":{"href":"https://github.com/rlworkgroup/garage/pull/457#discussion_r245122208"},"pull_request":{"href":"https://api.github.com/repos/rlworkgroup/garage/pulls/457"}},"in_reply_to_id":244934628},"pull_request":{"url":"https://api.github.com/repos/rlworkgroup/garage/pulls/457","id":241920485,"node_id":"MDExOlB1bGxSZXF1ZXN0MjQxOTIwNDg1","html_url":"https://github.com/rlworkgroup/garage/pull/457","diff_url":"https://github.com/rlworkgroup/garage/pull/457.diff","patch_url":"https://github.com/rlworkgroup/garage/pull/457.patch","issue_url":"https://api.github.com/repos/rlworkgroup/garage/issues/457","number":457,"state":"open","locked":false,"title":"Epsilon greedy policy","user":{"login":"ahtsan","id":10270515,"node_id":"MDQ6VXNlcjEwMjcwNTE1","avatar_url":"https://avatars1.githubusercontent.com/u/10270515?v=4","gravatar_id":"","url":"https://api.github.com/users/ahtsan","html_url":"https://github.com/ahtsan","followers_url":"https://api.github.com/users/ahtsan/followers","following_url":"https://api.github.com/users/ahtsan/following{/other_user}","gists_url":"https://api.github.com/users/ahtsan/gists{/gist_id}","starred_url":"https://api.github.com/users/ahtsan/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ahtsan/subscriptions","organizations_url":"https://api.github.com/users/ahtsan/orgs","repos_url":"https://api.github.com/users/ahtsan/repos","events_url":"https://api.github.com/users/ahtsan/events{/privacy}","received_events_url":"https://api.github.com/users/ahtsan/received_events","type":"User","site_admin":false},"body":"","created_at":"2019-01-03T07:20:06Z","updated_at":"2019-01-03T20:23:06Z","closed_at":null,"merged_at":null,"merge_commit_sha":"35b2caa211e2e8d864275ed4733a851633267a6b","assignee":null,"assignees":[],"requested_reviewers":[{"login":"krzentner","id":41180126,"node_id":"MDQ6VXNlcjQxMTgwMTI2","avatar_url":"https://avatars2.githubusercontent.com/u/41180126?v=4","gravatar_id":"","url":"https://api.github.com/users/krzentner","html_url":"https://github.com/krzentner","followers_url":"https://api.github.com/users/krzentner/followers","following_url":"https://api.github.com/users/krzentner/following{/other_user}","gists_url":"https://api.github.com/users/krzentner/gists{/gist_id}","starred_url":"https://api.github.com/users/krzentner/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/krzentner/subscriptions","organizations_url":"https://api.github.com/users/krzentner/orgs","repos_url":"https://api.github.com/users/krzentner/repos","events_url":"https://api.github.com/users/krzentner/events{/privacy}","received_events_url":"https://api.github.com/users/krzentner/received_events","type":"User","site_admin":false}],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/rlworkgroup/garage/pulls/457/commits","review_comments_url":"https://api.github.com/repos/rlworkgroup/garage/pulls/457/comments","review_comment_url":"https://api.github.com/repos/rlworkgroup/garage/pulls/comments{/number}","comments_url":"https://api.github.com/repos/rlworkgroup/garage/issues/457/comments","statuses_url":"https://api.github.com/repos/rlworkgroup/garage/statuses/a08f77aa0fd77746f2a7dc5dee8e141949b31270","head":{"label":"rlworkgroup:epsilon_greedy","ref":"epsilon_greedy","sha":"a08f77aa0fd77746f2a7dc5dee8e141949b31270","user":{"login":"rlworkgroup","id":39808070,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM5ODA4MDcw","avatar_url":"https://avatars0.githubusercontent.com/u/39808070?v=4","gravatar_id":"","url":"https://api.github.com/users/rlworkgroup","html_url":"https://github.com/rlworkgroup","followers_url":"https://api.github.com/users/rlworkgroup/followers","following_url":"https://api.github.com/users/rlworkgroup/following{/other_user}","gists_url":"https://api.github.com/users/rlworkgroup/gists{/gist_id}","starred_url":"https://api.github.com/users/rlworkgroup/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rlworkgroup/subscriptions","organizations_url":"https://api.github.com/users/rlworkgroup/orgs","repos_url":"https://api.github.com/users/rlworkgroup/repos","events_url":"https://api.github.com/users/rlworkgroup/events{/privacy}","received_events_url":"https://api.github.com/users/rlworkgroup/received_events","type":"Organization","site_admin":false},"repo":{"id":136846372,"node_id":"MDEwOlJlcG9zaXRvcnkxMzY4NDYzNzI=","name":"garage","full_name":"rlworkgroup/garage","private":false,"owner":{"login":"rlworkgroup","id":39808070,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM5ODA4MDcw","avatar_url":"https://avatars0.githubusercontent.com/u/39808070?v=4","gravatar_id":"","url":"https://api.github.com/users/rlworkgroup","html_url":"https://github.com/rlworkgroup","followers_url":"https://api.github.com/users/rlworkgroup/followers","following_url":"https://api.github.com/users/rlworkgroup/following{/other_user}","gists_url":"https://api.github.com/users/rlworkgroup/gists{/gist_id}","starred_url":"https://api.github.com/users/rlworkgroup/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rlworkgroup/subscriptions","organizations_url":"https://api.github.com/users/rlworkgroup/orgs","repos_url":"https://api.github.com/users/rlworkgroup/repos","events_url":"https://api.github.com/users/rlworkgroup/events{/privacy}","received_events_url":"https://api.github.com/users/rlworkgroup/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/rlworkgroup/garage","description":"A framework for reproducible reinforcement learning research","fork":false,"url":"https://api.github.com/repos/rlworkgroup/garage","forks_url":"https://api.github.com/repos/rlworkgroup/garage/forks","keys_url":"https://api.github.com/repos/rlworkgroup/garage/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rlworkgroup/garage/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rlworkgroup/garage/teams","hooks_url":"https://api.github.com/repos/rlworkgroup/garage/hooks","issue_events_url":"https://api.github.com/repos/rlworkgroup/garage/issues/events{/number}","events_url":"https://api.github.com/repos/rlworkgroup/garage/events","assignees_url":"https://api.github.com/repos/rlworkgroup/garage/assignees{/user}","branches_url":"https://api.github.com/repos/rlworkgroup/garage/branches{/branch}","tags_url":"https://api.github.com/repos/rlworkgroup/garage/tags","blobs_url":"https://api.github.com/repos/rlworkgroup/garage/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rlworkgroup/garage/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rlworkgroup/garage/git/refs{/sha}","trees_url":"https://api.github.com/repos/rlworkgroup/garage/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rlworkgroup/garage/statuses/{sha}","languages_url":"https://api.github.com/repos/rlworkgroup/garage/languages","stargazers_url":"https://api.github.com/repos/rlworkgroup/garage/stargazers","contributors_url":"https://api.github.com/repos/rlworkgroup/garage/contributors","subscribers_url":"https://api.github.com/repos/rlworkgroup/garage/subscribers","subscription_url":"https://api.github.com/repos/rlworkgroup/garage/subscription","commits_url":"https://api.github.com/repos/rlworkgroup/garage/commits{/sha}","git_commits_url":"https://api.github.com/repos/rlworkgroup/garage/git/commits{/sha}","comments_url":"https://api.github.com/repos/rlworkgroup/garage/comments{/number}","issue_comment_url":"https://api.github.com/repos/rlworkgroup/garage/issues/comments{/number}","contents_url":"https://api.github.com/repos/rlworkgroup/garage/contents/{+path}","compare_url":"https://api.github.com/repos/rlworkgroup/garage/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rlworkgroup/garage/merges","archive_url":"https://api.github.com/repos/rlworkgroup/garage/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rlworkgroup/garage/downloads","issues_url":"https://api.github.com/repos/rlworkgroup/garage/issues{/number}","pulls_url":"https://api.github.com/repos/rlworkgroup/garage/pulls{/number}","milestones_url":"https://api.github.com/repos/rlworkgroup/garage/milestones{/number}","notifications_url":"https://api.github.com/repos/rlworkgroup/garage/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rlworkgroup/garage/labels{/name}","releases_url":"https://api.github.com/repos/rlworkgroup/garage/releases{/id}","deployments_url":"https://api.github.com/repos/rlworkgroup/garage/deployments","created_at":"2018-06-10T21:31:23Z","updated_at":"2019-01-03T18:31:10Z","pushed_at":"2019-01-03T19:54:29Z","git_url":"git://github.com/rlworkgroup/garage.git","ssh_url":"git@github.com:rlworkgroup/garage.git","clone_url":"https://github.com/rlworkgroup/garage.git","svn_url":"https://github.com/rlworkgroup/garage","homepage":"","size":8949,"stargazers_count":173,"watchers_count":173,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":22,"mirror_url":null,"archived":false,"open_issues_count":119,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":22,"open_issues":119,"watchers":173,"default_branch":"master"}},"base":{"label":"rlworkgroup:master","ref":"master","sha":"241ae5c02f17e6fb4c6ec59b35454fe4b3dd1c23","user":{"login":"rlworkgroup","id":39808070,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM5ODA4MDcw","avatar_url":"https://avatars0.githubusercontent.com/u/39808070?v=4","gravatar_id":"","url":"https://api.github.com/users/rlworkgroup","html_url":"https://github.com/rlworkgroup","followers_url":"https://api.github.com/users/rlworkgroup/followers","following_url":"https://api.github.com/users/rlworkgroup/following{/other_user}","gists_url":"https://api.github.com/users/rlworkgroup/gists{/gist_id}","starred_url":"https://api.github.com/users/rlworkgroup/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rlworkgroup/subscriptions","organizations_url":"https://api.github.com/users/rlworkgroup/orgs","repos_url":"https://api.github.com/users/rlworkgroup/repos","events_url":"https://api.github.com/users/rlworkgroup/events{/privacy}","received_events_url":"https://api.github.com/users/rlworkgroup/received_events","type":"Organization","site_admin":false},"repo":{"id":136846372,"node_id":"MDEwOlJlcG9zaXRvcnkxMzY4NDYzNzI=","name":"garage","full_name":"rlworkgroup/garage","private":false,"owner":{"login":"rlworkgroup","id":39808070,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM5ODA4MDcw","avatar_url":"https://avatars0.githubusercontent.com/u/39808070?v=4","gravatar_id":"","url":"https://api.github.com/users/rlworkgroup","html_url":"https://github.com/rlworkgroup","followers_url":"https://api.github.com/users/rlworkgroup/followers","following_url":"https://api.github.com/users/rlworkgroup/following{/other_user}","gists_url":"https://api.github.com/users/rlworkgroup/gists{/gist_id}","starred_url":"https://api.github.com/users/rlworkgroup/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/rlworkgroup/subscriptions","organizations_url":"https://api.github.com/users/rlworkgroup/orgs","repos_url":"https://api.github.com/users/rlworkgroup/repos","events_url":"https://api.github.com/users/rlworkgroup/events{/privacy}","received_events_url":"https://api.github.com/users/rlworkgroup/received_events","type":"Organization","site_admin":false},"html_url":"https://github.com/rlworkgroup/garage","description":"A framework for reproducible reinforcement learning research","fork":false,"url":"https://api.github.com/repos/rlworkgroup/garage","forks_url":"https://api.github.com/repos/rlworkgroup/garage/forks","keys_url":"https://api.github.com/repos/rlworkgroup/garage/keys{/key_id}","collaborators_url":"https://api.github.com/repos/rlworkgroup/garage/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/rlworkgroup/garage/teams","hooks_url":"https://api.github.com/repos/rlworkgroup/garage/hooks","issue_events_url":"https://api.github.com/repos/rlworkgroup/garage/issues/events{/number}","events_url":"https://api.github.com/repos/rlworkgroup/garage/events","assignees_url":"https://api.github.com/repos/rlworkgroup/garage/assignees{/user}","branches_url":"https://api.github.com/repos/rlworkgroup/garage/branches{/branch}","tags_url":"https://api.github.com/repos/rlworkgroup/garage/tags","blobs_url":"https://api.github.com/repos/rlworkgroup/garage/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/rlworkgroup/garage/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/rlworkgroup/garage/git/refs{/sha}","trees_url":"https://api.github.com/repos/rlworkgroup/garage/git/trees{/sha}","statuses_url":"https://api.github.com/repos/rlworkgroup/garage/statuses/{sha}","languages_url":"https://api.github.com/repos/rlworkgroup/garage/languages","stargazers_url":"https://api.github.com/repos/rlworkgroup/garage/stargazers","contributors_url":"https://api.github.com/repos/rlworkgroup/garage/contributors","subscribers_url":"https://api.github.com/repos/rlworkgroup/garage/subscribers","subscription_url":"https://api.github.com/repos/rlworkgroup/garage/subscription","commits_url":"https://api.github.com/repos/rlworkgroup/garage/commits{/sha}","git_commits_url":"https://api.github.com/repos/rlworkgroup/garage/git/commits{/sha}","comments_url":"https://api.github.com/repos/rlworkgroup/garage/comments{/number}","issue_comment_url":"https://api.github.com/repos/rlworkgroup/garage/issues/comments{/number}","contents_url":"https://api.github.com/repos/rlworkgroup/garage/contents/{+path}","compare_url":"https://api.github.com/repos/rlworkgroup/garage/compare/{base}...{head}","merges_url":"https://api.github.com/repos/rlworkgroup/garage/merges","archive_url":"https://api.github.com/repos/rlworkgroup/garage/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/rlworkgroup/garage/downloads","issues_url":"https://api.github.com/repos/rlworkgroup/garage/issues{/number}","pulls_url":"https://api.github.com/repos/rlworkgroup/garage/pulls{/number}","milestones_url":"https://api.github.com/repos/rlworkgroup/garage/milestones{/number}","notifications_url":"https://api.github.com/repos/rlworkgroup/garage/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/rlworkgroup/garage/labels{/name}","releases_url":"https://api.github.com/repos/rlworkgroup/garage/releases{/id}","deployments_url":"https://api.github.com/repos/rlworkgroup/garage/deployments","created_at":"2018-06-10T21:31:23Z","updated_at":"2019-01-03T18:31:10Z","pushed_at":"2019-01-03T19:54:29Z","git_url":"git://github.com/rlworkgroup/garage.git","ssh_url":"git@github.com:rlworkgroup/garage.git","clone_url":"https://github.com/rlworkgroup/garage.git","svn_url":"https://github.com/rlworkgroup/garage","homepage":"","size":8949,"stargazers_count":173,"watchers_count":173,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":22,"mirror_url":null,"archived":false,"open_issues_count":119,"license":{"key":"mit","name":"MIT License","spdx_id":"MIT","url":"https://api.github.com/licenses/mit","node_id":"MDc6TGljZW5zZTEz"},"forks":22,"open_issues":119,"watchers":173,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/rlworkgroup/garage/pulls/457"},"html":{"href":"https://github.com/rlworkgroup/garage/pull/457"},"issue":{"href":"https://api.github.com/repos/rlworkgroup/garage/issues/457"},"comments":{"href":"https://api.github.com/repos/rlworkgroup/garage/issues/457/comments"},"review_comments":{"href":"https://api.github.com/repos/rlworkgroup/garage/pulls/457/comments"},"review_comment":{"href":"https://api.github.com/repos/rlworkgroup/garage/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/rlworkgroup/garage/pulls/457/commits"},"statuses":{"href":"https://api.github.com/repos/rlworkgroup/garage/statuses/a08f77aa0fd77746f2a7dc5dee8e141949b31270"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"ahtsan"}}