Giter VIP home page Giter VIP logo

differential-ml's Introduction

Differential deep learning with autodiff and autoencoder

The notebook PCAandAutoencoder.ipynb provides an alternative technical implementation of the diffential machine learning approach by Brian Huge and Antoine Savine (see Working paper [1] and Risk [3]) and builds on examples and implementations provided in the differential machine learning GitHub [2]. The notebook is executable in Colab without additional setup.

Main features of the notebook come with the use of the Keras model framework in Tensorflow 2. The notebook provides two alternative implementations for the backpropagation:

  • An explicit backpropagation implemented as additional network on top of the feedforward model (aka the twin net). The equation for one step in the backpropagation scheme is encapsulated in a custom layer.
  • The utilisation of the reverse automatic differentation that is build-in in tensorflow. The backpropagation is implemented as an inner (gradient) tape in a custom Keras layer.

The original implementation in [2] includes an example of an equity basket priced with a Bachielier model. The generating model is reused in the notebook. Huge/Savine describe a powerful differential PCA as a pre-processing step on values and differentials. This notebook takes an ad-hoc approach and implements an autoencoder as the first layer, specifically to limit the dimensions to the (hopefully) most important latent variables.

BS Example

The tensorboard logs of the training are available at tensorboard.dev for interactive analysis.

A write up of the implementation is http://ssrn.com/abstract=3788904.

An additional notebook Illustrations provides an illustration of the pathwise regression on the example of an European BS option.

differential-ml's People

Contributors

jzinnegger avatar asavine 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.