{"action":"created","issue":{"url":"https://api.github.com/repos/numpy/numpy/issues/4280","repository_url":"https://api.github.com/repos/numpy/numpy","labels_url":"https://api.github.com/repos/numpy/numpy/issues/4280/labels{/name}","comments_url":"https://api.github.com/repos/numpy/numpy/issues/4280/comments","events_url":"https://api.github.com/repos/numpy/numpy/issues/4280/events","html_url":"https://github.com/numpy/numpy/issues/4280","id":27397114,"number":4280,"title":"maybe a problem with matrix_rank","user":{"login":"argriffing","id":101416,"avatar_url":"https://avatars1.githubusercontent.com/u/101416?v=4","gravatar_id":"","url":"https://api.github.com/users/argriffing","html_url":"https://github.com/argriffing","followers_url":"https://api.github.com/users/argriffing/followers","following_url":"https://api.github.com/users/argriffing/following{/other_user}","gists_url":"https://api.github.com/users/argriffing/gists{/gist_id}","starred_url":"https://api.github.com/users/argriffing/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/argriffing/subscriptions","organizations_url":"https://api.github.com/users/argriffing/orgs","repos_url":"https://api.github.com/users/argriffing/repos","events_url":"https://api.github.com/users/argriffing/events{/privacy}","received_events_url":"https://api.github.com/users/argriffing/received_events","type":"User","site_admin":false},"labels":[{"id":6359214,"url":"https://api.github.com/repos/numpy/numpy/labels/00%20-%20Bug","name":"00 - Bug","color":"fef2c0","default":false},{"id":16915566,"url":"https://api.github.com/repos/numpy/numpy/labels/component:%20numpy.linalg","name":"component: numpy.linalg","color":"009800","default":false},{"id":16915544,"url":"https://api.github.com/repos/numpy/numpy/labels/priority:%20normal","name":"priority: normal","color":"ff0000","default":false}],"state":"open","locked":false,"assignee":null,"assignees":[],"milestone":null,"comments":2,"created_at":"2014-02-11T23:31:04Z","updated_at":"2017-11-08T07:43:04Z","closed_at":null,"author_association":"CONTRIBUTOR","body":"```\n$ python\nPython 2.7.5+ (default, Sep 19 2013, 13:48:49) \n[GCC 4.8.1] on linux2\nType \"help\", \"copyright\", \"credits\" or \"license\" for more information.\n>>> import numpy as np\n>>> np.__version__\n'1.7.1'\n>>> np.linalg.matrix_rank([[1e3, 0], [0, 1]])\n2\n>>> np.linalg.matrix_rank([[1e300, 0], [0, 1]])\n1\n>>> np.linalg.matrix_rank([[1e3000, 0], [0, 1]])\n0\n```\n\nThe first and second values look reasonable but the third one looks wrong.  I think this is caused by feeding lapack a matrix with an `inf` and then returning 0 because lapack doesn't understand `inf`.  Or maybe this is not considered a numpy bug and the solution is just that I should know better than to try computing `np.linalg.matrix_rank` of a matrix with an `inf`.\n"},"comment":{"url":"https://api.github.com/repos/numpy/numpy/issues/comments/342736068","html_url":"https://github.com/numpy/numpy/issues/4280#issuecomment-342736068","issue_url":"https://api.github.com/repos/numpy/numpy/issues/4280","id":342736068,"user":{"login":"eric-wieser","id":425260,"avatar_url":"https://avatars3.githubusercontent.com/u/425260?v=4","gravatar_id":"","url":"https://api.github.com/users/eric-wieser","html_url":"https://github.com/eric-wieser","followers_url":"https://api.github.com/users/eric-wieser/followers","following_url":"https://api.github.com/users/eric-wieser/following{/other_user}","gists_url":"https://api.github.com/users/eric-wieser/gists{/gist_id}","starred_url":"https://api.github.com/users/eric-wieser/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/eric-wieser/subscriptions","organizations_url":"https://api.github.com/users/eric-wieser/orgs","repos_url":"https://api.github.com/users/eric-wieser/repos","events_url":"https://api.github.com/users/eric-wieser/events{/privacy}","received_events_url":"https://api.github.com/users/eric-wieser/received_events","type":"User","site_admin":false},"created_at":"2017-11-08T07:43:04Z","updated_at":"2017-11-08T07:43:04Z","author_association":"MEMBER","body":"If you want the theoretical rank, use `np.linalg.matrix_rank([[1e300, 0], [0, 1]], tol=0)`"}}
{"actor":{"display_login":"eric-wieser"}}