相关疑难解决方法(0)

Google Colaboratory matplotlib 图表中的自定义字体

在本地使用 matplotlib 中的自定义字体涉及将.ttfs存储在matplotlib/mpl-data/fonts/ttf/文件夹中,然后调用mpl.font_manager._rebuild(),然后设置mpl.rcParams['font.sans-serif']

有没有办法在 Google Colaboratory 中执行此操作,但似乎无法ttf访问此文件夹?

例如,我想使用Roboto 字体。安装后,这将使用mpl.rcParams['font.sans-serif'] = 'Roboto'.

fonts matplotlib google-colaboratory

3
推荐指数
1
解决办法
4404
查看次数

标签 统计

fonts ×1

google-colaboratory ×1

matplotlib ×1