{"action":"opened","number":3822,"pull_request":{"url":"https://api.github.com/repos/mne-tools/mne-python/pulls/3822","id":96923265,"html_url":"https://github.com/mne-tools/mne-python/pull/3822","diff_url":"https://github.com/mne-tools/mne-python/pull/3822.diff","patch_url":"https://github.com/mne-tools/mne-python/pull/3822.patch","issue_url":"https://api.github.com/repos/mne-tools/mne-python/issues/3822","number":3822,"state":"open","locked":false,"title":"[WIP] Welch PR 1 - add spectral helper","user":{"login":"mmagnuski","id":8452354,"avatar_url":"https://avatars.githubusercontent.com/u/8452354?v=3","gravatar_id":"","url":"https://api.github.com/users/mmagnuski","html_url":"https://github.com/mmagnuski","followers_url":"https://api.github.com/users/mmagnuski/followers","following_url":"https://api.github.com/users/mmagnuski/following{/other_user}","gists_url":"https://api.github.com/users/mmagnuski/gists{/gist_id}","starred_url":"https://api.github.com/users/mmagnuski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmagnuski/subscriptions","organizations_url":"https://api.github.com/users/mmagnuski/orgs","repos_url":"https://api.github.com/users/mmagnuski/repos","events_url":"https://api.github.com/users/mmagnuski/events{/privacy}","received_events_url":"https://api.github.com/users/mmagnuski/received_events","type":"User","site_admin":false},"body":"Breaking up #3820 into smaller steps.  \r\n\r\nThis one adds `_spectral_helper` from `scipy.signal.spectral` which is needed for different window reductions (median, trimmed mean etc. - this will come in subsequent PR) - because all public `scipy` functions reduce windows with mean by default. This function has been somewhat adapted by throwing out unnecessary functionality. More on this in notes section of `_spectral_helper`, copied below:\r\n> Differences with respect to `scipy.signal.spectral._spectral_helper`:\r\n>* only one data argument - x instead of x and y, because csd is not\r\n  computed\r\n>* sampling frequency (`fs`) is no longer optional\r\n>* always returns one-sided spectrum thus `return_onesided` arg is gone\r\n>* use 'density' scaling by default (this is the default for\r\n  `scipy.signal.welch`)\r\n>* mode is always 'psd' so `mode` argument is removed\r\n\r\nTodos:\r\n- [ ] add tests against scipy's `csd` of relevant features of `_spectral_helper`\r\n\r\nThings to discuss:\r\n* is the way `_spectral_helper` is adapted ok for you?\r\n* `_spectral_helper` returns psd, time and freq - but time is unused and freq is computed in `_psd_welch` - so these return args could be removed from `_spectral_helper`\r\n* I removed `_compute_psd` because it was not used anywhere","created_at":"2016-12-07T13:29:03Z","updated_at":"2016-12-07T13:29:03Z","closed_at":null,"merged_at":null,"merge_commit_sha":"89d7b899b5aa6d0346ea4eea5b77c24c040ac832","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/mne-tools/mne-python/pulls/3822/commits","review_comments_url":"https://api.github.com/repos/mne-tools/mne-python/pulls/3822/comments","review_comment_url":"https://api.github.com/repos/mne-tools/mne-python/pulls/comments{/number}","comments_url":"https://api.github.com/repos/mne-tools/mne-python/issues/3822/comments","statuses_url":"https://api.github.com/repos/mne-tools/mne-python/statuses/1785d89174e03d6e215cf750775b8ba45bb7e074","head":{"label":"mmagnuski:welch_add_spectral_helper","ref":"welch_add_spectral_helper","sha":"1785d89174e03d6e215cf750775b8ba45bb7e074","user":{"login":"mmagnuski","id":8452354,"avatar_url":"https://avatars.githubusercontent.com/u/8452354?v=3","gravatar_id":"","url":"https://api.github.com/users/mmagnuski","html_url":"https://github.com/mmagnuski","followers_url":"https://api.github.com/users/mmagnuski/followers","following_url":"https://api.github.com/users/mmagnuski/following{/other_user}","gists_url":"https://api.github.com/users/mmagnuski/gists{/gist_id}","starred_url":"https://api.github.com/users/mmagnuski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmagnuski/subscriptions","organizations_url":"https://api.github.com/users/mmagnuski/orgs","repos_url":"https://api.github.com/users/mmagnuski/repos","events_url":"https://api.github.com/users/mmagnuski/events{/privacy}","received_events_url":"https://api.github.com/users/mmagnuski/received_events","type":"User","site_admin":false},"repo":{"id":49723382,"name":"mne-python","full_name":"mmagnuski/mne-python","owner":{"login":"mmagnuski","id":8452354,"avatar_url":"https://avatars.githubusercontent.com/u/8452354?v=3","gravatar_id":"","url":"https://api.github.com/users/mmagnuski","html_url":"https://github.com/mmagnuski","followers_url":"https://api.github.com/users/mmagnuski/followers","following_url":"https://api.github.com/users/mmagnuski/following{/other_user}","gists_url":"https://api.github.com/users/mmagnuski/gists{/gist_id}","starred_url":"https://api.github.com/users/mmagnuski/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mmagnuski/subscriptions","organizations_url":"https://api.github.com/users/mmagnuski/orgs","repos_url":"https://api.github.com/users/mmagnuski/repos","events_url":"https://api.github.com/users/mmagnuski/events{/privacy}","received_events_url":"https://api.github.com/users/mmagnuski/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/mmagnuski/mne-python","description":"MNE : Magnetoencephalography (MEG) and Electroencephalography (EEG) in Python","fork":true,"url":"https://api.github.com/repos/mmagnuski/mne-python","forks_url":"https://api.github.com/repos/mmagnuski/mne-python/forks","keys_url":"https://api.github.com/repos/mmagnuski/mne-python/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mmagnuski/mne-python/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mmagnuski/mne-python/teams","hooks_url":"https://api.github.com/repos/mmagnuski/mne-python/hooks","issue_events_url":"https://api.github.com/repos/mmagnuski/mne-python/issues/events{/number}","events_url":"https://api.github.com/repos/mmagnuski/mne-python/events","assignees_url":"https://api.github.com/repos/mmagnuski/mne-python/assignees{/user}","branches_url":"https://api.github.com/repos/mmagnuski/mne-python/branches{/branch}","tags_url":"https://api.github.com/repos/mmagnuski/mne-python/tags","blobs_url":"https://api.github.com/repos/mmagnuski/mne-python/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mmagnuski/mne-python/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mmagnuski/mne-python/git/refs{/sha}","trees_url":"https://api.github.com/repos/mmagnuski/mne-python/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mmagnuski/mne-python/statuses/{sha}","languages_url":"https://api.github.com/repos/mmagnuski/mne-python/languages","stargazers_url":"https://api.github.com/repos/mmagnuski/mne-python/stargazers","contributors_url":"https://api.github.com/repos/mmagnuski/mne-python/contributors","subscribers_url":"https://api.github.com/repos/mmagnuski/mne-python/subscribers","subscription_url":"https://api.github.com/repos/mmagnuski/mne-python/subscription","commits_url":"https://api.github.com/repos/mmagnuski/mne-python/commits{/sha}","git_commits_url":"https://api.github.com/repos/mmagnuski/mne-python/git/commits{/sha}","comments_url":"https://api.github.com/repos/mmagnuski/mne-python/comments{/number}","issue_comment_url":"https://api.github.com/repos/mmagnuski/mne-python/issues/comments{/number}","contents_url":"https://api.github.com/repos/mmagnuski/mne-python/contents/{+path}","compare_url":"https://api.github.com/repos/mmagnuski/mne-python/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mmagnuski/mne-python/merges","archive_url":"https://api.github.com/repos/mmagnuski/mne-python/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mmagnuski/mne-python/downloads","issues_url":"https://api.github.com/repos/mmagnuski/mne-python/issues{/number}","pulls_url":"https://api.github.com/repos/mmagnuski/mne-python/pulls{/number}","milestones_url":"https://api.github.com/repos/mmagnuski/mne-python/milestones{/number}","notifications_url":"https://api.github.com/repos/mmagnuski/mne-python/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mmagnuski/mne-python/labels{/name}","releases_url":"https://api.github.com/repos/mmagnuski/mne-python/releases{/id}","deployments_url":"https://api.github.com/repos/mmagnuski/mne-python/deployments","created_at":"2016-01-15T14:26:28Z","updated_at":"2016-01-15T14:26:31Z","pushed_at":"2016-12-07T13:13:53Z","git_url":"git://github.com/mmagnuski/mne-python.git","ssh_url":"git@github.com:mmagnuski/mne-python.git","clone_url":"https://github.com/mmagnuski/mne-python.git","svn_url":"https://github.com/mmagnuski/mne-python","homepage":"http://martinos.org/mne/","size":90420,"stargazers_count":0,"watchers_count":0,"language":"Python","has_issues":false,"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":0,"default_branch":"master"}},"base":{"label":"mne-tools:master","ref":"master","sha":"1bd2e44b621a1f1a09a7ba9bb0789de949d78d2d","user":{"login":"mne-tools","id":583875,"avatar_url":"https://avatars.githubusercontent.com/u/583875?v=3","gravatar_id":"","url":"https://api.github.com/users/mne-tools","html_url":"https://github.com/mne-tools","followers_url":"https://api.github.com/users/mne-tools/followers","following_url":"https://api.github.com/users/mne-tools/following{/other_user}","gists_url":"https://api.github.com/users/mne-tools/gists{/gist_id}","starred_url":"https://api.github.com/users/mne-tools/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mne-tools/subscriptions","organizations_url":"https://api.github.com/users/mne-tools/orgs","repos_url":"https://api.github.com/users/mne-tools/repos","events_url":"https://api.github.com/users/mne-tools/events{/privacy}","received_events_url":"https://api.github.com/users/mne-tools/received_events","type":"Organization","site_admin":false},"repo":{"id":1301584,"name":"mne-python","full_name":"mne-tools/mne-python","owner":{"login":"mne-tools","id":583875,"avatar_url":"https://avatars.githubusercontent.com/u/583875?v=3","gravatar_id":"","url":"https://api.github.com/users/mne-tools","html_url":"https://github.com/mne-tools","followers_url":"https://api.github.com/users/mne-tools/followers","following_url":"https://api.github.com/users/mne-tools/following{/other_user}","gists_url":"https://api.github.com/users/mne-tools/gists{/gist_id}","starred_url":"https://api.github.com/users/mne-tools/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/mne-tools/subscriptions","organizations_url":"https://api.github.com/users/mne-tools/orgs","repos_url":"https://api.github.com/users/mne-tools/repos","events_url":"https://api.github.com/users/mne-tools/events{/privacy}","received_events_url":"https://api.github.com/users/mne-tools/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/mne-tools/mne-python","description":"MNE : Magnetoencephalography (MEG) and Electroencephalography (EEG) in Python","fork":false,"url":"https://api.github.com/repos/mne-tools/mne-python","forks_url":"https://api.github.com/repos/mne-tools/mne-python/forks","keys_url":"https://api.github.com/repos/mne-tools/mne-python/keys{/key_id}","collaborators_url":"https://api.github.com/repos/mne-tools/mne-python/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/mne-tools/mne-python/teams","hooks_url":"https://api.github.com/repos/mne-tools/mne-python/hooks","issue_events_url":"https://api.github.com/repos/mne-tools/mne-python/issues/events{/number}","events_url":"https://api.github.com/repos/mne-tools/mne-python/events","assignees_url":"https://api.github.com/repos/mne-tools/mne-python/assignees{/user}","branches_url":"https://api.github.com/repos/mne-tools/mne-python/branches{/branch}","tags_url":"https://api.github.com/repos/mne-tools/mne-python/tags","blobs_url":"https://api.github.com/repos/mne-tools/mne-python/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/mne-tools/mne-python/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/mne-tools/mne-python/git/refs{/sha}","trees_url":"https://api.github.com/repos/mne-tools/mne-python/git/trees{/sha}","statuses_url":"https://api.github.com/repos/mne-tools/mne-python/statuses/{sha}","languages_url":"https://api.github.com/repos/mne-tools/mne-python/languages","stargazers_url":"https://api.github.com/repos/mne-tools/mne-python/stargazers","contributors_url":"https://api.github.com/repos/mne-tools/mne-python/contributors","subscribers_url":"https://api.github.com/repos/mne-tools/mne-python/subscribers","subscription_url":"https://api.github.com/repos/mne-tools/mne-python/subscription","commits_url":"https://api.github.com/repos/mne-tools/mne-python/commits{/sha}","git_commits_url":"https://api.github.com/repos/mne-tools/mne-python/git/commits{/sha}","comments_url":"https://api.github.com/repos/mne-tools/mne-python/comments{/number}","issue_comment_url":"https://api.github.com/repos/mne-tools/mne-python/issues/comments{/number}","contents_url":"https://api.github.com/repos/mne-tools/mne-python/contents/{+path}","compare_url":"https://api.github.com/repos/mne-tools/mne-python/compare/{base}...{head}","merges_url":"https://api.github.com/repos/mne-tools/mne-python/merges","archive_url":"https://api.github.com/repos/mne-tools/mne-python/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/mne-tools/mne-python/downloads","issues_url":"https://api.github.com/repos/mne-tools/mne-python/issues{/number}","pulls_url":"https://api.github.com/repos/mne-tools/mne-python/pulls{/number}","milestones_url":"https://api.github.com/repos/mne-tools/mne-python/milestones{/number}","notifications_url":"https://api.github.com/repos/mne-tools/mne-python/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/mne-tools/mne-python/labels{/name}","releases_url":"https://api.github.com/repos/mne-tools/mne-python/releases{/id}","deployments_url":"https://api.github.com/repos/mne-tools/mne-python/deployments","created_at":"2011-01-28T03:31:13Z","updated_at":"2016-12-04T09:58:10Z","pushed_at":"2016-12-07T13:29:03Z","git_url":"git://github.com/mne-tools/mne-python.git","ssh_url":"git@github.com:mne-tools/mne-python.git","clone_url":"https://github.com/mne-tools/mne-python.git","svn_url":"https://github.com/mne-tools/mne-python","homepage":"http://martinos.org/mne/","size":183946,"stargazers_count":247,"watchers_count":247,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":226,"mirror_url":null,"open_issues_count":219,"forks":226,"open_issues":219,"watchers":247,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/mne-tools/mne-python/pulls/3822"},"html":{"href":"https://github.com/mne-tools/mne-python/pull/3822"},"issue":{"href":"https://api.github.com/repos/mne-tools/mne-python/issues/3822"},"comments":{"href":"https://api.github.com/repos/mne-tools/mne-python/issues/3822/comments"},"review_comments":{"href":"https://api.github.com/repos/mne-tools/mne-python/pulls/3822/comments"},"review_comment":{"href":"https://api.github.com/repos/mne-tools/mne-python/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/mne-tools/mne-python/pulls/3822/commits"},"statuses":{"href":"https://api.github.com/repos/mne-tools/mne-python/statuses/1785d89174e03d6e215cf750775b8ba45bb7e074"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":0,"review_comments":0,"commits":3,"additions":242,"deletions":19,"changed_files":1}}
{"actor":{"display_login":"mmagnuski"}}