{"action":"closed","number":194,"pull_request":{"url":"https://api.github.com/repos/Astroua/CARTAvis/pulls/194","id":91955606,"html_url":"https://github.com/Astroua/CARTAvis/pull/194","diff_url":"https://github.com/Astroua/CARTAvis/pull/194.diff","patch_url":"https://github.com/Astroua/CARTAvis/pull/194.patch","issue_url":"https://api.github.com/repos/Astroua/CARTAvis/issues/194","number":194,"state":"closed","locked":false,"title":"Fix calculation of intensity locations in quantile-finding function","user":{"login":"confluence","id":651030,"avatar_url":"https://avatars.githubusercontent.com/u/651030?v=3","gravatar_id":"","url":"https://api.github.com/users/confluence","html_url":"https://github.com/confluence","followers_url":"https://api.github.com/users/confluence/followers","following_url":"https://api.github.com/users/confluence/following{/other_user}","gists_url":"https://api.github.com/users/confluence/gists{/gist_id}","starred_url":"https://api.github.com/users/confluence/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/confluence/subscriptions","organizations_url":"https://api.github.com/users/confluence/orgs","repos_url":"https://api.github.com/users/confluence/repos","events_url":"https://api.github.com/users/confluence/events{/privacy}","received_events_url":"https://api.github.com/users/confluence/received_events","type":"User","site_admin":false},"body":"The current code for finding intensity values and their corresponding frame locations for percentiles does not calculate the location values correctly. After copies of the intensity values and their indices have been stored in separate vectors, the values are partially sorted with nth_element, at which point the relationship between the the values and indices is broken. The indices which are subsequently selected from the index vector are completely unrelated to the partially sorted intensities.\r\n\r\nIn addition to this, the code for calculating the divisor used to convert the absolute index value to a frame on the spectral axis seems to behave incorrectly on images with an additional axis after the spectral axis (e.g. Stokes parameters) -- any axes after the spectral axis are not included in the divisor. But I may have misinterpreted the intended behaviour -- please let me know if the new calculation is not correct.\r\n\r\nI have copied and sorted the data as a single vector of index:intensity tuples (using only the intensity value as the key). I also explored an alternative solution in which only the values are sorted and the indices are subsequently looked up by value in the original data, but this solution is faster.\r\n\r\nI am not sure what the expected correct behaviour is when the intensity returned for a percentile is found multiple times in different frames, and I would appreciate any guidance regarding this. As far as I know (from my correspondence with @slovelan) these frame values are only used in a unit conversion in the colour map.","created_at":"2016-11-02T11:52:52Z","updated_at":"2016-11-10T14:22:25Z","closed_at":"2016-11-10T14:22:25Z","merged_at":null,"merge_commit_sha":"fb081caa0758ee93d0fa1f67efc6cc2c83c6d88c","assignee":null,"assignees":[],"milestone":null,"commits_url":"https://api.github.com/repos/Astroua/CARTAvis/pulls/194/commits","review_comments_url":"https://api.github.com/repos/Astroua/CARTAvis/pulls/194/comments","review_comment_url":"https://api.github.com/repos/Astroua/CARTAvis/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Astroua/CARTAvis/issues/194/comments","statuses_url":"https://api.github.com/repos/Astroua/CARTAvis/statuses/82888d52ef04d0feee63ce915518d1148b5cadf5","head":{"label":"confluence:develop","ref":"develop","sha":"82888d52ef04d0feee63ce915518d1148b5cadf5","user":{"login":"confluence","id":651030,"avatar_url":"https://avatars.githubusercontent.com/u/651030?v=3","gravatar_id":"","url":"https://api.github.com/users/confluence","html_url":"https://github.com/confluence","followers_url":"https://api.github.com/users/confluence/followers","following_url":"https://api.github.com/users/confluence/following{/other_user}","gists_url":"https://api.github.com/users/confluence/gists{/gist_id}","starred_url":"https://api.github.com/users/confluence/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/confluence/subscriptions","organizations_url":"https://api.github.com/users/confluence/orgs","repos_url":"https://api.github.com/users/confluence/repos","events_url":"https://api.github.com/users/confluence/events{/privacy}","received_events_url":"https://api.github.com/users/confluence/received_events","type":"User","site_admin":false},"repo":{"id":50350330,"name":"CARTAvis","full_name":"confluence/CARTAvis","owner":{"login":"confluence","id":651030,"avatar_url":"https://avatars.githubusercontent.com/u/651030?v=3","gravatar_id":"","url":"https://api.github.com/users/confluence","html_url":"https://github.com/confluence","followers_url":"https://api.github.com/users/confluence/followers","following_url":"https://api.github.com/users/confluence/following{/other_user}","gists_url":"https://api.github.com/users/confluence/gists{/gist_id}","starred_url":"https://api.github.com/users/confluence/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/confluence/subscriptions","organizations_url":"https://api.github.com/users/confluence/orgs","repos_url":"https://api.github.com/users/confluence/repos","events_url":"https://api.github.com/users/confluence/events{/privacy}","received_events_url":"https://api.github.com/users/confluence/received_events","type":"User","site_admin":false},"private":false,"html_url":"https://github.com/confluence/CARTAvis","description":"Visualization Code for ALMA","fork":true,"url":"https://api.github.com/repos/confluence/CARTAvis","forks_url":"https://api.github.com/repos/confluence/CARTAvis/forks","keys_url":"https://api.github.com/repos/confluence/CARTAvis/keys{/key_id}","collaborators_url":"https://api.github.com/repos/confluence/CARTAvis/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/confluence/CARTAvis/teams","hooks_url":"https://api.github.com/repos/confluence/CARTAvis/hooks","issue_events_url":"https://api.github.com/repos/confluence/CARTAvis/issues/events{/number}","events_url":"https://api.github.com/repos/confluence/CARTAvis/events","assignees_url":"https://api.github.com/repos/confluence/CARTAvis/assignees{/user}","branches_url":"https://api.github.com/repos/confluence/CARTAvis/branches{/branch}","tags_url":"https://api.github.com/repos/confluence/CARTAvis/tags","blobs_url":"https://api.github.com/repos/confluence/CARTAvis/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/confluence/CARTAvis/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/confluence/CARTAvis/git/refs{/sha}","trees_url":"https://api.github.com/repos/confluence/CARTAvis/git/trees{/sha}","statuses_url":"https://api.github.com/repos/confluence/CARTAvis/statuses/{sha}","languages_url":"https://api.github.com/repos/confluence/CARTAvis/languages","stargazers_url":"https://api.github.com/repos/confluence/CARTAvis/stargazers","contributors_url":"https://api.github.com/repos/confluence/CARTAvis/contributors","subscribers_url":"https://api.github.com/repos/confluence/CARTAvis/subscribers","subscription_url":"https://api.github.com/repos/confluence/CARTAvis/subscription","commits_url":"https://api.github.com/repos/confluence/CARTAvis/commits{/sha}","git_commits_url":"https://api.github.com/repos/confluence/CARTAvis/git/commits{/sha}","comments_url":"https://api.github.com/repos/confluence/CARTAvis/comments{/number}","issue_comment_url":"https://api.github.com/repos/confluence/CARTAvis/issues/comments{/number}","contents_url":"https://api.github.com/repos/confluence/CARTAvis/contents/{+path}","compare_url":"https://api.github.com/repos/confluence/CARTAvis/compare/{base}...{head}","merges_url":"https://api.github.com/repos/confluence/CARTAvis/merges","archive_url":"https://api.github.com/repos/confluence/CARTAvis/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/confluence/CARTAvis/downloads","issues_url":"https://api.github.com/repos/confluence/CARTAvis/issues{/number}","pulls_url":"https://api.github.com/repos/confluence/CARTAvis/pulls{/number}","milestones_url":"https://api.github.com/repos/confluence/CARTAvis/milestones{/number}","notifications_url":"https://api.github.com/repos/confluence/CARTAvis/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/confluence/CARTAvis/labels{/name}","releases_url":"https://api.github.com/repos/confluence/CARTAvis/releases{/id}","deployments_url":"https://api.github.com/repos/confluence/CARTAvis/deployments","created_at":"2016-01-25T12:51:04Z","updated_at":"2016-01-25T12:51:06Z","pushed_at":"2016-11-10T10:57:26Z","git_url":"git://github.com/confluence/CARTAvis.git","ssh_url":"git@github.com:confluence/CARTAvis.git","clone_url":"https://github.com/confluence/CARTAvis.git","svn_url":"https://github.com/confluence/CARTAvis","homepage":null,"size":24960,"stargazers_count":0,"watchers_count":0,"language":"C++","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":"Astroua:develop","ref":"develop","sha":"35698640a02312158d18cf7d5aaf6d0565bf8281","user":{"login":"Astroua","id":5502523,"avatar_url":"https://avatars.githubusercontent.com/u/5502523?v=3","gravatar_id":"","url":"https://api.github.com/users/Astroua","html_url":"https://github.com/Astroua","followers_url":"https://api.github.com/users/Astroua/followers","following_url":"https://api.github.com/users/Astroua/following{/other_user}","gists_url":"https://api.github.com/users/Astroua/gists{/gist_id}","starred_url":"https://api.github.com/users/Astroua/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Astroua/subscriptions","organizations_url":"https://api.github.com/users/Astroua/orgs","repos_url":"https://api.github.com/users/Astroua/repos","events_url":"https://api.github.com/users/Astroua/events{/privacy}","received_events_url":"https://api.github.com/users/Astroua/received_events","type":"Organization","site_admin":false},"repo":{"id":16624384,"name":"CARTAvis","full_name":"Astroua/CARTAvis","owner":{"login":"Astroua","id":5502523,"avatar_url":"https://avatars.githubusercontent.com/u/5502523?v=3","gravatar_id":"","url":"https://api.github.com/users/Astroua","html_url":"https://github.com/Astroua","followers_url":"https://api.github.com/users/Astroua/followers","following_url":"https://api.github.com/users/Astroua/following{/other_user}","gists_url":"https://api.github.com/users/Astroua/gists{/gist_id}","starred_url":"https://api.github.com/users/Astroua/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Astroua/subscriptions","organizations_url":"https://api.github.com/users/Astroua/orgs","repos_url":"https://api.github.com/users/Astroua/repos","events_url":"https://api.github.com/users/Astroua/events{/privacy}","received_events_url":"https://api.github.com/users/Astroua/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Astroua/CARTAvis","description":"Visualization Code for ALMA","fork":false,"url":"https://api.github.com/repos/Astroua/CARTAvis","forks_url":"https://api.github.com/repos/Astroua/CARTAvis/forks","keys_url":"https://api.github.com/repos/Astroua/CARTAvis/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Astroua/CARTAvis/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Astroua/CARTAvis/teams","hooks_url":"https://api.github.com/repos/Astroua/CARTAvis/hooks","issue_events_url":"https://api.github.com/repos/Astroua/CARTAvis/issues/events{/number}","events_url":"https://api.github.com/repos/Astroua/CARTAvis/events","assignees_url":"https://api.github.com/repos/Astroua/CARTAvis/assignees{/user}","branches_url":"https://api.github.com/repos/Astroua/CARTAvis/branches{/branch}","tags_url":"https://api.github.com/repos/Astroua/CARTAvis/tags","blobs_url":"https://api.github.com/repos/Astroua/CARTAvis/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Astroua/CARTAvis/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Astroua/CARTAvis/git/refs{/sha}","trees_url":"https://api.github.com/repos/Astroua/CARTAvis/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Astroua/CARTAvis/statuses/{sha}","languages_url":"https://api.github.com/repos/Astroua/CARTAvis/languages","stargazers_url":"https://api.github.com/repos/Astroua/CARTAvis/stargazers","contributors_url":"https://api.github.com/repos/Astroua/CARTAvis/contributors","subscribers_url":"https://api.github.com/repos/Astroua/CARTAvis/subscribers","subscription_url":"https://api.github.com/repos/Astroua/CARTAvis/subscription","commits_url":"https://api.github.com/repos/Astroua/CARTAvis/commits{/sha}","git_commits_url":"https://api.github.com/repos/Astroua/CARTAvis/git/commits{/sha}","comments_url":"https://api.github.com/repos/Astroua/CARTAvis/comments{/number}","issue_comment_url":"https://api.github.com/repos/Astroua/CARTAvis/issues/comments{/number}","contents_url":"https://api.github.com/repos/Astroua/CARTAvis/contents/{+path}","compare_url":"https://api.github.com/repos/Astroua/CARTAvis/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Astroua/CARTAvis/merges","archive_url":"https://api.github.com/repos/Astroua/CARTAvis/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Astroua/CARTAvis/downloads","issues_url":"https://api.github.com/repos/Astroua/CARTAvis/issues{/number}","pulls_url":"https://api.github.com/repos/Astroua/CARTAvis/pulls{/number}","milestones_url":"https://api.github.com/repos/Astroua/CARTAvis/milestones{/number}","notifications_url":"https://api.github.com/repos/Astroua/CARTAvis/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Astroua/CARTAvis/labels{/name}","releases_url":"https://api.github.com/repos/Astroua/CARTAvis/releases{/id}","deployments_url":"https://api.github.com/repos/Astroua/CARTAvis/deployments","created_at":"2014-02-07T19:05:39Z","updated_at":"2016-11-07T08:39:07Z","pushed_at":"2016-11-10T10:57:27Z","git_url":"git://github.com/Astroua/CARTAvis.git","ssh_url":"git@github.com:Astroua/CARTAvis.git","clone_url":"https://github.com/Astroua/CARTAvis.git","svn_url":"https://github.com/Astroua/CARTAvis","homepage":null,"size":25347,"stargazers_count":2,"watchers_count":2,"language":"C++","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":false,"forks_count":8,"mirror_url":null,"open_issues_count":33,"forks":8,"open_issues":33,"watchers":2,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Astroua/CARTAvis/pulls/194"},"html":{"href":"https://github.com/Astroua/CARTAvis/pull/194"},"issue":{"href":"https://api.github.com/repos/Astroua/CARTAvis/issues/194"},"comments":{"href":"https://api.github.com/repos/Astroua/CARTAvis/issues/194/comments"},"review_comments":{"href":"https://api.github.com/repos/Astroua/CARTAvis/pulls/194/comments"},"review_comment":{"href":"https://api.github.com/repos/Astroua/CARTAvis/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Astroua/CARTAvis/pulls/194/commits"},"statuses":{"href":"https://api.github.com/repos/Astroua/CARTAvis/statuses/82888d52ef04d0feee63ce915518d1148b5cadf5"}},"merged":false,"mergeable":true,"mergeable_state":"clean","merged_by":null,"comments":4,"review_comments":4,"commits":33,"additions":47,"deletions":56,"changed_files":2}}
{"actor":{"display_login":"low-sky"}}