Title: font_manager.py takes multiple seconds to import · Issue #4756 · matplotlib/matplotlib · GitHub
Open Graph Title: font_manager.py takes multiple seconds to import · Issue #4756 · matplotlib/matplotlib
X Title: font_manager.py takes multiple seconds to import · Issue #4756 · matplotlib/matplotlib
Description: This is brutal amount of latency when trying to provide a smooth user experience from an application that uses matplotlib internally. In [1]: %prun -r -s cumtime -l 20 import matplotlib.pyplot ncalls tottime percall cumtime percall filen...
Open Graph Description: This is brutal amount of latency when trying to provide a smooth user experience from an application that uses matplotlib internally. In [1]: %prun -r -s cumtime -l 20 import matplotlib.pyplot ncal...
X Description: This is brutal amount of latency when trying to provide a smooth user experience from an application that uses matplotlib internally. In [1]: %prun -r -s cumtime -l 20 import matplotlib.pyplot ncal...
Opengraph URL: https://github.com/matplotlib/matplotlib/issues/4756
X: @github
Domain: github.com
{"@context":"https://schema.org","@type":"DiscussionForumPosting","headline":"font_manager.py takes multiple seconds to import","articleBody":"This is brutal amount of latency when trying to provide a smooth user experience from an application that uses matplotlib internally.\n\n```\nIn [1]: %prun -r -s cumtime -l 20 import matplotlib.pyplot\n\nncalls tottime percall cumtime percall filename:lineno(function)\n 1 0.002 0.002 2.461 2.461 \u003cstring\u003e:1(\u003cmodule\u003e)\n 1 0.001 0.001 2.413 2.413 pyplot.py:17(\u003cmodule\u003e)\n 1 0.001 0.001 2.392 2.392 colorbar.py:20(\u003cmodule\u003e)\n 1 0.001 0.001 2.380 2.380 collections.py:10(\u003cmodule\u003e)\n 1 0.002 0.002 2.374 2.374 backend_bases.py:28(\u003cmodule\u003e)\n 1 0.001 0.001 2.365 2.365 textpath.py:3(\u003cmodule\u003e)\n 1 0.001 0.001 2.362 2.362 font_manager.py:21(\u003cmodule\u003e)\n 1 0.000 0.000 2.361 2.361 font_manager.py:952(pickle_load)\n 1 0.003 0.003 2.361 2.361 {cPickle.load}\n 1 0.001 0.001 2.358 2.358 font_manager.py:1013(__init__)\n 2 0.098 0.049 2.275 1.137 font_manager.py:544(createFontList)\n 215 0.000 0.000 2.149 0.010 afm.py:341(__init__)\n 215 0.001 0.000 2.148 0.010 afm.py:323(parse_afm)\n 215 0.001 0.000 1.443 0.007 afm.py:292(_parse_optional)\n 182 0.979 0.005 1.434 0.008 afm.py:220(_parse_kern_pairs)\n 215 0.374 0.002 0.690 0.003 afm.py:180(_parse_char_metrics)\n 1298020 0.229 0.000 0.229 0.000 {method 'split' of 'str' objects}\n 839978 0.157 0.000 0.157 0.000 {method 'readline' of 'file' objects}\n 114276 0.087 0.000 0.107 0.000 afm.py:72(_to_list_of_floats)\n 843180 0.092 0.000 0.092 0.000 {method 'startswith' of 'str' objects}\n 4 0.000 0.000 0.082 0.021 font_manager.py:294(findSystemFonts)q\n```\n","author":{"url":"https://github.com/ssanderson","@type":"Person","name":"ssanderson"},"datePublished":"2015-07-22T14:46:14.000Z","interactionStatistic":{"@type":"InteractionCounter","interactionType":"https://schema.org/CommentAction","userInteractionCount":11},"url":"https://github.com/4756/matplotlib/issues/4756"}
| route-pattern | /_view_fragments/issues/show/:user_id/:repository/:id/issue_layout(.:format) |
| route-controller | voltron_issues_fragments |
| route-action | issue_layout |
| fetch-nonce | v2:da43faed-3329-738d-c14b-894fe913061a |
| current-catalog-service-hash | 81bb79d38c15960b92d99bca9288a9108c7a47b18f2423d0f6438c5b7bcd2114 |
| request-id | EE08:21831D:16EBE10:1E344A3:6A51C40D |
| html-safe-nonce | 88e47d90f78ad29ebc0dcf4cb7ea3ff5985b7b06eae212497765c1a105ffda90 |
| visitor-payload | eyJyZWZlcnJlciI6IiIsInJlcXVlc3RfaWQiOiJFRTA4OjIxODMxRDoxNkVCRTEwOjFFMzQ0QTM6NkE1MUM0MEQiLCJ2aXNpdG9yX2lkIjoiMjUyMzY1MjY1MjM5MjM2NzExNyIsInJlZ2lvbl9lZGdlIjoiaWFkIiwicmVnaW9uX3JlbmRlciI6ImlhZCJ9 |
| visitor-hmac | 0a8f8483532c333708ce56fe7bacfe448bc7e55dee854357b1a5ff5639f0f092 |
| hovercard-subject-tag | issue:96585786 |
| github-keyboard-shortcuts | repository,issues,copilot |
| google-site-verification | Apib7-x98H0j5cPqHWwSMm6dNU4GmODRoqxLiDzdx9I |
| octolytics-url | https://collector.github.com/github/collect |
| analytics-location | / |
| fb:app_id | 1401488693436528 |
| apple-itunes-app | app-id=1477376905, app-argument=https://github.com/_view_fragments/issues/show/matplotlib/matplotlib/4756/issue_layout |
| twitter:image | https://opengraph.githubassets.com/e5bf7afe516fdc1b8f57ef94722d7e27d620807dc3d62e79beb882652553ff82/matplotlib/matplotlib/issues/4756 |
| twitter:card | summary_large_image |
| og:image | https://opengraph.githubassets.com/e5bf7afe516fdc1b8f57ef94722d7e27d620807dc3d62e79beb882652553ff82/matplotlib/matplotlib/issues/4756 |
| og:image:alt | This is brutal amount of latency when trying to provide a smooth user experience from an application that uses matplotlib internally. In [1]: %prun -r -s cumtime -l 20 import matplotlib.pyplot ncal... |
| og:image:width | 1200 |
| og:image:height | 600 |
| og:site_name | GitHub |
| og:type | object |
| og:author:username | ssanderson |
| hostname | github.com |
| expected-hostname | github.com |
| None | b9a586c06a05a7a86fc7e3f4dbd03e42f6869085879aa184aa6369456dbd50fb |
| turbo-cache-control | no-preview |
| go-import | github.com/matplotlib/matplotlib git https://github.com/matplotlib/matplotlib.git |
| octolytics-dimension-user_id | 215947 |
| octolytics-dimension-user_login | matplotlib |
| octolytics-dimension-repository_id | 1385122 |
| octolytics-dimension-repository_nwo | matplotlib/matplotlib |
| octolytics-dimension-repository_public | true |
| octolytics-dimension-repository_is_fork | false |
| octolytics-dimension-repository_network_root_id | 1385122 |
| octolytics-dimension-repository_network_root_nwo | matplotlib/matplotlib |
| turbo-body-classes | logged-out env-production page-responsive |
| disable-turbo | false |
| browser-stats-url | https://api.github.com/_private/browser/stats |
| browser-errors-url | https://api.github.com/_private/browser/errors |
| release | 7aed05249554b889eb33d002851a973eebcc7e91 |
| ui-target | full |
| theme-color | #1e2327 |
| color-scheme | light dark |
Links:
Viewport: width=device-width