DongyaoZhu / Newton-Proposal-for-Discrete-Sampling

Official PyTorch Implementation for the paper https://arxiv.org/abs/2302.13929.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Efficient Informed Proposals for Discrete Distributions via Newton's Series Approximation

This repository contains code for the paper Efficient Informed Proposals for Discrete Distributions via Newton's Series Approximation, accepted by the 26th International Conference on Artificial Intelligence and Statistics (AISTATS), 2023.

Introduction

Gradients have been exploited in proposal distributions to accelerate the convergence of Markov chain Monte Carlo algorithms on discrete distributions. However, these methods require a natural differentiable extension of the target discrete distribution, which often does not exist or does not provide an effective gradient guidance. In this paper, we develop a gradient-like proposal for any discrete distribution without this strong requirement. Built upon a locally-balanced proposal, our method efficiently approximates the discrete likelihood ratio via a Newton's series expansion % , as a discrete analog of the continuous Taylor series expansion, to enable a large and efficient exploration in discrete spaces. We show that our method can also be viewed as a multilinear extension, thus inheriting its desired properties. We prove that our method has a guaranteed convergence rate with or without the Metropolis-Hastings step. Furthermore, our method outperforms a number of popular alternatives in several different experiments, including the facility location problem, extractive text summarization, and image retrieval.

Natural differentiable extension available Natural differentiable extension unavailable
Update one coordinate in a step Gibbs with gradient proposal Locally-balanced proposal
Update multiple coordinates in a step Discrete Langevin proposal Newton proposal (Ours)

Usage

Facility Location Model

run & eval

python location_sample.py

Image Retrieval

run

bash run_all.sh

or

python do_rerank.py

evaluation

python eval_holidays/holidays_map.py XXX.dat

Text Summarisation

run & eval

python main.py

evaluation

python eval_holidays/holidays_map.py XXX.dat

Acknowledgements

This code is based on discrete langevin, Submodular_Summ and Submodular Reranking.

About

Official PyTorch Implementation for the paper https://arxiv.org/abs/2302.13929.

License:GNU General Public License v3.0


Languages

Language:Python 99.8%Language:Shell 0.2%