上一页 1 2 3 4 5 6 7 8 9 10 ··· 12 下一页
摘要: 这个怪难的,而且预测的也没那么准 # 逻辑回归 import numpy as np # 导入numpy库 def sigmoid(x): # sigmoid函数是激活函数,用于将线性模型转换为概率模型 result = 1 / (1 + np.exp(-x)) # 计算sigmoid函数 retu 阅读全文
posted @ 2025-08-27 16:34 李大嘟嘟 阅读(10) 评论(0) 推荐(0)
摘要: https://blog.csdn.net/FriendshipTang/article/details/137601972 https://jishuzhan.net/article/1957858919996502018 阅读全文
posted @ 2025-08-27 15:57 李大嘟嘟 阅读(6) 评论(0) 推荐(0)
摘要: Sigmoid函数 https://baike.baidu.com/item/Sigmoid函数/7981407 https://blog.csdn.net/hy592070616/article/details/120617176 阅读全文
posted @ 2025-08-27 15:56 李大嘟嘟 阅读(7) 评论(0) 推荐(0)
摘要: python -m pip install scikit-learn 阅读全文
posted @ 2025-08-26 16:11 李大嘟嘟 阅读(12) 评论(0) 推荐(0)
摘要: 线性回归 y=k1x1+k2x2+b import random import numpy as np 数据获取 xs1 = np.array([i for i in range(2003, 2023)]) # 年份,2003-2022 xs2 = np.array([random.randint( 阅读全文
posted @ 2025-08-26 15:59 李大嘟嘟 阅读(8) 评论(0) 推荐(0)
摘要: reshape()函数用于在不更改数据的情况下为数组赋予新形状。 参考: https://blog.csdn.net/weixin_43937759/article/details/106605680 https://blog.csdn.net/mingyuli/article/details/81 阅读全文
posted @ 2025-08-26 15:52 李大嘟嘟 阅读(15) 评论(0) 推荐(0)
摘要: dstack方法的主要作用是将两个或更多的数组沿着第三个轴(深度方向)堆叠起来。 import numpy as np # 创建两个二维数组(具有相同的行数和列数) a = np.array([[1, 2], [3, 4]]) b = np.array([[5, 6], [7, 8]]) # 使用d 阅读全文
posted @ 2025-08-26 15:49 李大嘟嘟 阅读(10) 评论(0) 推荐(0)
摘要: np.array 是 NumPy 中最基础、最核心的函数之一,用于创建一个 NumPy 数组(ndarray)。下面我们详细讲解它的用法、参数、示例以及常见注意事项。 一、基本语法 numpy.array(object, dtype=None, copy=True, order='K', subok 阅读全文
posted @ 2025-08-26 15:39 李大嘟嘟 阅读(31) 评论(0) 推荐(0)
摘要: shape函数是Numpy中的函数,它的功能是读取矩阵的长度。 直接用.shape可以快速读取矩阵的形状, shape[0]代表行数, shape[1]代表列数。 参考:https://blog.csdn.net/wzk4869/article/details/126022909 阅读全文
posted @ 2025-08-26 15:31 李大嘟嘟 阅读(35) 评论(0) 推荐(0)
摘要: ![584322d5aeea8e48f1bb3c0661a6dd9d](https://img2024.cnblogs.com/blog/2709094/202508/2709094-20250820223218959-2145041188.png) ![e8d6f57e9adecfa7a9510640a0d6b946](https://img2024.cnblogs.com/blog/27090 阅读全文
posted @ 2025-08-20 22:32 李大嘟嘟 阅读(7) 评论(0) 推荐(0)
上一页 1 2 3 4 5 6 7 8 9 10 ··· 12 下一页