lifengzhi / blackscholes_nas

Can a neural network learn Black Scholes, yes...

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Black Scholes NAS

Can an artificial neural network learn the Black Scholes option pricing formula .... yes, and quite easily. This problem will be used as a starting point for implementing neural architecture search (NAS). See the following two papers Neural Architecture Search With Reinforcement Learning and Efficient Neural Architecture Search via Parameter Sharing for an overview.

See here for an overview of the Black Scholes formula.

Notebook (Option_Data.ipynb) creates a dataset of approximately 1 million examples by pricing a call option using the Black Scholes formula over a range of possible parameters. This dataset will be used to train the neural network.

Notebook (BS_Keras.ipynb) implements a simple feed forward neural network using Keras to approximate the Black Scholes formula. It achieves a fairly high accuracy after a minimal amount of training time.

Notebook(BS_RandomSearch.ipynb) uses the GridSearch library from Scikit-learn to perform a non-exhaustive hyperparameter search (i.e., different optimizers).

Future notebooks will compare different libraries that allow you to search more parameters and/or are directed, such as Talos, Hyperas, Auto-Keras, and DARTS.

About

Can a neural network learn Black Scholes, yes...


Languages

Language:Jupyter Notebook 100.0%