{"action":"created","issue":{"url":"https://api.github.com/repos/ContinuumIO/anaconda-issues/issues/479","labels_url":"https://api.github.com/repos/ContinuumIO/anaconda-issues/issues/479/labels{/name}","comments_url":"https://api.github.com/repos/ContinuumIO/anaconda-issues/issues/479/comments","events_url":"https://api.github.com/repos/ContinuumIO/anaconda-issues/issues/479/events","html_url":"https://github.com/ContinuumIO/anaconda-issues/issues/479","id":111867401,"number":479,"title":"Scipy sph_harm miscompilation","user":{"login":"Eric89GXL","id":2365790,"avatar_url":"https://avatars.githubusercontent.com/u/2365790?v=3","gravatar_id":"","url":"https://api.github.com/users/Eric89GXL","html_url":"https://github.com/Eric89GXL","followers_url":"https://api.github.com/users/Eric89GXL/followers","following_url":"https://api.github.com/users/Eric89GXL/following{/other_user}","gists_url":"https://api.github.com/users/Eric89GXL/gists{/gist_id}","starred_url":"https://api.github.com/users/Eric89GXL/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Eric89GXL/subscriptions","organizations_url":"https://api.github.com/users/Eric89GXL/orgs","repos_url":"https://api.github.com/users/Eric89GXL/repos","events_url":"https://api.github.com/users/Eric89GXL/events{/privacy}","received_events_url":"https://api.github.com/users/Eric89GXL/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":1,"created_at":"2015-10-16T16:40:50Z","updated_at":"2015-10-16T16:41:20Z","closed_at":null,"body":"I found an inconsistency in sph_harm, but it appears on Linux 64-bit Python 3.4 (e.g., on Anaconda scipy=0.16 or scipy=0.15) but not on Python 2.7 with equivalent numpy/scipy versions. Running this command in a Python 3.4 Anaconda virtual environment I get:\r\n\r\n```\r\n$ python -c \"from scipy.special import sph_harm; print(sph_harm(1, 1, 1., 1.))\"\r\n(-0.290723302201-2.02129965364e-310j)\r\n```\r\nBut the correct result is what I get on Python 2.7:\r\n```\r\n(-0.157078470549-0.24463522341j)\r\n```\r\nIt does work on my system Python3 when using the Ubuntu-packaged scipy 0.14.1, or when I build scipy myself, latest master with MKL or maintenance/0.16.x using system BLAS.\r\n\r\nThe scipy devs told me that:\r\n\r\n\"Whatever compiler they are using has miscompiled the Cython-generated routine __pyx_f_5scipy_7special_8sph_harm_sph_harmonic so that it returns the wrong value.\"\r\n\r\nSee:\r\n\r\nhttps://github.com/scipy/scipy/issues/5376"},"comment":{"url":"https://api.github.com/repos/ContinuumIO/anaconda-issues/issues/comments/148764287","html_url":"https://github.com/ContinuumIO/anaconda-issues/issues/479#issuecomment-148764287","issue_url":"https://api.github.com/repos/ContinuumIO/anaconda-issues/issues/479","id":148764287,"user":{"login":"Eric89GXL","id":2365790,"avatar_url":"https://avatars.githubusercontent.com/u/2365790?v=3","gravatar_id":"","url":"https://api.github.com/users/Eric89GXL","html_url":"https://github.com/Eric89GXL","followers_url":"https://api.github.com/users/Eric89GXL/followers","following_url":"https://api.github.com/users/Eric89GXL/following{/other_user}","gists_url":"https://api.github.com/users/Eric89GXL/gists{/gist_id}","starred_url":"https://api.github.com/users/Eric89GXL/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Eric89GXL/subscriptions","organizations_url":"https://api.github.com/users/Eric89GXL/orgs","repos_url":"https://api.github.com/users/Eric89GXL/repos","events_url":"https://api.github.com/users/Eric89GXL/events{/privacy}","received_events_url":"https://api.github.com/users/Eric89GXL/received_events","type":"User","site_admin":false},"created_at":"2015-10-16T16:41:20Z","updated_at":"2015-10-16T16:41:20Z","body":"Notably, this happens both on Ubuntu 15.04 that I am running, and on Travis-CI Ubuntu 12.04 builds (where I originally saw the problem)."}}