{"action":"created","issue":{"url":"https://api.github.com/repos/tqdm/tqdm/issues/21","labels_url":"https://api.github.com/repos/tqdm/tqdm/issues/21/labels{/name}","comments_url":"https://api.github.com/repos/tqdm/tqdm/issues/21/comments","events_url":"https://api.github.com/repos/tqdm/tqdm/issues/21/events","html_url":"https://github.com/tqdm/tqdm/issues/21","id":94524293,"number":21,"title":"New string formatting speed issues","user":{"login":"lrq3000","id":1118942,"avatar_url":"https://avatars.githubusercontent.com/u/1118942?v=3","gravatar_id":"","url":"https://api.github.com/users/lrq3000","html_url":"https://github.com/lrq3000","followers_url":"https://api.github.com/users/lrq3000/followers","following_url":"https://api.github.com/users/lrq3000/following{/other_user}","gists_url":"https://api.github.com/users/lrq3000/gists{/gist_id}","starred_url":"https://api.github.com/users/lrq3000/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lrq3000/subscriptions","organizations_url":"https://api.github.com/users/lrq3000/orgs","repos_url":"https://api.github.com/users/lrq3000/repos","events_url":"https://api.github.com/users/lrq3000/events{/privacy}","received_events_url":"https://api.github.com/users/lrq3000/received_events","type":"User","site_admin":false},"labels":[],"state":"open","locked":false,"assignee":null,"milestone":null,"comments":5,"created_at":"2015-07-12T02:02:23Z","updated_at":"2015-07-13T11:17:39Z","closed_at":null,"body":"Hi there,\r\n\r\nI noted that the previous string formatting, like:\r\n\r\n    '%5.2f' % (n / elapsed)\r\n\r\nWas systematically changed to:\r\n\r\n    '{0:5.2f}'.format(float(n) / elapsed)\r\n\r\nHowever, this is about 2x slower than the old string formatting. Is there any reason to keep using the new formatting style?"},"comment":{"url":"https://api.github.com/repos/tqdm/tqdm/issues/comments/120893688","html_url":"https://github.com/tqdm/tqdm/issues/21#issuecomment-120893688","issue_url":"https://api.github.com/repos/tqdm/tqdm/issues/21","id":120893688,"user":{"login":"lrq3000","id":1118942,"avatar_url":"https://avatars.githubusercontent.com/u/1118942?v=3","gravatar_id":"","url":"https://api.github.com/users/lrq3000","html_url":"https://github.com/lrq3000","followers_url":"https://api.github.com/users/lrq3000/followers","following_url":"https://api.github.com/users/lrq3000/following{/other_user}","gists_url":"https://api.github.com/users/lrq3000/gists{/gist_id}","starred_url":"https://api.github.com/users/lrq3000/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/lrq3000/subscriptions","organizations_url":"https://api.github.com/users/lrq3000/orgs","repos_url":"https://api.github.com/users/lrq3000/repos","events_url":"https://api.github.com/users/lrq3000/events{/privacy}","received_events_url":"https://api.github.com/users/lrq3000/received_events","type":"User","site_admin":false},"created_at":"2015-07-13T11:17:39Z","updated_at":"2015-07-13T11:17:39Z","body":"Ok, good for me, thank you very much for having benchmarked that :)\n\n2015-07-13 12:29 GMT+02:00 Casper da Costa-Luis <notifications@github.com>:\n\n> Further clarification: after some rather more strenuous testing/profiling\n> I can confirm that there is a slight measurable effect. However, the main\n> bottleneck is still calls to time.time (I did my best to reduce these\n> with \"clever\" dynamic values for miniters/mininterval). An order of\n> magnitude less of a bottleneck is the format_meter function.\n>\n> I don't think it's worth reverting - the current implementation is a lot\n> easier to read and extend. It is recommended formatting after all.\n>\n> —\n> Reply to this email directly or view it on GitHub\n> <https://github.com/tqdm/tqdm/issues/21#issuecomment-120886532>.\n>\n"}}