{"id":1422,"date":"2019-07-10T10:56:18","date_gmt":"2019-07-10T16:56:18","guid":{"rendered":"http:\/\/jaredrobinson.com\/blog\/?p=1422"},"modified":"2019-07-10T20:19:19","modified_gmt":"2019-07-11T02:19:19","slug":"python-how-to-reduce-memory-usage","status":"publish","type":"post","link":"https:\/\/jaredrobinson.com\/blog\/python-how-to-reduce-memory-usage\/","title":{"rendered":"Python: How to reduce memory usage"},"content":{"rendered":"<p>Useful information for reducing memory usage of Python programs:<\/p>\n<ul>\n<li>https:\/\/m.habr.com\/en\/post\/458518\/<\/li>\n<li>https:\/\/stackoverflow.com\/questions\/472000\/usage-of-slots<\/li>\n<\/ul>\n<p>TLDR: Dictionaries use a lot of memory. Possible solutions include using a class and <strong>slots<\/strong>, namedtuple, recordclass, cython, or numpy.<\/p>\n","protected":false},"excerpt":{"rendered":"<p>Useful information for reducing memory usage of Python programs: https:\/\/m.habr.com\/en\/post\/458518\/ https:\/\/stackoverflow.com\/questions\/472000\/usage-of-slots TLDR: Dictionaries use a lot of memory. Possible solutions include using a class and slots, namedtuple, recordclass, cython, or numpy.<\/p>\n","protected":false},"author":1,"featured_media":0,"comment_status":"closed","ping_status":"open","sticky":false,"template":"","format":"standard","meta":{"footnotes":""},"categories":[12,17],"tags":[],"class_list":["post-1422","post","type-post","status-publish","format-standard","hentry","category-programming","category-tech"],"_links":{"self":[{"href":"https:\/\/jaredrobinson.com\/blog\/wp-json\/wp\/v2\/posts\/1422","targetHints":{"allow":["GET"]}}],"collection":[{"href":"https:\/\/jaredrobinson.com\/blog\/wp-json\/wp\/v2\/posts"}],"about":[{"href":"https:\/\/jaredrobinson.com\/blog\/wp-json\/wp\/v2\/types\/post"}],"author":[{"embeddable":true,"href":"https:\/\/jaredrobinson.com\/blog\/wp-json\/wp\/v2\/users\/1"}],"replies":[{"embeddable":true,"href":"https:\/\/jaredrobinson.com\/blog\/wp-json\/wp\/v2\/comments?post=1422"}],"version-history":[{"count":3,"href":"https:\/\/jaredrobinson.com\/blog\/wp-json\/wp\/v2\/posts\/1422\/revisions"}],"predecessor-version":[{"id":1425,"href":"https:\/\/jaredrobinson.com\/blog\/wp-json\/wp\/v2\/posts\/1422\/revisions\/1425"}],"wp:attachment":[{"href":"https:\/\/jaredrobinson.com\/blog\/wp-json\/wp\/v2\/media?parent=1422"}],"wp:term":[{"taxonomy":"category","embeddable":true,"href":"https:\/\/jaredrobinson.com\/blog\/wp-json\/wp\/v2\/categories?post=1422"},{"taxonomy":"post_tag","embeddable":true,"href":"https:\/\/jaredrobinson.com\/blog\/wp-json\/wp\/v2\/tags?post=1422"}],"curies":[{"name":"wp","href":"https:\/\/api.w.org\/{rel}","templated":true}]}}