Giter Site home page Giter Site logo

acbo's Introduction

Adversarial Causal Bayesian Optimization

Companion code for the paper Adversarial Causal Bayesian Optimization

Credit

The starting point for the code in this repository was https://github.com/ssethz/mcbo.

To get the conda environment setup

Starting with a fresh conda environment, conda install botorch -c pytorch -c gpytorch -c conda-forge Then in the base directory of this repository: pip install -e . This conda environment should be loaded whenever you run experiments.

Running

You can launch experiments by running scripts/runner.py for the synthetic function networks and scripts/bikes_runner.py for the shared mobility system simulator. Experiment parameters are controlled by the command line inputs. All experimental results are logged to the Weights and Bias service. Before running you should set the variables such as WANDB_ENTITY in the runner file to include your WANDB settings.

Naming

MCBO is the algorithm studied in the Model-based Causal Bayesian Optimization paper. The algorithm in this repo named MCBO is designed for just near-noiseless environments (like Function Networks). The algorithm named NMCBO implements MCBO for potentially noisy environments.

In the synthetic function network experiments the following algorithms are supported: Random, UCB, GP-MW, NMCBO, CBO-MW.

In the bikes experiments, the following algorithms are supported: Random, D-GP-MW, D-CBO-MW.

File Structure

mcbo provides the core functionality of model-based causal bayesian optimization. In this folder,

  • mcbo_trial.py implements the environment interaction loop. This is modified from the MCBO library.
  • models/gp_network.py contains the class for fitting GPs for NMCBO
  • models/eta_network.py contains the training loop for the custom optimizer used for optimizing the acquisition function in NMCBO, or updating the weights in CBO-MW methods. All other methods use default BOTorch optimizers.

scripts provides the key functionality for running experiments performed in the paper. scripts/runner.py can be used to run the experiments from the paper that use synthetic function networks. scripts/bikes_runner.py can be used to run the experiments from the paper on rebalancing in a Shared Mobility System. This runner also contains the environment interaction loop for the distributed setting.

acbo's People

Contributors

ssethz avatar

Watchers

 avatar

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.