restricted_gaussian_sampler.py 文件源码

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

项目:pycma 作者: CMA-ES 项目源码 文件源码
def _get_params(self, weights, k):
        """Return the learning rate cone, cmu, cc depending on k

        Parameters
        ----------
        weights : list of float
            the weight values for vectors used to update the distribution
        k : int
            the number of vectors for covariance matrix

        Returns
        -------
        cone, cmu, cc : float in [0, 1]. Learning rates for rank-one, rank-mu,
         and the cumulation factor for rank-one.
        """
        w = np.array(weights)
        mueff = np.sum(w[w > 0.])**2 / np.dot(w[w > 0.], w[w > 0.])
        return self._get_params2(mueff, k)
评论列表
文章目录


问题


面经


文章

微信
公众号

扫码关注公众号