{"action":"created","comment":{"url":"https://api.github.com/repos/Mindwerks/worldengine/pulls/comments/45368182","id":45368182,"diff_hunk":"@@ -693,7 +696,7 @@ def draw_scatter_plot(world, size, target):\n         for x in range(world.width):\n             if world.is_land((x, y)):\n                 t = world.temperature_at((x, y))\n-                p = world.humidity['data'][y, x]\n+                p = world.humidity_at((x, y))","path":"worldengine/draw.py","position":214,"original_position":214,"commit_id":"c53873e277b88b8a9f6516609cb2a4a45a4e034d","original_commit_id":"c53873e277b88b8a9f6516609cb2a4a45a4e034d","user":{"login":"ftomassetti","id":439078,"avatar_url":"https://avatars.githubusercontent.com/u/439078?v=3","gravatar_id":"","url":"https://api.github.com/users/ftomassetti","html_url":"https://github.com/ftomassetti","followers_url":"https://api.github.com/users/ftomassetti/followers","following_url":"https://api.github.com/users/ftomassetti/following{/other_user}","gists_url":"https://api.github.com/users/ftomassetti/gists{/gist_id}","starred_url":"https://api.github.com/users/ftomassetti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ftomassetti/subscriptions","organizations_url":"https://api.github.com/users/ftomassetti/orgs","repos_url":"https://api.github.com/users/ftomassetti/repos","events_url":"https://api.github.com/users/ftomassetti/events{/privacy}","received_events_url":"https://api.github.com/users/ftomassetti/received_events","type":"User","site_admin":false},"body":"for me it is not about being pretty or not but it is about maintanability through encapsulation: if the latter one was used this patch would be like ten times smaller because we could have changed the way we keep data without affecting the whole codebase. I agree that it could cause a performance hit but in the cases where it is strictly needed we can access directly the array. In many cases we could use numpy functions instead of accessing single values.","created_at":"2015-11-19T16:59:15Z","updated_at":"2015-11-19T16:59:15Z","html_url":"https://github.com/Mindwerks/worldengine/pull/207#discussion_r45368182","pull_request_url":"https://api.github.com/repos/Mindwerks/worldengine/pulls/207","_links":{"self":{"href":"https://api.github.com/repos/Mindwerks/worldengine/pulls/comments/45368182"},"html":{"href":"https://github.com/Mindwerks/worldengine/pull/207#discussion_r45368182"},"pull_request":{"href":"https://api.github.com/repos/Mindwerks/worldengine/pulls/207"}}},"pull_request":{"url":"https://api.github.com/repos/Mindwerks/worldengine/pulls/207","id":51233512,"html_url":"https://github.com/Mindwerks/worldengine/pull/207","diff_url":"https://github.com/Mindwerks/worldengine/pull/207.diff","patch_url":"https://github.com/Mindwerks/worldengine/pull/207.patch","issue_url":"https://api.github.com/repos/Mindwerks/worldengine/issues/207","number":207,"state":"open","locked":false,"title":"Reorganize World","user":{"login":"ftomassetti","id":439078,"avatar_url":"https://avatars.githubusercontent.com/u/439078?v=3","gravatar_id":"","url":"https://api.github.com/users/ftomassetti","html_url":"https://github.com/ftomassetti","followers_url":"https://api.github.com/users/ftomassetti/followers","following_url":"https://api.github.com/users/ftomassetti/following{/other_user}","gists_url":"https://api.github.com/users/ftomassetti/gists{/gist_id}","starred_url":"https://api.github.com/users/ftomassetti/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/ftomassetti/subscriptions","organizations_url":"https://api.github.com/users/ftomassetti/orgs","repos_url":"https://api.github.com/users/ftomassetti/repos","events_url":"https://api.github.com/users/ftomassetti/events{/privacy}","received_events_url":"https://api.github.com/users/ftomassetti/received_events","type":"User","site_admin":false},"body":"This is an initial step to reorganize the World class. Other refactoring will follow but I thought it would be better to start discussing and merging this one.\r\n\r\nNow most of data is grouped either under generation_params or in layers.\r\n\r\nA Layer represent a piece of information available for each cell. Each layer has a matrix of data, some of them have also thresholds while others have quantiles.\r\n\r\nThe idea is to treat layers in the more homogeneous way possible. ","created_at":"2015-11-19T15:04:58Z","updated_at":"2015-11-19T16:59:15Z","closed_at":null,"merged_at":null,"merge_commit_sha":"6b572d4cbe6848413bc58f91d052a384bc145381","assignee":null,"milestone":null,"commits_url":"https://api.github.com/repos/Mindwerks/worldengine/pulls/207/commits","review_comments_url":"https://api.github.com/repos/Mindwerks/worldengine/pulls/207/comments","review_comment_url":"https://api.github.com/repos/Mindwerks/worldengine/pulls/comments{/number}","comments_url":"https://api.github.com/repos/Mindwerks/worldengine/issues/207/comments","statuses_url":"https://api.github.com/repos/Mindwerks/worldengine/statuses/c53873e277b88b8a9f6516609cb2a4a45a4e034d","head":{"label":"Mindwerks:model_organization","ref":"model_organization","sha":"c53873e277b88b8a9f6516609cb2a4a45a4e034d","user":{"login":"Mindwerks","id":6725881,"avatar_url":"https://avatars.githubusercontent.com/u/6725881?v=3","gravatar_id":"","url":"https://api.github.com/users/Mindwerks","html_url":"https://github.com/Mindwerks","followers_url":"https://api.github.com/users/Mindwerks/followers","following_url":"https://api.github.com/users/Mindwerks/following{/other_user}","gists_url":"https://api.github.com/users/Mindwerks/gists{/gist_id}","starred_url":"https://api.github.com/users/Mindwerks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mindwerks/subscriptions","organizations_url":"https://api.github.com/users/Mindwerks/orgs","repos_url":"https://api.github.com/users/Mindwerks/repos","events_url":"https://api.github.com/users/Mindwerks/events{/privacy}","received_events_url":"https://api.github.com/users/Mindwerks/received_events","type":"Organization","site_admin":false},"repo":{"id":14665885,"name":"worldengine","full_name":"Mindwerks/worldengine","owner":{"login":"Mindwerks","id":6725881,"avatar_url":"https://avatars.githubusercontent.com/u/6725881?v=3","gravatar_id":"","url":"https://api.github.com/users/Mindwerks","html_url":"https://github.com/Mindwerks","followers_url":"https://api.github.com/users/Mindwerks/followers","following_url":"https://api.github.com/users/Mindwerks/following{/other_user}","gists_url":"https://api.github.com/users/Mindwerks/gists{/gist_id}","starred_url":"https://api.github.com/users/Mindwerks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mindwerks/subscriptions","organizations_url":"https://api.github.com/users/Mindwerks/orgs","repos_url":"https://api.github.com/users/Mindwerks/repos","events_url":"https://api.github.com/users/Mindwerks/events{/privacy}","received_events_url":"https://api.github.com/users/Mindwerks/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Mindwerks/worldengine","description":"World generator using simulation of plates, rain shadow, erosion, etc.","fork":false,"url":"https://api.github.com/repos/Mindwerks/worldengine","forks_url":"https://api.github.com/repos/Mindwerks/worldengine/forks","keys_url":"https://api.github.com/repos/Mindwerks/worldengine/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Mindwerks/worldengine/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Mindwerks/worldengine/teams","hooks_url":"https://api.github.com/repos/Mindwerks/worldengine/hooks","issue_events_url":"https://api.github.com/repos/Mindwerks/worldengine/issues/events{/number}","events_url":"https://api.github.com/repos/Mindwerks/worldengine/events","assignees_url":"https://api.github.com/repos/Mindwerks/worldengine/assignees{/user}","branches_url":"https://api.github.com/repos/Mindwerks/worldengine/branches{/branch}","tags_url":"https://api.github.com/repos/Mindwerks/worldengine/tags","blobs_url":"https://api.github.com/repos/Mindwerks/worldengine/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Mindwerks/worldengine/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Mindwerks/worldengine/git/refs{/sha}","trees_url":"https://api.github.com/repos/Mindwerks/worldengine/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Mindwerks/worldengine/statuses/{sha}","languages_url":"https://api.github.com/repos/Mindwerks/worldengine/languages","stargazers_url":"https://api.github.com/repos/Mindwerks/worldengine/stargazers","contributors_url":"https://api.github.com/repos/Mindwerks/worldengine/contributors","subscribers_url":"https://api.github.com/repos/Mindwerks/worldengine/subscribers","subscription_url":"https://api.github.com/repos/Mindwerks/worldengine/subscription","commits_url":"https://api.github.com/repos/Mindwerks/worldengine/commits{/sha}","git_commits_url":"https://api.github.com/repos/Mindwerks/worldengine/git/commits{/sha}","comments_url":"https://api.github.com/repos/Mindwerks/worldengine/comments{/number}","issue_comment_url":"https://api.github.com/repos/Mindwerks/worldengine/issues/comments{/number}","contents_url":"https://api.github.com/repos/Mindwerks/worldengine/contents/{+path}","compare_url":"https://api.github.com/repos/Mindwerks/worldengine/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Mindwerks/worldengine/merges","archive_url":"https://api.github.com/repos/Mindwerks/worldengine/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Mindwerks/worldengine/downloads","issues_url":"https://api.github.com/repos/Mindwerks/worldengine/issues{/number}","pulls_url":"https://api.github.com/repos/Mindwerks/worldengine/pulls{/number}","milestones_url":"https://api.github.com/repos/Mindwerks/worldengine/milestones{/number}","notifications_url":"https://api.github.com/repos/Mindwerks/worldengine/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Mindwerks/worldengine/labels{/name}","releases_url":"https://api.github.com/repos/Mindwerks/worldengine/releases{/id}","created_at":"2013-11-24T17:49:35Z","updated_at":"2015-11-19T11:47:52Z","pushed_at":"2015-11-19T16:29:36Z","git_url":"git://github.com/Mindwerks/worldengine.git","ssh_url":"git@github.com:Mindwerks/worldengine.git","clone_url":"https://github.com/Mindwerks/worldengine.git","svn_url":"https://github.com/Mindwerks/worldengine","homepage":"","size":84893,"stargazers_count":349,"watchers_count":349,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":26,"mirror_url":null,"open_issues_count":36,"forks":26,"open_issues":36,"watchers":349,"default_branch":"master"}},"base":{"label":"Mindwerks:master","ref":"master","sha":"b67e5668066e5c5044a75b8193c4e1e82f285435","user":{"login":"Mindwerks","id":6725881,"avatar_url":"https://avatars.githubusercontent.com/u/6725881?v=3","gravatar_id":"","url":"https://api.github.com/users/Mindwerks","html_url":"https://github.com/Mindwerks","followers_url":"https://api.github.com/users/Mindwerks/followers","following_url":"https://api.github.com/users/Mindwerks/following{/other_user}","gists_url":"https://api.github.com/users/Mindwerks/gists{/gist_id}","starred_url":"https://api.github.com/users/Mindwerks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mindwerks/subscriptions","organizations_url":"https://api.github.com/users/Mindwerks/orgs","repos_url":"https://api.github.com/users/Mindwerks/repos","events_url":"https://api.github.com/users/Mindwerks/events{/privacy}","received_events_url":"https://api.github.com/users/Mindwerks/received_events","type":"Organization","site_admin":false},"repo":{"id":14665885,"name":"worldengine","full_name":"Mindwerks/worldengine","owner":{"login":"Mindwerks","id":6725881,"avatar_url":"https://avatars.githubusercontent.com/u/6725881?v=3","gravatar_id":"","url":"https://api.github.com/users/Mindwerks","html_url":"https://github.com/Mindwerks","followers_url":"https://api.github.com/users/Mindwerks/followers","following_url":"https://api.github.com/users/Mindwerks/following{/other_user}","gists_url":"https://api.github.com/users/Mindwerks/gists{/gist_id}","starred_url":"https://api.github.com/users/Mindwerks/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/Mindwerks/subscriptions","organizations_url":"https://api.github.com/users/Mindwerks/orgs","repos_url":"https://api.github.com/users/Mindwerks/repos","events_url":"https://api.github.com/users/Mindwerks/events{/privacy}","received_events_url":"https://api.github.com/users/Mindwerks/received_events","type":"Organization","site_admin":false},"private":false,"html_url":"https://github.com/Mindwerks/worldengine","description":"World generator using simulation of plates, rain shadow, erosion, etc.","fork":false,"url":"https://api.github.com/repos/Mindwerks/worldengine","forks_url":"https://api.github.com/repos/Mindwerks/worldengine/forks","keys_url":"https://api.github.com/repos/Mindwerks/worldengine/keys{/key_id}","collaborators_url":"https://api.github.com/repos/Mindwerks/worldengine/collaborators{/collaborator}","teams_url":"https://api.github.com/repos/Mindwerks/worldengine/teams","hooks_url":"https://api.github.com/repos/Mindwerks/worldengine/hooks","issue_events_url":"https://api.github.com/repos/Mindwerks/worldengine/issues/events{/number}","events_url":"https://api.github.com/repos/Mindwerks/worldengine/events","assignees_url":"https://api.github.com/repos/Mindwerks/worldengine/assignees{/user}","branches_url":"https://api.github.com/repos/Mindwerks/worldengine/branches{/branch}","tags_url":"https://api.github.com/repos/Mindwerks/worldengine/tags","blobs_url":"https://api.github.com/repos/Mindwerks/worldengine/git/blobs{/sha}","git_tags_url":"https://api.github.com/repos/Mindwerks/worldengine/git/tags{/sha}","git_refs_url":"https://api.github.com/repos/Mindwerks/worldengine/git/refs{/sha}","trees_url":"https://api.github.com/repos/Mindwerks/worldengine/git/trees{/sha}","statuses_url":"https://api.github.com/repos/Mindwerks/worldengine/statuses/{sha}","languages_url":"https://api.github.com/repos/Mindwerks/worldengine/languages","stargazers_url":"https://api.github.com/repos/Mindwerks/worldengine/stargazers","contributors_url":"https://api.github.com/repos/Mindwerks/worldengine/contributors","subscribers_url":"https://api.github.com/repos/Mindwerks/worldengine/subscribers","subscription_url":"https://api.github.com/repos/Mindwerks/worldengine/subscription","commits_url":"https://api.github.com/repos/Mindwerks/worldengine/commits{/sha}","git_commits_url":"https://api.github.com/repos/Mindwerks/worldengine/git/commits{/sha}","comments_url":"https://api.github.com/repos/Mindwerks/worldengine/comments{/number}","issue_comment_url":"https://api.github.com/repos/Mindwerks/worldengine/issues/comments{/number}","contents_url":"https://api.github.com/repos/Mindwerks/worldengine/contents/{+path}","compare_url":"https://api.github.com/repos/Mindwerks/worldengine/compare/{base}...{head}","merges_url":"https://api.github.com/repos/Mindwerks/worldengine/merges","archive_url":"https://api.github.com/repos/Mindwerks/worldengine/{archive_format}{/ref}","downloads_url":"https://api.github.com/repos/Mindwerks/worldengine/downloads","issues_url":"https://api.github.com/repos/Mindwerks/worldengine/issues{/number}","pulls_url":"https://api.github.com/repos/Mindwerks/worldengine/pulls{/number}","milestones_url":"https://api.github.com/repos/Mindwerks/worldengine/milestones{/number}","notifications_url":"https://api.github.com/repos/Mindwerks/worldengine/notifications{?since,all,participating}","labels_url":"https://api.github.com/repos/Mindwerks/worldengine/labels{/name}","releases_url":"https://api.github.com/repos/Mindwerks/worldengine/releases{/id}","created_at":"2013-11-24T17:49:35Z","updated_at":"2015-11-19T11:47:52Z","pushed_at":"2015-11-19T16:29:36Z","git_url":"git://github.com/Mindwerks/worldengine.git","ssh_url":"git@github.com:Mindwerks/worldengine.git","clone_url":"https://github.com/Mindwerks/worldengine.git","svn_url":"https://github.com/Mindwerks/worldengine","homepage":"","size":84893,"stargazers_count":349,"watchers_count":349,"language":"Python","has_issues":true,"has_downloads":true,"has_wiki":true,"has_pages":true,"forks_count":26,"mirror_url":null,"open_issues_count":36,"forks":26,"open_issues":36,"watchers":349,"default_branch":"master"}},"_links":{"self":{"href":"https://api.github.com/repos/Mindwerks/worldengine/pulls/207"},"html":{"href":"https://github.com/Mindwerks/worldengine/pull/207"},"issue":{"href":"https://api.github.com/repos/Mindwerks/worldengine/issues/207"},"comments":{"href":"https://api.github.com/repos/Mindwerks/worldengine/issues/207/comments"},"review_comments":{"href":"https://api.github.com/repos/Mindwerks/worldengine/pulls/207/comments"},"review_comment":{"href":"https://api.github.com/repos/Mindwerks/worldengine/pulls/comments{/number}"},"commits":{"href":"https://api.github.com/repos/Mindwerks/worldengine/pulls/207/commits"},"statuses":{"href":"https://api.github.com/repos/Mindwerks/worldengine/statuses/c53873e277b88b8a9f6516609cb2a4a45a4e034d"}}}}