{"action":"opened","issue":{"url":"https://api.github.com/repos/ngageoint/mrgeo/issues/174","labels_url":"https://api.github.com/repos/ngageoint/mrgeo/issues/174/labels{/name}","comments_url":"https://api.github.com/repos/ngageoint/mrgeo/issues/174/comments","events_url":"https://api.github.com/repos/ngageoint/mrgeo/issues/174/events","html_url":"https://github.com/ngageoint/mrgeo/issues/174","id":125455706,"number":174,"title":"Change for loops to while loops for performance","user":{"login":"djohnson729","id":7021622,"avatar_url":"https://avatars.githubusercontent.com/u/7021622?v=3","gravatar_id":"","url":"https://api.github.com/users/djohnson729","html_url":"https://github.com/djohnson729","followers_url":"https://api.github.com/users/djohnson729/followers","following_url":"https://api.github.com/users/djohnson729/following{/other_user}","gists_url":"https://api.github.com/users/djohnson729/gists{/gist_id}","starred_url":"https://api.github.com/users/djohnson729/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/djohnson729/subscriptions","organizations_url":"https://api.github.com/users/djohnson729/orgs","repos_url":"https://api.github.com/users/djohnson729/repos","events_url":"https://api.github.com/users/djohnson729/events{/privacy}","received_events_url":"https://api.github.com/users/djohnson729/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":0,"created_at":"2016-01-07T18:22:17Z","updated_at":"2016-01-07T18:22:17Z","closed_at":null,"body":"In scala, when looping over a set of integers, like 0 .. 100, using the scala \"for\" construct like \"for (i <- 0 until 100)\" is significantly slower than using a while loop.\r\n\r\nWe need to look through MrGeo code for \"for\" loop usage and change over to while loops when they are simple numeric loops as noted above. This is especially important inside of RDD \"map\" functionality (such as when looping over rasters inside of map algebra functions).\r\n"}}