{"action":"created","comment":{"url":"https://api.github.com/repos/intel-analytics/BigDL/pulls/comments/116893616","pull_request_review_id":38552370,"id":116893616,"diff_hunk":"@@ -201,6 +287,19 @@ object SGD {\n       state(\"evalCounter\") = nevals + 1\n       config(\"clr\") = clr\n     }\n+\n+    override def updateHyperParameter[T](optimMethod: SGD[T]): Unit = {\n+      val lr = optimMethod.learningRate\n+      val nevals = optimMethod.state.get[Int](\"evalCounter\").getOrElse(0)\n+      val clr = if (nevals > maxIteration) {\n+        0.0\n+      } else {\n+        -lr * math.pow(1.0 - nevals.toDouble / maxIteration, power)\n+      }\n+      println(s\"iteration is : ${nevals}. current learning rate is $clr\")","path":"spark/dl/src/main/scala/com/intel/analytics/bigdl/optim/SGD.scala","position":270,"original_position":270,"commit_id":"aa8375d29df07085eba3518c8502e27e0967b5d4","original_commit_id":"aa8375d29df07085eba3518c8502e27e0967b5d4","user":{"login":"qiuxin2012","id":4495653,"avatar_url":"https://avatars2.githubusercontent.com/u/4495653?v=3","gravatar_id":"","url":"https://api.github.com/users/qiuxin2012","html_url":"https://github.com/qiuxin2012","followers_url":"https://api.github.com/users/qiuxin2012/followers","following_url":"https://api.github.com/users/qiuxin2012/following{/other_user}","gists_url":"https://api.github.com/users/qiuxin2012/gists{/gist_id}","starred_url":"https://api.github.com/users/qiuxin2012/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/qiuxin2012/subscriptions","organizations_url":"https://api.github.com/users/qiuxin2012/orgs","repos_url":"https://api.github.com/users/qiuxin2012/repos","events_url":"https://api.github.com/users/qiuxin2012/events{/privacy}","received_events_url":"https://api.github.com/users/qiuxin2012/received_events","type":"User","site_admin":false},"body":"Could you delete println?","created_at":"2017-05-17T01:31:15Z","updated_at":"2017-05-17T01:31:15Z","html_url":"https://github.com/intel-analytics/BigDL/pull/802#discussion_r116893616","pull_request_url":"https://api.github.com/repos/intel-analytics/BigDL/pulls/802","_links":{"self":{"href":"https://api.github.com/repos/intel-analytics/BigDL/pulls/comments/116893616"},"html":{"href":"https://github.com/intel-analytics/BigDL/pull/802#discussion_r116893616"},"pull_request":{"href":"https://api.github.com/repos/intel-analytics/BigDL/pulls/802"}}},"pull_request":{"url":"https://api.github.com/repos/intel-analytics/BigDL/pulls/802","id":116694235,"html_url":"https://github.com/intel-analytics/BigDL/pull/802","diff_url":"https://github.com/intel-analytics/BigDL/pull/802.diff","patch_url":"https://github.com/intel-analytics/BigDL/pull/802.patch","issue_url":"https://api.github.com/repos/intel-analytics/BigDL/issues/802","number":802,"state":"closed","locked":false,"title":"refactor hyper parameters","user":{"login":"zhangxiaoli73","id":20787576,"avatar_url":"https://avatars3.githubusercontent.com/u/20787576?v=3","gravatar_id":"","url":"https://api.github.com/users/zhangxiaoli73","html_url":"https://github.com/zhangxiaoli73","followers_url":"https://api.github.com/users/zhangxiaoli73/followers","following_url":"https://api.github.com/users/zhangxiaoli73/following{/other_user}","gists_url":"https://api.github.com/users/zhangxiaoli73/gists{/gist_id}","starred_url":"https://api.github.com/users/zhangxiaoli73/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhangxiaoli73/subscriptions","organizations_url":"https://api.github.com/users/zhangxiaoli73/orgs","repos_url":"https://api.github.com/users/zhangxiaoli73/repos","events_url":"https://api.github.com/users/zhangxiaoli73/events{/privacy}","received_events_url":"https://api.github.com/users/zhangxiaoli73/received_events","type":"User","site_admin":false},"body":"## What changes were proposed in this pull request?\r\n\r\n(1) refactor hyper parameters of OptimMethod\r\n(2) add OptimMethod object to python\r\n\r\n## How was this patch tested?\r\n\r\nmanual test and unit test\r\n\r\n","created_at":"2017-04-20T05:41:31Z","updated_at":"2017-05-17T01:31:15Z","closed_at":"2017-05-12T02:04:22Z","merged_at":"2017-05-12T02:04:22Z","merge_commit_sha":"a986826a11c69c5a1a28d4f0c483aaf668a2d043","assignee":{"login":"zhichao-li","id":2662017,"avatar_url":"https://avatars0.githubusercontent.com/u/2662017?v=3","gravatar_id":"","url":"https://api.github.com/users/zhichao-li","html_url":"https://github.com/zhichao-li","followers_url":"https://api.github.com/users/zhichao-li/followers","following_url":"https://api.github.com/users/zhichao-li/following{/other_user}","gists_url":"https://api.github.com/users/zhichao-li/gists{/gist_id}","starred_url":"https://api.github.com/users/zhichao-li/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhichao-li/subscriptions","organizations_url":"https://api.github.com/users/zhichao-li/orgs","repos_url":"https://api.github.com/users/zhichao-li/repos","events_url":"https://api.github.com/users/zhichao-li/events{/privacy}","received_events_url":"https://api.github.com/users/zhichao-li/received_events","type":"User","site_admin":false},"assignees":[{"login":"zhichao-li","id":2662017,"avatar_url":"https://avatars0.githubusercontent.com/u/2662017?v=3","gravatar_id":"","url":"https://api.github.com/users/zhichao-li","html_url":"https://github.com/zhichao-li","followers_url":"https://api.github.com/users/zhichao-li/followers","following_url":"https://api.github.com/users/zhichao-li/following{/other_user}","gists_url":"https://api.github.com/users/zhichao-li/gists{/gist_id}","starred_url":"https://api.github.com/users/zhichao-li/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhichao-li/subscriptions","organizations_url":"https://api.github.com/users/zhichao-li/orgs","repos_url":"https://api.github.com/users/zhichao-li/repos","events_url":"https://api.github.com/users/zhichao-li/events{/privacy}","received_events_url":"https://api.github.com/users/zhichao-li/received_events","type":"User","site_admin":false},{"login":"qiuxin2012","id":4495653,"avatar_url":"https://avatars2.githubusercontent.com/u/4495653?v=3","gravatar_id":"","url":"https://api.github.com/users/qiuxin2012","html_url":"https://github.com/qiuxin2012","followers_url":"https://api.github.com/users/qiuxin2012/followers","following_url":"https://api.github.com/users/qiuxin2012/following{/other_user}","gists_url":"https://api.github.com/users/qiuxin2012/gists{/gist_id}","starred_url":"https://api.github.com/users/qiuxin2012/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/qiuxin2012/subscriptions","organizations_url":"https://api.github.com/users/qiuxin2012/orgs","repos_url":"https://api.github.com/users/qiuxin2012/repos","events_url":"https://api.github.com/users/qiuxin2012/events{/privacy}","received_events_url":"https://api.github.com/users/qiuxin2012/received_events","type":"User","site_admin":false}],"requested_reviewers":[],"milestone":null,"commits_url":"https://api.github.com/repos/intel-analytics/BigDL/pulls/802/commits","review_comments_url":"https://api.github.com/repos/intel-analytics/BigDL/pulls/802/comments","review_comment_url":"https://api.github.com/repos/intel-analytics/BigDL/pulls/comments{/number}","comments_url":"https://api.github.com/repos/intel-analytics/BigDL/issues/802/comments","statuses_url":"https://api.github.com/repos/intel-analytics/BigDL/statuses/aa8375d29df07085eba3518c8502e27e0967b5d4","head":{"label":"zhangxiaoli73:hyper","ref":"hyper","sha":"aa8375d29df07085eba3518c8502e27e0967b5d4","user":{"login":"zhangxiaoli73","id":20787576,"avatar_url":"https://avatars3.githubusercontent.com/u/20787576?v=3","gravatar_id":"","url":"https://api.github.com/users/zhangxiaoli73","html_url":"https://github.com/zhangxiaoli73","followers_url":"https://api.github.com/users/zhangxiaoli73/followers","following_url":"https://api.github.com/users/zhangxiaoli73/following{/other_user}","gists_url":"https://api.github.com/users/zhangxiaoli73/gists{/gist_id}","starred_url":"https://api.github.com/users/zhangxiaoli73/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhangxiaoli73/subscriptions","organizations_url":"https://api.github.com/users/zhangxiaoli73/orgs","repos_url":"https://api.github.com/users/zhangxiaoli73/repos","events_url":"https://api.github.com/users/zhangxiaoli73/events{/privacy}","received_events_url":"https://api.github.com/users/zhangxiaoli73/received_events","type":"User","site_admin":false},"repo":{"id":78390763,"name":"BigDL","full_name":"zhangxiaoli73/BigDL","owner":{"login":"zhangxiaoli73","id":20787576,"avatar_url":"https://avatars3.githubusercontent.com/u/20787576?v=3","gravatar_id":"","url":"https://api.github.com/users/zhangxiaoli73","html_url":"https://github.com/zhangxiaoli73","followers_url":"https://api.github.com/users/zhangxiaoli73/followers","following_url":"https://api.github.com/users/zhangxiaoli73/following{/other_user}","gists_url":"https://api.github.com/users/zhangxiaoli73/gists{/gist_id}","starred_url":"https://api.github.com/users/zhangxiaoli73/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/zhangxiaoli73/subscriptions","organizations_url":"https://api.github.com/users/zhangxiaoli73/orgs","repos_url":"https://api.github.com/users/zhangxiaoli73/repos","events_url":"https://api.github.com/users/zhangxiaoli73/events{/privacy}","received_events_url":"https://api.github.com/users/zhangxiaoli73/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/zhangxiaoli73/BigDL","description":"BigDL: Distributed Deep learning Library for Apache Spark","fork":true,"url":"https://api.github.com/repos/zhangxiaoli73/BigDL","forks_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/forks","keys_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/keys{/key_id}","collaborators_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/teams","hooks_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/hooks","issue_events_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/issues/events{/number}","events_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/events","assignees_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/assignees{/user}","branches_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/branches{/branch}","tags_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/tags","blobs_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/git/refs{/sha}","trees_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/git/trees{/sha}","statuses_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/statuses/{sha}","languages_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/languages","stargazers_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/stargazers","contributors_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/contributors","subscribers_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/subscribers","subscription_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/subscription","commits_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/commits{/sha}","git_commits_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/git/commits{/sha}","comments_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/comments{/number}","issue_comment_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/issues/comments{/number}","contents_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/contents/{+path}","compare_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/compare/{base}...{head}","merges_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/merges","archive_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/downloads","issues_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/issues{/number}","pulls_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/pulls{/number}","milestones_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/milestones{/number}","notifications_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/labels{/name}","releases_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/releases{/id}","deployments_url":"https://api.github.com/repos/zhangxiaoli73/BigDL/deployments","created_at":"2017-01-09T03:34:17Z","updated_at":"2017-02-12T10:19:01Z","pushed_at":"2017-05-15T07:21:41Z","git_url":"git://github.com/zhangxiaoli73/BigDL.git","ssh_url":"git@github.com:zhangxiaoli73/BigDL.git","clone_url":"https://github.com/zhangxiaoli73/BigDL.git","svn_url":"https://github.com/zhangxiaoli73/BigDL","homepage":"","size":11479,"stargazers_count":1,"watchers_count":1,"language":"Scala","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"open_issues_count":0,"forks":0,"open_issues":0,"watchers":1,"default_branch":"master"}},"base":{"label":"intel-analytics:master","ref":"master","sha":"eb944bf662086770acf6daccddaf7a9160afdae7","user":{"login":"intel-analytics","id":10941215,"avatar_url":"https://avatars0.githubusercontent.com/u/10941215?v=3","gravatar_id":"","url":"https://api.github.com/users/intel-analytics","html_url":"https://github.com/intel-analytics","followers_url":"https://api.github.com/users/intel-analytics/followers","following_url":"https://api.github.com/users/intel-analytics/following{/other_user}","gists_url":"https://api.github.com/users/intel-analytics/gists{/gist_id}","starred_url":"https://api.github.com/users/intel-analytics/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/intel-analytics/subscriptions","organizations_url":"https://api.github.com/users/intel-analytics/orgs","repos_url":"https://api.github.com/users/intel-analytics/repos","events_url":"https://api.github.com/users/intel-analytics/events{/privacy}","received_events_url":"https://api.github.com/users/intel-analytics/received_events","type":"Organization","site_admin":false},"repo":{"id":66823715,"name":"BigDL","full_name":"intel-analytics/BigDL","owner":{"login":"intel-analytics","id":10941215,"avatar_url":"https://avatars0.githubusercontent.com/u/10941215?v=3","gravatar_id":"","url":"https://api.github.com/users/intel-analytics","html_url":"https://github.com/intel-analytics","followers_url":"https://api.github.com/users/intel-analytics/followers","following_url":"https://api.github.com/users/intel-analytics/following{/other_user}","gists_url":"https://api.github.com/users/intel-analytics/gists{/gist_id}","starred_url":"https://api.github.com/users/intel-analytics/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/intel-analytics/subscriptions","organizations_url":"https://api.github.com/users/intel-analytics/orgs","repos_url":"https://api.github.com/users/intel-analytics/repos","events_url":"https://api.github.com/users/intel-analytics/events{/privacy}","received_events_url":"https://api.github.com/users/intel-analytics/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/intel-analytics/BigDL","description":"BigDL: Distributed Deep Learning Library for Apache Spark","fork":false,"url":"https://api.github.com/repos/intel-analytics/BigDL","forks_url":"https://api.github.com/repos/intel-analytics/BigDL/forks","keys_url":"https://api.github.com/repos/intel-analytics/BigDL/keys{/key_id}","collaborators_url":"https://api.github.com/repos/intel-analytics/BigDL/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/intel-analytics/BigDL/teams","hooks_url":"https://api.github.com/repos/intel-analytics/BigDL/hooks","issue_events_url":"https://api.github.com/repos/intel-analytics/BigDL/issues/events{/number}","events_url":"https://api.github.com/repos/intel-analytics/BigDL/events","assignees_url":"https://api.github.com/repos/intel-analytics/BigDL/assignees{/user}","branches_url":"https://api.github.com/repos/intel-analytics/BigDL/branches{/branch}","tags_url":"https://api.github.com/repos/intel-analytics/BigDL/tags","blobs_url":"https://api.github.com/repos/intel-analytics/BigDL/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/intel-analytics/BigDL/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/intel-analytics/BigDL/git/refs{/sha}","trees_url":"https://api.github.com/repos/intel-analytics/BigDL/git/trees{/sha}","statuses_url":"https://api.github.com/repos/intel-analytics/BigDL/statuses/{sha}","languages_url":"https://api.github.com/repos/intel-analytics/BigDL/languages","stargazers_url":"https://api.github.com/repos/intel-analytics/BigDL/stargazers","contributors_url":"https://api.github.com/repos/intel-analytics/BigDL/contributors","subscribers_url":"https://api.github.com/repos/intel-analytics/BigDL/subscribers","subscription_url":"https://api.github.com/repos/intel-analytics/BigDL/subscription","commits_url":"https://api.github.com/repos/intel-analytics/BigDL/commits{/sha}","git_commits_url":"https://api.github.com/repos/intel-analytics/BigDL/git/commits{/sha}","comments_url":"https://api.github.com/repos/intel-analytics/BigDL/comments{/number}","issue_comment_url":"https://api.github.com/repos/intel-analytics/BigDL/issues/comments{/number}","contents_url":"https://api.github.com/repos/intel-analytics/BigDL/contents/{+path}","compare_url":"https://api.github.com/repos/intel-analytics/BigDL/compare/{base}...{head}","merges_url":"https://api.github.com/repos/intel-analytics/BigDL/merges","archive_url":"https://api.github.com/repos/intel-analytics/BigDL/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/intel-analytics/BigDL/downloads","issues_url":"https://api.github.com/repos/intel-analytics/BigDL/issues{/number}","pulls_url":"https://api.github.com/repos/intel-analytics/BigDL/pulls{/number}","milestones_url":"https://api.github.com/repos/intel-analytics/BigDL/milestones{/number}","notifications_url":"https://api.github.com/repos/intel-analytics/BigDL/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/intel-analytics/BigDL/labels{/name}","releases_url":"https://api.github.com/repos/intel-analytics/BigDL/releases{/id}","deployments_url":"https://api.github.com/repos/intel-analytics/BigDL/deployments","created_at":"2016-08-29T07:59:50Z","updated_at":"2017-05-17T00:30:31Z","pushed_at":"2017-05-16T15:07:36Z","git_url":"git://github.com/intel-analytics/BigDL.git","ssh_url":"git@github.com:intel-analytics/BigDL.git","clone_url":"https://github.com/intel-analytics/BigDL.git","svn_url":"https://github.com/intel-analytics/BigDL","homepage":"","size":11651,"stargazers_count":1731,"watchers_count":1731,"language":"Scala","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":332,"mirror_url":null,"open_issues_count":112,"forks":332,"open_issues":112,"watchers":1731,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/intel-analytics/BigDL/pulls/802"},"html":{"href":"https://github.com/intel-analytics/BigDL/pull/802"},"issue":{"href":"https://api.github.com/repos/intel-analytics/BigDL/issues/802"},"comments":{"href":"https://api.github.com/repos/intel-analytics/BigDL/issues/802/comments"},"review_comments":{"href":"https://api.github.com/repos/intel-analytics/BigDL/pulls/802/comments"},"review_comment":{"href":"https://api.github.com/repos/intel-analytics/BigDL/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/intel-analytics/BigDL/pulls/802/commits"},"statuses":{"href":"https://api.github.com/repos/intel-analytics/BigDL/statuses/aa8375d29df07085eba3518c8502e27e0967b5d4"}}}}
{"actor":{"display_login":"qiuxin2012"}}