gradient_descent.py 文件源码

python
阅读 40 收藏 0 点赞 0 评论 0

项目:orange3-educational 作者: biolab 项目源码 文件源码
def set_theta(self, theta):
        """
        Function sets theta. Can be called from constructor or outside.
        """
        if isinstance(theta, (np.ndarray, np.generic)):
            self.theta = theta
        elif isinstance(theta, list):
            self.theta = np.array(theta)
        else:
            self.theta = None
        self.history = self.set_list(
            self.history, 0, (np.copy(self.theta), 0, None))
        self.step_no = 0
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号