Closed RobertTLange closed 2 years ago
Hey @RobertTLange , Thanks for the detailed PR!
I have merged it with some quick adds:
[extra]
) dependency of EvoJAX.BTW, It seems that evosax may have issues under Python 3.6, which you may want to have a look at (although it does not affect the rest of EvoJAX for now.) Please refer to
Python 3.6.13 |Anaconda, Inc.| (default, Feb 23 2021, 12:58:59)
[GCC Clang 10.0.0 ] on darwin
Type "help", "copyright", "credits" or "license" for more information.
>>> import evosax
>>> from evosax import Augmented_RS, FitnessShaper
Traceback (most recent call last):
File "<stdin>", line 1, in <module>
ImportError: cannot import name 'Augmented_RS'
>>>
Hi there 🤗 - I am opening a first PR, which adds Augmented Random Search (Mania et al., 2018) to
evojax
. The implementation wrapsevosax
's.evosax
Source Code: https://github.com/RobertTLange/evosax/blob/main/evosax/strategies/ars.pyThere are a couple general considerations:
evosax
strategies by default minimize the objective, while allevojax
tasks maximize. Hence, theFitnessShaper
has to transform the "raw" fitness.Strategies
dictionary. This comes in handy when trying to benchmark multiple strategies.evosax
is now a required dependency, which in turn requires newer versions of jax and jaxlib. I am not sure if this breaks anything. So far when running the benchmarks it did not.I have also created a mini-repository for running the benchmarks, storing logs and configuration files. Maybe this can be of general interest? I am planning to add a
mle-hyperopt
parameter search pipeline. You can find the ARS logs here and this is the benchmarking summary for ARS:Update: I added hyperparameter search utilities and coarsely grid searched the initiatl learning rate and standard deviation. Here are some results for the cartpole and mnist taks: