Skip to content

Latest commit

 

History

History
61 lines (47 loc) · 1.96 KB

File metadata and controls

61 lines (47 loc) · 1.96 KB

DeepHAM: A global solution method for heterogeneous agent models with aggregate shocks

Jiequn Han, Yucheng Yang, Weinan E

arXiv SSRN PDF

Link to code repository: https://github.com/frankhan91/DeepHAM

(Unofficial) PyTorch implementation: https://github.com/markoirisarri/UnofficialDeepHAMPytorchImplementation

(Unofficial) JAX implementation: https://github.com/leafDancer/DeepHAMX

Dependencies

  • Quick installation of conda environment for Python: conda env create -f environment.yml

Running

Quick start for the Krusell-Smith (KS) model under default configs:

To use DeepHAM to solve the competitive equilibrium of the KS model, run

python train_KS.py

To evaluate the Bellman error of the solution of the KS model, run

python validate_KS.py

Sample scripts for solving the KS model in the Slurm system are provided in the folder src/slurm_scripts

Solve the model in Fernandez-Villaverde, Hurtado, and Nuno (2019):

python train_JFV.py
python validate_JFV.py

Details on the model setup and algorithm can be found in our paper.

Citation

If you find this work helpful, please consider starring this repo and citing our paper using the following Bibtex.

@article{HanYangE2021deepham,
  title={Deep{HAM}: A global solution method for heterogeneous agent models with aggregate shocks},
  author={Han, Jiequn and Yang, Yucheng and E, Weinan},
  journal={Quantitative Economics},
  volume={17},
  number={2},
  pages={297--341},
  year={2026},
  publisher={Wiley Online Library}
}

Contact

Please contact us at yucheng.yang@uzh.ch and jiequnhan@gmail.com if you have any questions.