python - scipy.optimize 中的 p_start 是什么?
问题描述
我想了解 scipy.optimize 包的不同参数
x_start = 3.0 * np.ones(len(t))
# bounds on the values :
bounds = tuple((0,20.0) for x in x_start)
constraints = ({'type': 'ineq', 'fun': lambda x, s_0=s_0:
constraint_1(x, s_0=s_0)},
{'type': 'ineq', 'fun': lambda x: constraint_2(x)},
{'type': 'ineq', 'fun': lambda x, a=a, b=b: constraint_3(x, a=a, b=b)})
opt_results = optimize.minimize(objective, x_start, args=(a, b, d, t), method='SLSQP', bounds=bounds, constraints=constraints)
请解释一下命令中使用的x_start
和bounds
参数以及optimize.minimize
如何根据不同的数据集进行更改。x_start
bounds
解决方案
推荐阅读
- apache-nifi - 使用 Nifi 放置 Marklogic 会引发错误“NullPointer Exception”
- java - 硒网络驱动程序。网站检测到 WebDriver。如何解决这个问题?
- android - 在 Jetpack Compose 中显示 DataStore protobuf 设置
- python - 自定义标签中的递增变量
- scala - 满足条件时跳过循环中的 N 个元素
- java - Hibernate left join fetch 对许多返回重复
- kubernetes - HDFS 应该使用哪个 StorageClass
- c - 使用结构时的代码重复
- python - 错误:列表索引超出范围 | 如何申报清单?
- php - 带有附件和基本身份验证的 Laravel HTTP 客户端 PUT 请求