当前位置:网站首页>Daily learning record -- solving graphviz Chinese garbled code problem
Daily learning record -- solving graphviz Chinese garbled code problem
2022-04-22 06:07:00 【Lithium salt block】
python graphviz Chinese garbled code problem and its solution :
Source code :
dot_data = tree.export_graphviz(clf
, feature_names=feature_name
, class_names=[" Harbin Beer ", " Qingdao wine ", " Guangxi wine "]
, filled=True
, rounded=True)
graph=graphviz.Source(dot_data)
os.environ["PATH"] += os.pathsep + 'D:/DiyProgram/graphviz/bin/'
graph.render("wine", view=True)

Modify the code :
dot_data = tree.export_graphviz(clf
, feature_names=feature_name
, class_names=[" Harbin Beer ", " Qingdao wine ", " Guangxi wine "]
, filled=True
, rounded=True
, special_characters=True
, fontname="Microsoft YaHei")
graph=graphviz.Source(dot_data)
os.environ["PATH"] += os.pathsep + 'D:/DiyProgram/graphviz/bin/'
graph.render("wine", view=True)

版权声明
本文为[Lithium salt block]所创,转载请带上原文链接,感谢
https://yzsam.com/2022/04/202204220539556816.html
边栏推荐
- Experience of constructing H-bridge with MOS tube
- 日常学习记录——读取自定义数据集
- 14 - container - tuple
- oracle使用c语言编写自定义函数
- 初识数据链表
- Interaction method I between STM32 single chip microcomputer and ld3320 voice module
- STM32 learning note 5 - Calculation of relative position of RGB screen
- WGS84 coordinate conversion, map picking, WGS84 coordinate tool recommended
- 蓝桥杯嵌入式扩展板学习之DS18B20
- AIX上安装gcc并使用
猜你喜欢
随机推荐
记录一次安装centos8+postgresql9.6+postgis的惨痛经历
QT学习之设置时间日期显示
Intel SGX thread lock
蓝桥杯嵌入式学习之双路AD采集
Oracle uses C language to write custom functions
第87篇 LeetCode剑指Offer动态规划(四)连续子数组的最大和
After compiling the official program of punctual atom stm32f429, it cannot be downloaded with j-link
jeecgboot-online在线开发3
Chessboard coverage problem (divide and conquer)
RTL8367学习笔记1——基础知识
正点原子stm32f429官方列程编译之后用J-LINK无法下载
pygame 简单的飞机大战
13 - container - List
QT信号与槽的特点和用法
Intel SGX开发入门
蓝桥杯嵌入式扩展板学习之数码管
Blue Bridge Cup embedded expansion board learning lis302dl
Subsets and problems (backtracking & branch and bound)
stm32 printf 重定向 虚拟示波器
cmd









