{"action":"created","issue":{"url":"https://api.github.com/repos/SheffieldML/GPy/issues/343","repository_url":"https://api.github.com/repos/SheffieldML/GPy","labels_url":"https://api.github.com/repos/SheffieldML/GPy/issues/343/labels{/name}","comments_url":"https://api.github.com/repos/SheffieldML/GPy/issues/343/comments","events_url":"https://api.github.com/repos/SheffieldML/GPy/issues/343/events","html_url":"https://github.com/SheffieldML/GPy/issues/343","id":141726633,"number":343,"title":"Feature request: support lists as data","user":{"login":"jluttine","id":2195834,"avatar_url":"https://avatars.githubusercontent.com/u/2195834?v=3","gravatar_id":"","url":"https://api.github.com/users/jluttine","html_url":"https://github.com/jluttine","followers_url":"https://api.github.com/users/jluttine/followers","following_url":"https://api.github.com/users/jluttine/following{/other_user}","gists_url":"https://api.github.com/users/jluttine/gists{/gist_id}","starred_url":"https://api.github.com/users/jluttine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jluttine/subscriptions","organizations_url":"https://api.github.com/users/jluttine/orgs","repos_url":"https://api.github.com/users/jluttine/repos","events_url":"https://api.github.com/users/jluttine/events{/privacy}","received_events_url":"https://api.github.com/users/jluttine/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2016-03-17T22:52:56Z","updated_at":"2016-03-18T05:24:27Z","closed_at":null,"body":"Very minor feature request: would it be possible to support lists as data? So that they are wrapped to NumPy arrays in the methods if necessary. For instance, I'd like this to work:\r\n```python\r\nimport GPy\r\nk = GPy.kern.RBF(input_dim=1)\r\nmod = GPy.models.GPRegression(np.random.randn(10, 1), np.random.randn(10,1), kernel=k)\r\nmod.predict([[0], [1], [2]])\r\n```\r\nBut it raises `AttributeError`."},"comment":{"url":"https://api.github.com/repos/SheffieldML/GPy/issues/comments/198213291","html_url":"https://github.com/SheffieldML/GPy/issues/343#issuecomment-198213291","issue_url":"https://api.github.com/repos/SheffieldML/GPy/issues/343","id":198213291,"user":{"login":"jluttine","id":2195834,"avatar_url":"https://avatars.githubusercontent.com/u/2195834?v=3","gravatar_id":"","url":"https://api.github.com/users/jluttine","html_url":"https://github.com/jluttine","followers_url":"https://api.github.com/users/jluttine/followers","following_url":"https://api.github.com/users/jluttine/following{/other_user}","gists_url":"https://api.github.com/users/jluttine/gists{/gist_id}","starred_url":"https://api.github.com/users/jluttine/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/jluttine/subscriptions","organizations_url":"https://api.github.com/users/jluttine/orgs","repos_url":"https://api.github.com/users/jluttine/repos","events_url":"https://api.github.com/users/jluttine/events{/privacy}","received_events_url":"https://api.github.com/users/jluttine/received_events","type":"User","site_admin":false},"created_at":"2016-03-18T05:24:27Z","updated_at":"2016-03-18T05:24:27Z","body":"@mzwiessele Sorry, I didn't quite understand your explanation. NumPy itself supports arrays/matrices as lists in all its functions. For instance, you can do `np.linalg.svd([[1, 2, 3], [4, 5, 6]])`. It means simply a call `data = np.asanyarray(data)` at the beginning of the functions that are facing the user directly. It is simple as that, nothing else needs to change, nothing new needs to be supported. It doesn't mean that data is given as one dimensional vectors or that dimensionalities are somehow lost. I just think that it is consistent in the NumPy/SciPy world to support arrays as lists without forcing the user to write explicitly `np.array(...)` around the data array he/she has written as a (nested) list.\r\n\r\nThe point of this feature request is to make the user interface just a little bit more polished and consistent with other NumPy/SciPy world user interfaces. It is a very minor matter but also extremely simple and straightforward to implement. But yes, I do understand if you feel that it still isn't worth any efforts. But I'd consider this as a low priority small task that could be implemented if someone just has a little bit of extra time. I might have some myself at some point for that matter.\r\n\r\nBut thanks for the feedback!"}}