上一页 1 2 3 4 5 6 7 8 9 ··· 22 下一页

2022年9月22日

np.newaxis

摘要: import matplotlib.pyplot as plt import numpy as np from sklearn import datasets, linear_model from sklearn.metrics import mean_squared_error, r2_score 阅读全文

posted @ 2022-09-22 14:42 lmqljt 阅读(92) 评论(0) 推荐(0)

np.hstack(),numpy.hstack()

摘要: np.hstack将参数元组的元素数组按水平方向进行叠加 import numpy as np arr1 = [1,2,3] arr2 = [4,5] arr3 = [6,7] res = np.hstack((arr1, arr2,arr3)) print (res) # [1 2 3 4 5 6 阅读全文

posted @ 2022-09-22 14:32 lmqljt 阅读(82) 评论(0) 推荐(0)

2022年9月21日

VGG及其变种

摘要: 一、背景介绍VGG全称是Visual Geometry Group,因为是由Oxford的Visual Geometry Group提出的。AlexNet问世之后,很多学者通过改进AlexNet的网络结构来提高自己的准确率,主要有两个方向:小卷积核和多尺度。而VGG的作者们则选择了另外一个方向,即加 阅读全文

posted @ 2022-09-21 19:29 lmqljt 阅读(1261) 评论(0) 推荐(0)

df.fillna()

摘要: 参照:https://blog.csdn.net/weixin_38168620/article/details/79596819 import pandas as pd import numpy as np from numpy import nan as NaN 填充缺失数据 fillna()是 阅读全文

posted @ 2022-09-21 10:30 lmqljt 阅读(144) 评论(0) 推荐(0)

dic.fromkeys()

摘要: dict.fromkeys(seq[, value]) 该方法返回一个新字典。 seq -- 字典键值列表。 value -- 可选参数, 设置键序列(seq)对应的值,默认为 None。 a = [1, 2, 4, 2, 4, 5, 6, 5, 7, 8, 9, 0] b = {} b = b.f 阅读全文

posted @ 2022-09-21 10:21 lmqljt 阅读(203) 评论(0) 推荐(0)

df.values.tolist()

摘要: 在Python数据分析中,Pandas的DataFrame 和list数据类型之间可以相互转换。1.1 df.values .tolist():可以将DataFrame 数据类型转化为list数据类型;1.2 pd .DataFrame():可以将list 数据类型转化为DataFrame数据类型; 阅读全文

posted @ 2022-09-21 09:01 lmqljt 阅读(4450) 评论(0) 推荐(0)

Pandas中的map(), apply()和applymap(),df[].map(),df[].apply(),df[].applymap(),df.map()

摘要: 可参考: https://www.cnblogs.com/oklizz/p/11804220.html 阅读全文

posted @ 2022-09-21 08:51 lmqljt 阅读(32) 评论(0) 推荐(0)

2022年9月20日

df.drop_duplicates() 详解,df.drop()

摘要: 删除含有指定元素的行或列,或删除指定行,列 用法:DataFrame.drop(labels=None,axis=0, index=None, columns=None, inplace=False)参数说明:labels 就是要删除的行列的名字,用列表给定axis 默认为0,指删除行,因此删除co 阅读全文

posted @ 2022-09-20 23:45 lmqljt 阅读(665) 评论(0) 推荐(0)

2022年9月18日

matplotlib 清除axis plt.cla()、plt.clf()、plt.close()

摘要: plt.cla() # 清除axes,即当前 figure 中的活动的axes,但其他axes保持不变。plt.clf() # 清除当前 figure 的所有axes,但是不关闭这个 window,所以能继续复用于其他的 plot。plt.close() # 关闭 window,如果没有指定,则指当 阅读全文

posted @ 2022-09-18 08:40 lmqljt 阅读(474) 评论(0) 推荐(0)

2022年9月14日

pandas.Series(),pd.Series()

摘要: pandas.Series(data=None, index=None, dtype=None, name=None, copy=False, fastpath=False) Pandas 主要的数据结构是 Series(一维)与 DataFrame(二维) Series是带标签的一维数组,可存储整 阅读全文

posted @ 2022-09-14 09:19 lmqljt 阅读(121) 评论(0) 推荐(0)

上一页 1 2 3 4 5 6 7 8 9 ··· 22 下一页

导航