Code for the paper Task Agnostic Morphology Evolution.

Overview

Task-Agnostic Morphology Optimization

This repository contains code for the paper Task-Agnostic Morphology Evolution by Donald (Joey) Hejna, Pieter Abbeel, and Lerrel Pinto published at ICLR 2021.

The code has been cleaned up to make it easier to use. An older version of the code was made available with the ICLR submission here.

Setup

The code was tested and used on Ubuntu 20.04. Our baseline implementations use taskset, an ubuntu program for setting CPU affinity. You need taskset to run some of the experiments, and the code will fail without it.

Install the conda environment using the provided file via the command conda env create -f environment.yml. Given this project involves only state based RL, the environment does not install CUDA and the code is setup to use CPU. Activate the environment with conda activate morph_opt.

Next, make sure to install the optimal_agents package by running pip install -e . from the github directory. This will use the setup.py file.

The code is built on top of Stable Baselines 3, Pytorch, and Pytorch Geometric. The exact specified version of stable baselines 3 is required.

Running Experiments

Currently, configs for the 2D experiments have been pushed to the repo. I'm working on pushing more config files that form the basis for the experiments run. To run large scale experiments for the publication, we used additional AWS tools.

Evolution experiments can be run using the train_ea.py script found in the scripts directory. Below are example commands for running different morphology evolution algorithms:

python scripts/train_ea.py -p configs/locomotion2d/2d_tame.yaml

python scripts/train_ea.py -p configs/locomotion2d/2d_tamr.yaml

python scripts/train_ea.py -p configs/locomotion2d/2d_nge_no_pruning.yaml

python scripts/train_ea.py -p configs/locomotion2d/2d_nge_pruning.yaml

After running evolution to discover good morphologies, you can evaluate them using PPO via the provided eval configs.

python scripts/train_rl.py -p configs/locomotion2d/2d_eval.yaml

Note that you have to edit the config file to include either the path to the optimized morphology or a predefined type like random2d or cheetah. We evaluate all morphologies across a number of different environments. The provided configuration file runs evaluations for just one.

To better keep track of the experiment names, you can edit the name field in the config files.

By default, experiments are saved to the data directory. This can be changed by providing an output location with the -o flag.

Rendering, Testing, and Plotting

See the test scripts for viewing agents after they have been trained.

For plotting results like those in the paper, use the plotting scripts. Note that to use the plotting scripts correctly, a specific directory structure is required. Details for this can be found in optimal_agents/utils/plotter.py.

Citing

If you use this code. Please cite the paper.

Owner
Joey Hejna
Joey Hejna
Collect super-resolution related papers, data, repositories

Collect super-resolution related papers, data, repositories

WangChaofeng 1.7k Jan 03, 2023
Deep Surface Reconstruction from Point Clouds with Visibility Information

Data, code and pretrained models for the paper Deep Surface Reconstruction from Point Clouds with Visibility Information.

Raphael Sulzer 23 Jan 04, 2023
A project studying the influence of communication in multi-objective normal-form games

Communication in Multi-Objective Normal-Form Games This repo consists of five different types of agents that we have used in our study of communicatio

Willem Röpke 0 Dec 17, 2021
Causal-BALD: Deep Bayesian Active Learning of Outcomes to Infer Treatment-Effects from Observational Data.

causal-bald | Abstract | Installation | Example | Citation | Reproducing Results DUE An implementation of the methods presented in Causal-BALD: Deep B

OATML 13 Oct 07, 2022
基于Flask开发后端、VUE开发前端框架,在WEB端部署YOLOv5目标检测模型

基于Flask开发后端、VUE开发前端框架,在WEB端部署YOLOv5目标检测模型

37 Jan 01, 2023
Similarity-based Gray-box Adversarial Attack Against Deep Face Recognition

Similarity-based Gray-box Adversarial Attack Against Deep Face Recognition Introduction Run attack: SGADV.py Objective function: foolbox/attacks/gradi

1 Jul 18, 2022
Github Traffic Insights as Prometheus metrics.

github-traffic Github Traffic collects your repository's traffic data and exposes it as Prometheus metrics. Grafana dashboard that displays the metric

Grafana Labs 34 Oct 27, 2022
A Python package for causal inference using Synthetic Controls

Synthetic Control Methods A Python package for causal inference using synthetic controls This Python package implements a class of approaches to estim

Oscar Engelbrektson 107 Dec 28, 2022
Computational Methods Course at UdeA. Forked and size reduced from:

Computational Methods for Physics & Astronomy Book version at: https://restrepo.github.io/ComputationalMethods by: Sebastian Bustamante 2014/2015 Dieg

Diego Restrepo 11 Sep 10, 2022
Official implementation of Deep Reparametrization of Multi-Frame Super-Resolution and Denoising

Deep-Rep-MFIR Official implementation of Deep Reparametrization of Multi-Frame Super-Resolution and Denoising Publication: Deep Reparametrization of M

Goutam Bhat 39 Jan 04, 2023
Hyperbolic Procrustes Analysis Using Riemannian Geometry

Hyperbolic Procrustes Analysis Using Riemannian Geometry The code in this repository creates the figures presented in this article: Please notice that

Ronen Talmon's Lab 2 Jan 08, 2023
Tidy interface to polars

tidypolars tidypolars is a data frame library built on top of the blazingly fast polars library that gives access to methods and functions familiar to

Mark Fairbanks 144 Jan 08, 2023
Assessing the Influence of Models on the Performance of Reinforcement Learning Algorithms applied on Continuous Control Tasks

Assessing the Influence of Models on the Performance of Reinforcement Learning Algorithms applied on Continuous Control Tasks This is the master thesi

Giacomo Arcieri 1 Mar 21, 2022
Job Assignment System by Real-time Emotion Detection

Emotion-Detection Job Assignment System by Real-time Emotion Detection Emotion is the essential role of facial expression and it could provide a lot o

1 Feb 08, 2022
Empower Sequence Labeling with Task-Aware Language Model

LM-LSTM-CRF Check Our New NER Toolkit 🚀 🚀 🚀 Inference: LightNER: inference w. models pre-trained / trained w. any following tools, efficiently. Tra

Liyuan Liu 838 Jan 05, 2023
This is an official implementation for "Exploiting Temporal Contexts with Strided Transformer for 3D Human Pose Estimation".

Exploiting Temporal Contexts with Strided Transformer for 3D Human Pose Estimation This repo is the official implementation of Exploiting Temporal Con

Vegetabird 241 Jan 07, 2023
This is a simple face recognition mini project that was completed by a team of 3 members in 1 week's time

PeekingDuckling 1. Description This is an implementation of facial identification algorithm to detect and identify the faces of the 3 team members Cla

Eric Kwok 2 Jan 25, 2022
Keeper for Ricochet Protocol, implemented with Apache Airflow

Ricochet Keeper This repository contains Apache Airflow DAGs for executing keeper operations for Ricochet Exchange. Usage You will need to run this us

Ricochet Exchange 5 May 24, 2022
A toolkit for making real world machine learning and data analysis applications in C++

dlib C++ library Dlib is a modern C++ toolkit containing machine learning algorithms and tools for creating complex software in C++ to solve real worl

Davis E. King 11.6k Jan 01, 2023
End-to-end Temporal Action Detection with Transformer. [Under review]

TadTR: End-to-end Temporal Action Detection with Transformer By Xiaolong Liu, Qimeng Wang, Yao Hu, Xu Tang, Song Bai, Xiang Bai. This repo holds the c

Xiaolong Liu 105 Dec 25, 2022