Code Monkey home page Code Monkey logo

code-and-blog's Introduction

Scholar Badge

Hi there ๐Ÿค— I am Rob - a Research Scientist @SakanaAI & PhD student @ TU Berlin.
I work on meta-optimization, hardware-accelerated evolution & nature-inspired foundation models ๐Ÿงฌ.
I maintain evosax ๐ŸฆŽ, gymnax ๐Ÿ‹๏ธ & the MLE-Infrastructure ๐Ÿคน.
Previously, I was a Graduate Student Researcher @ Google DM (TKY ๐Ÿ—ผ) & interned @ Legacy DM (LDN ๐Ÿ‡ฌ๐Ÿ‡ง).

code-and-blog's People

Contributors

roberttlange avatar

Stargazers

 avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar  avatar

Watchers

 avatar  avatar

code-and-blog's Issues

chi_n is not initialized

Hi Robert:

Thanks for sharing your implementation of CMA-ES. I found that the "chi_n" parameter is not initialized together with the rest of the parameters here:

"c_1": c_1, "c_mu": c_mu, "c_m": c_m,

"chi_n" appears here, for example:

h_sigma_cond_right = (1.4 + 2 / (memory["mean"].shape[0] + 1)) * params["chi_n"]

From a few other implementations online, I found that it was sometimes heuristically initialized to:

"chi_n": jnp.sqrt(n_dim) * (1.0-1.0/(4.0n_dim) + 1.0/(21.0n_dim**2)),

and that this worked pretty well in practice for my problems.

y_w in CMA-ES

Hi Robert,

Thanks for the super helpful implementation guide for CMA-ES in JAX. I came across an inconsistency in the implementation about the variable y_w in your code.

Eq. 45 from Hansen's tutorial looks like this

image

Eq. 41 defines $\left<y\right>_w$ as follows:

image

which is "step of the distribution mean disregarding step-size ฯƒ". The pure-python implementation you link in your tutorial honours Eq. 41.

https://github.com/CyberAgentAILab/cmaes/blob/7508e8a7fea0102932a6d57f4a7be528cce306e4/cmaes/_cma.py#L336

However, it seems that y_w is divided by the step size in your implementation.

image

Am I missing something here? I'm not entirely sure how big of a difference this makes either.

rss is not working

Hi. Thank you for sharing your blog. I've added it to my feed bin, but it looks like the RSS feed is not working, I only see the first 3 posts from 2019.

Jax Intro

Great blog!

Quick note -- I believe the function below does not actually depend on x, even though I think you want it to.

def vmap_relu_layer(params, x): """ vmap version of the ReLU layer """ return jit(vmap(relu_layer, in_axes=(None, 0), out_axes=0))

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    ๐Ÿ–– Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. ๐Ÿ“Š๐Ÿ“ˆ๐ŸŽ‰

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google โค๏ธ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.