{"action":"created","comment":{"url":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/comments/209530508","pull_request_review_id":145559725,"id":209530508,"node_id":"MDI0OlB1bGxSZXF1ZXN0UmV2aWV3Q29tbWVudDIwOTUzMDUwOA==","diff_hunk":"@@ -132,6 +132,21 @@ def optimizer(obj_func, initial_theta, bounds):\n     log_marginal_likelihood_value_ : float\n         The log-marginal-likelihood of ``self.kernel_.theta``\n \n+    Examples\n+    --------\n+    >>> from sklearn.datasets import make_friedman2\n+    >>> from sklearn.gaussian_process import GaussianProcessRegressor\n+    >>> from sklearn.gaussian_process.kernels import DotProduct, WhiteKernel\n+    >>> X, y = make_friedman2(n_samples=500, noise=0, random_state=0)\n+    >>> #kernel = DotProduct(sigma_0_bounds=(1e-3, 1e3))\n+    >>> kernel = DotProduct() + WhiteKernel()\n+    >>> gpr = GaussianProcessRegressor(kernel=kernel,\n+    ...         random_state=0).fit(X, y)\n+    >>> gpr.score(X, y) # doctest: +ELLIPSIS\n+    0.3680...\n+    >>> gpr.predict(X[:2,:], return_std=True) # doctest: +ELLIPSIS\n+    (array([653.0..., 592.1...]), array([316.6..., 316.6...]))","path":"sklearn/gaussian_process/gpr.py","position":17,"original_position":17,"commit_id":"12b76a7fb3bac4da55e5067ce8491925d3c3f5c0","original_commit_id":"12b76a7fb3bac4da55e5067ce8491925d3c3f5c0","user":{"login":"adrinjalali","id":1663864,"node_id":"MDQ6VXNlcjE2NjM4NjQ=","avatar_url":"https://avatars3.githubusercontent.com/u/1663864?v=4","gravatar_id":"","url":"https://api.github.com/users/adrinjalali","html_url":"https://github.com/adrinjalali","followers_url":"https://api.github.com/users/adrinjalali/followers","following_url":"https://api.github.com/users/adrinjalali/following{/other_user}","gists_url":"https://api.github.com/users/adrinjalali/gists{/gist_id}","starred_url":"https://api.github.com/users/adrinjalali/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrinjalali/subscriptions","organizations_url":"https://api.github.com/users/adrinjalali/orgs","repos_url":"https://api.github.com/users/adrinjalali/repos","events_url":"https://api.github.com/users/adrinjalali/events{/privacy}","received_events_url":"https://api.github.com/users/adrinjalali/received_events","type":"User","site_admin":false},"body":"Yeah I know. But it's already pretty tricky to come up with an example which is short, and doesn't give any convergence warning or something. GPs are just pretty unstable, and all example I've seen which actually work, are with over engineering of the prior and on low dimensional data (and I had to work with them for a while as a part of my thesis).\r\n\r\nI can take one of those one dimensional examples, generate data, and have it here. It'll be a bit more code, but it'll be clean results. Should I?","created_at":"2018-08-13T08:39:53Z","updated_at":"2018-08-13T08:39:53Z","html_url":"https://github.com/scikit-learn/scikit-learn/pull/11748#discussion_r209530508","pull_request_url":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/11748","author_association":"CONTRIBUTOR","_links":{"self":{"href":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/comments/209530508"},"html":{"href":"https://github.com/scikit-learn/scikit-learn/pull/11748#discussion_r209530508"},"pull_request":{"href":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/11748"}},"in_reply_to_id":209440744},"pull_request":{"url":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/11748","id":206202219,"node_id":"MDExOlB1bGxSZXF1ZXN0MjA2MjAyMjE5","html_url":"https://github.com/scikit-learn/scikit-learn/pull/11748","diff_url":"https://github.com/scikit-learn/scikit-learn/pull/11748.diff","patch_url":"https://github.com/scikit-learn/scikit-learn/pull/11748.patch","issue_url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/11748","number":11748,"state":"open","locked":false,"title":"[MRG] DOC GaussianProcess (classification and regression) examples added to docstrings","user":{"login":"adrinjalali","id":1663864,"node_id":"MDQ6VXNlcjE2NjM4NjQ=","avatar_url":"https://avatars3.githubusercontent.com/u/1663864?v=4","gravatar_id":"","url":"https://api.github.com/users/adrinjalali","html_url":"https://github.com/adrinjalali","followers_url":"https://api.github.com/users/adrinjalali/followers","following_url":"https://api.github.com/users/adrinjalali/following{/other_user}","gists_url":"https://api.github.com/users/adrinjalali/gists{/gist_id}","starred_url":"https://api.github.com/users/adrinjalali/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrinjalali/subscriptions","organizations_url":"https://api.github.com/users/adrinjalali/orgs","repos_url":"https://api.github.com/users/adrinjalali/repos","events_url":"https://api.github.com/users/adrinjalali/events{/privacy}","received_events_url":"https://api.github.com/users/adrinjalali/received_events","type":"User","site_admin":false},"body":"See #3846\r\n\r\n`GaussianProcess` examples added.","created_at":"2018-08-04T17:38:57Z","updated_at":"2018-08-13T08:39:53Z","closed_at":null,"merged_at":null,"merge_commit_sha":"22801a244cbe99b7aa21b443a8bbe0e960cdef68","assignee":null,"assignees":[],"requested_reviewers":[],"requested_teams":[],"labels":[],"milestone":null,"commits_url":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/11748/commits","review_comments_url":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/11748/comments","review_comment_url":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/comments{/number}","comments_url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/11748/comments","statuses_url":"https://api.github.com/repos/scikit-learn/scikit-learn/statuses/12b76a7fb3bac4da55e5067ce8491925d3c3f5c0","head":{"label":"adrinjalali:examples/gp-docstrings","ref":"examples/gp-docstrings","sha":"12b76a7fb3bac4da55e5067ce8491925d3c3f5c0","user":{"login":"adrinjalali","id":1663864,"node_id":"MDQ6VXNlcjE2NjM4NjQ=","avatar_url":"https://avatars3.githubusercontent.com/u/1663864?v=4","gravatar_id":"","url":"https://api.github.com/users/adrinjalali","html_url":"https://github.com/adrinjalali","followers_url":"https://api.github.com/users/adrinjalali/followers","following_url":"https://api.github.com/users/adrinjalali/following{/other_user}","gists_url":"https://api.github.com/users/adrinjalali/gists{/gist_id}","starred_url":"https://api.github.com/users/adrinjalali/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrinjalali/subscriptions","organizations_url":"https://api.github.com/users/adrinjalali/orgs","repos_url":"https://api.github.com/users/adrinjalali/repos","events_url":"https://api.github.com/users/adrinjalali/events{/privacy}","received_events_url":"https://api.github.com/users/adrinjalali/received_events","type":"User","site_admin":false},"repo":{"id":43740145,"node_id":"MDEwOlJlcG9zaXRvcnk0Mzc0MDE0NQ==","name":"scikit-learn","full_name":"adrinjalali/scikit-learn","owner":{"login":"adrinjalali","id":1663864,"node_id":"MDQ6VXNlcjE2NjM4NjQ=","avatar_url":"https://avatars3.githubusercontent.com/u/1663864?v=4","gravatar_id":"","url":"https://api.github.com/users/adrinjalali","html_url":"https://github.com/adrinjalali","followers_url":"https://api.github.com/users/adrinjalali/followers","following_url":"https://api.github.com/users/adrinjalali/following{/other_user}","gists_url":"https://api.github.com/users/adrinjalali/gists{/gist_id}","starred_url":"https://api.github.com/users/adrinjalali/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/adrinjalali/subscriptions","organizations_url":"https://api.github.com/users/adrinjalali/orgs","repos_url":"https://api.github.com/users/adrinjalali/repos","events_url":"https://api.github.com/users/adrinjalali/events{/privacy}","received_events_url":"https://api.github.com/users/adrinjalali/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/adrinjalali/scikit-learn","description":"scikit-learn: machine learning in Python","fork":true,"url":"https://api.github.com/repos/adrinjalali/scikit-learn","forks_url":"https://api.github.com/repos/adrinjalali/scikit-learn/forks","keys_url":"https://api.github.com/repos/adrinjalali/scikit-learn/keys{/key_id}","collaborators_url":"https://api.github.com/repos/adrinjalali/scikit-learn/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/adrinjalali/scikit-learn/teams","hooks_url":"https://api.github.com/repos/adrinjalali/scikit-learn/hooks","issue_events_url":"https://api.github.com/repos/adrinjalali/scikit-learn/issues/events{/number}","events_url":"https://api.github.com/repos/adrinjalali/scikit-learn/events","assignees_url":"https://api.github.com/repos/adrinjalali/scikit-learn/assignees{/user}","branches_url":"https://api.github.com/repos/adrinjalali/scikit-learn/branches{/branch}","tags_url":"https://api.github.com/repos/adrinjalali/scikit-learn/tags","blobs_url":"https://api.github.com/repos/adrinjalali/scikit-learn/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/adrinjalali/scikit-learn/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/adrinjalali/scikit-learn/git/refs{/sha}","trees_url":"https://api.github.com/repos/adrinjalali/scikit-learn/git/trees{/sha}","statuses_url":"https://api.github.com/repos/adrinjalali/scikit-learn/statuses/{sha}","languages_url":"https://api.github.com/repos/adrinjalali/scikit-learn/languages","stargazers_url":"https://api.github.com/repos/adrinjalali/scikit-learn/stargazers","contributors_url":"https://api.github.com/repos/adrinjalali/scikit-learn/contributors","subscribers_url":"https://api.github.com/repos/adrinjalali/scikit-learn/subscribers","subscription_url":"https://api.github.com/repos/adrinjalali/scikit-learn/subscription","commits_url":"https://api.github.com/repos/adrinjalali/scikit-learn/commits{/sha}","git_commits_url":"https://api.github.com/repos/adrinjalali/scikit-learn/git/commits{/sha}","comments_url":"https://api.github.com/repos/adrinjalali/scikit-learn/comments{/number}","issue_comment_url":"https://api.github.com/repos/adrinjalali/scikit-learn/issues/comments{/number}","contents_url":"https://api.github.com/repos/adrinjalali/scikit-learn/contents/{+path}","compare_url":"https://api.github.com/repos/adrinjalali/scikit-learn/compare/{base}...{head}","merges_url":"https://api.github.com/repos/adrinjalali/scikit-learn/merges","archive_url":"https://api.github.com/repos/adrinjalali/scikit-learn/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/adrinjalali/scikit-learn/downloads","issues_url":"https://api.github.com/repos/adrinjalali/scikit-learn/issues{/number}","pulls_url":"https://api.github.com/repos/adrinjalali/scikit-learn/pulls{/number}","milestones_url":"https://api.github.com/repos/adrinjalali/scikit-learn/milestones{/number}","notifications_url":"https://api.github.com/repos/adrinjalali/scikit-learn/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/adrinjalali/scikit-learn/labels{/name}","releases_url":"https://api.github.com/repos/adrinjalali/scikit-learn/releases{/id}","deployments_url":"https://api.github.com/repos/adrinjalali/scikit-learn/deployments","created_at":"2015-10-06T09:03:13Z","updated_at":"2018-08-13T07:52:34Z","pushed_at":"2018-08-13T08:32:52Z","git_url":"git://github.com/adrinjalali/scikit-learn.git","ssh_url":"git@github.com:adrinjalali/scikit-learn.git","clone_url":"https://github.com/adrinjalali/scikit-learn.git","svn_url":"https://github.com/adrinjalali/scikit-learn","homepage":"http://scikit-learn.org","size":91283,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":0,"mirror_url":null,"archived":false,"open_issues_count":0,"license":{"key":"other","name":"Other","spdx_id":null,"url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":0,"open_issues":0,"watchers":0,"default_branch":"master"}},"base":{"label":"scikit-learn:master","ref":"master","sha":"40e6c43cb49d6c1eb56faa46ca0ffa40ab6228b8","user":{"login":"scikit-learn","id":365630,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM2NTYzMA==","avatar_url":"https://avatars2.githubusercontent.com/u/365630?v=4","gravatar_id":"","url":"https://api.github.com/users/scikit-learn","html_url":"https://github.com/scikit-learn","followers_url":"https://api.github.com/users/scikit-learn/followers","following_url":"https://api.github.com/users/scikit-learn/following{/other_user}","gists_url":"https://api.github.com/users/scikit-learn/gists{/gist_id}","starred_url":"https://api.github.com/users/scikit-learn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scikit-learn/subscriptions","organizations_url":"https://api.github.com/users/scikit-learn/orgs","repos_url":"https://api.github.com/users/scikit-learn/repos","events_url":"https://api.github.com/users/scikit-learn/events{/privacy}","received_events_url":"https://api.github.com/users/scikit-learn/received_events","type":"Organization","site_admin":false},"repo":{"id":843222,"node_id":"MDEwOlJlcG9zaXRvcnk4NDMyMjI=","name":"scikit-learn","full_name":"scikit-learn/scikit-learn","owner":{"login":"scikit-learn","id":365630,"node_id":"MDEyOk9yZ2FuaXphdGlvbjM2NTYzMA==","avatar_url":"https://avatars2.githubusercontent.com/u/365630?v=4","gravatar_id":"","url":"https://api.github.com/users/scikit-learn","html_url":"https://github.com/scikit-learn","followers_url":"https://api.github.com/users/scikit-learn/followers","following_url":"https://api.github.com/users/scikit-learn/following{/other_user}","gists_url":"https://api.github.com/users/scikit-learn/gists{/gist_id}","starred_url":"https://api.github.com/users/scikit-learn/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/scikit-learn/subscriptions","organizations_url":"https://api.github.com/users/scikit-learn/orgs","repos_url":"https://api.github.com/users/scikit-learn/repos","events_url":"https://api.github.com/users/scikit-learn/events{/privacy}","received_events_url":"https://api.github.com/users/scikit-learn/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/scikit-learn/scikit-learn","description":"scikit-learn: machine learning in Python","fork":false,"url":"https://api.github.com/repos/scikit-learn/scikit-learn","forks_url":"https://api.github.com/repos/scikit-learn/scikit-learn/forks","keys_url":"https://api.github.com/repos/scikit-learn/scikit-learn/keys{/key_id}","collaborators_url":"https://api.github.com/repos/scikit-learn/scikit-learn/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/scikit-learn/scikit-learn/teams","hooks_url":"https://api.github.com/repos/scikit-learn/scikit-learn/hooks","issue_events_url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/events{/number}","events_url":"https://api.github.com/repos/scikit-learn/scikit-learn/events","assignees_url":"https://api.github.com/repos/scikit-learn/scikit-learn/assignees{/user}","branches_url":"https://api.github.com/repos/scikit-learn/scikit-learn/branches{/branch}","tags_url":"https://api.github.com/repos/scikit-learn/scikit-learn/tags","blobs_url":"https://api.github.com/repos/scikit-learn/scikit-learn/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/scikit-learn/scikit-learn/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/scikit-learn/scikit-learn/git/refs{/sha}","trees_url":"https://api.github.com/repos/scikit-learn/scikit-learn/git/trees{/sha}","statuses_url":"https://api.github.com/repos/scikit-learn/scikit-learn/statuses/{sha}","languages_url":"https://api.github.com/repos/scikit-learn/scikit-learn/languages","stargazers_url":"https://api.github.com/repos/scikit-learn/scikit-learn/stargazers","contributors_url":"https://api.github.com/repos/scikit-learn/scikit-learn/contributors","subscribers_url":"https://api.github.com/repos/scikit-learn/scikit-learn/subscribers","subscription_url":"https://api.github.com/repos/scikit-learn/scikit-learn/subscription","commits_url":"https://api.github.com/repos/scikit-learn/scikit-learn/commits{/sha}","git_commits_url":"https://api.github.com/repos/scikit-learn/scikit-learn/git/commits{/sha}","comments_url":"https://api.github.com/repos/scikit-learn/scikit-learn/comments{/number}","issue_comment_url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/comments{/number}","contents_url":"https://api.github.com/repos/scikit-learn/scikit-learn/contents/{+path}","compare_url":"https://api.github.com/repos/scikit-learn/scikit-learn/compare/{base}...{head}","merges_url":"https://api.github.com/repos/scikit-learn/scikit-learn/merges","archive_url":"https://api.github.com/repos/scikit-learn/scikit-learn/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/scikit-learn/scikit-learn/downloads","issues_url":"https://api.github.com/repos/scikit-learn/scikit-learn/issues{/number}","pulls_url":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls{/number}","milestones_url":"https://api.github.com/repos/scikit-learn/scikit-learn/milestones{/number}","notifications_url":"https://api.github.com/repos/scikit-learn/scikit-learn/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/scikit-learn/scikit-learn/labels{/name}","releases_url":"https://api.github.com/repos/scikit-learn/scikit-learn/releases{/id}","deployments_url":"https://api.github.com/repos/scikit-learn/scikit-learn/deployments","created_at":"2010-08-17T09:43:38Z","updated_at":"2018-08-13T08:21:16Z","pushed_at":"2018-08-13T08:26:42Z","git_url":"git://github.com/scikit-learn/scikit-learn.git","ssh_url":"git@github.com:scikit-learn/scikit-learn.git","clone_url":"https://github.com/scikit-learn/scikit-learn.git","svn_url":"https://github.com/scikit-learn/scikit-learn","homepage":"http://scikit-learn.org","size":93378,"stargazers_count":29897,"watchers_count":29897,"language":"Python","has_issues":true,"has_projects":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":14805,"mirror_url":null,"archived":false,"open_issues_count":1660,"license":{"key":"other","name":"Other","spdx_id":null,"url":null,"node_id":"MDc6TGljZW5zZTA="},"forks":14805,"open_issues":1660,"watchers":29897,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/11748"},"html":{"href":"https://github.com/scikit-learn/scikit-learn/pull/11748"},"issue":{"href":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/11748"},"comments":{"href":"https://api.github.com/repos/scikit-learn/scikit-learn/issues/11748/comments"},"review_comments":{"href":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/11748/comments"},"review_comment":{"href":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/scikit-learn/scikit-learn/pulls/11748/commits"},"statuses":{"href":"https://api.github.com/repos/scikit-learn/scikit-learn/statuses/12b76a7fb3bac4da55e5067ce8491925d3c3f5c0"}},"author_association":"CONTRIBUTOR"}}
{"actor":{"display_login":"adrinjalali"}}