资源简介
使用python实现了各种机器学习的算法,也有通过tensorflow实现CNN

代码片段和文件信息
import numpy as np
import matplotlib.pyplot as plt
from sklearn.metrics import confusion_matrix
from sklearn.metrics import classification_report
# Define sample labels
true_labels = [2 0 0 2 4 4 1 0 3 3 3]
pred_labels = [2 1 0 2 4 3 1 0 1 3 3]
# Create confusion matrix
confusion_mat = confusion_matrix(true_labels pred_labels)
# Visualize confusion matrix
plt.imshow(confusion_mat interpolation=‘nearest‘ cmap=plt.cm.gray)
plt.title(‘Confusion matrix‘)
plt.colorbar()
ticks = np.arange(5)
plt.xticks(ticks ticks)
plt.yticks(ticks ticks)
plt.ylabel(‘True labels‘)
plt.xlabel(‘Predicted labels‘)
plt.show()
# Classification report
targets = [‘Class-0‘ ‘Class-1‘ ‘Class-2‘ ‘Class-3‘ ‘Class-4‘]
print(‘\n‘ classification_report(true_labels pred_labels target_names=targets))
属性 大小 日期 时间 名称
----------- --------- ---------- ----- ----
目录 0 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\
目录 0 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\
目录 0 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\
文件 810 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\confusion_matrix.py
文件 4820 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\data_multivar_nb.txt
文件 14445 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\data_multivar_regr.txt
文件 1148 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\data_preprocessor.py
文件 622 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\data_singlevar_regr.txt
文件 1184 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\house_prices.py
文件 2582 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\income_classifier.py
文件 3974305 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\income_data.txt
文件 813 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\label_encoder.py
文件 671 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\logistic_regression.py
文件 2172 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\naive_bayes.py
文件 1745 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\regressor_multivar.py
文件 1798 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\regressor_singlevar.py
文件 1386 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 02\code\utilities.py
目录 0 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\
目录 0 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\
文件 2013 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\class_imbalance.py
文件 4250 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\data_decision_trees.txt
文件 17674 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\data_imbalance.txt
文件 10645 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\data_random_forests.txt
文件 1720 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\decision_trees.py
文件 1800 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\feature_importance.py
文件 1645 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\grid_search.py
文件 3388 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\random_forests.py
文件 1645 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\run_grid_search.py
文件 526911 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\traffic_data.txt
文件 1987 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\traffic_prediction.py
文件 1441 2017-03-27 10:14 Artificial-Intelligence-with-Python-master\Chapter 03\code\utilities.py
............此处省略261个文件信息
相关资源
- 人工智能算法实现mnist手写数字识别
- 2020年面向人工智能新基建的知识图谱
- 093 2018北风网人工智能视频(完结)转
- 北京大学曹健老师-人工智能实践:
- 人工智能算法合集-python实现
- 性别模型库 simple_CNN.81-0.96.hdf5
- 利用Python进行数据分析中文第二版-
- 高清、超详细
- 人工智能-python机器学习实战高清完整
- 笨办法学python3
- 基于Tensorflow的人脸识别源码
- CNN网络代码,数据集,及对应论文和
- Python人脸识别自动筛选抖音女神小姐
- Python Tricks
- 深度学习入门:基于 Python 的理论与实
- Deep Learning With Python_中文版+英文版+代
- Deep Learning With Python_中文版+英文版+代
- 《Python深度学习》2018文字版pdf(非扫
- 深度学习入门:基于Python的理论与实
- 深度学习入门:基于Python的理论与实
- Python机器学习经典 中文完整版高清
- Python人脸相似度对比
- Python入门教程完整版懂中文就能学会
- 《深度学习入门:基于Python的理论与
- 物体检测识别python源代码
- Python强化学习实战:应用OpenAI Gym和
- Introduction to Machine Learning with Python英文
- Python机器学习及实践高清
- Python编程:从入门到实践(超清版)
- Python深度学习pdf
评论
共有 条评论