jupyter notebook 安装字体解决可视化时字体不显示
jupyter notebook 安装中文字体解决可视化时部分字体不显示或者错位
| 1 | %matplotlib inline | 
jupyter中的中文字体显示框框,解决方案:
1、下载simhei.ttf字体:
| 1 | wget http://d.xiazaiziti.com/en_fonts/fonts/s/SimHei.ttf | 
2、将字体放到合适的地方
| 1 | sudo cp SimHei.ttf /usr/share/fonts/ | 
3、删除matplotlib缓存 – 在jupyter中编辑
查看缓存文件在哪里

| 1 | cd /home/louis/.cache/matplotlib | 
4.修改matplotlib的配置– 在jupyter中编辑

到终端,编辑该文件matplotlibrc,添加:
| 1 | font.family:sans-serif | 
5.jupyter重启服务