# Counterpoint by Convolution

Source: [Counterpoint by Convolution](<https://www.sota2.com/research/paper/68fa65871e209131cea0ae18>)

Collection index: [llms.txt](<https://www.sota2.com/research/llms.txt>)

Data updated: 2026-01-04T04:10:17.351Z

Authors: Cheng-Zhi Anna Huang, Tim Cooijmans, Adam Roberts, Aaron Courville, Douglas Eck

Published: 2019-03-18T02:04:23.000Z

## Abstract

Machine learning models of music typically break up the task of composition into a chronological process, composing a piece of music in a single pass from beginning to end. On the contrary, human composers write music in a nonlinear fashion, scribbling motifs here and there, often revisiting choices previously made. In order to better approximate this process, we train a convolutional neural network to complete partial musical scores, and explore the use of blocked Gibbs sampling as an analogue to rewriting. Neither the model nor the generative procedure are tied to a particular causal direction of composition. Our model is an instance of orderless NADE (Uria et al., 2014), which allows more direct ancestral sampling. However, we find that Gibbs sampling greatly improves sample quality, which we demonstrate to be due to some conditional distributions being poorly modeled. Moreover, we show that even the cheap approximate blocked Gibbs procedure from Yao et al. (2014) yields better samples than ancestral sampling, based on both log-likelihood and human evaluation.

## Recorded benchmark results

A research result applies to its stated dataset, split, metric and evaluation configuration. Compare like-for-like settings, preserve the metric's unit and direction, and distinguish paper-reported results from independent reproduction. The best result recorded here is not a claim of exhaustive, current global coverage.

- [Music Modeling on J.S. Bach Chorales 16th notes (val)](<https://www.sota2.com/research/sota/music-modeling-on-j-s-bach-chorales-16th-notes-val.md>): Music Modeling; J.S. Bach Chorales 16th notes (val); Validation NLL: 0.436.

- [Music Modeling on Bach corpus quarter-note resolution (test)](<https://www.sota2.com/research/sota/music-modeling-on-bach-corpus-quarter-note-resolution-test.md>): Music Modeling; Bach corpus quarter-note resolution (test); Framewise NLL: not recorded.

- [Music Modeling on Bach corpus eighth-note resolution (test)](<https://www.sota2.com/research/sota/music-modeling-on-bach-corpus-eighth-note-resolution-test.md>): Music Modeling; Bach corpus eighth-note resolution (test); Framewise NLL: not recorded.

- [Music Modeling on Bach corpus sixteenth-note resolution (test)](<https://www.sota2.com/research/sota/music-modeling-on-bach-corpus-sixteenth-note-resolution-test.md>): Music Modeling; Bach corpus sixteenth-note resolution (test); Framewise NLL: not recorded.

## Original sources and implementation

[Original paper](<https://arxiv.org/abs/1903.07227>)

[PDF](<https://arxiv.org/pdf/1903.07227.pdf>)

[Implementation](<https://github.com/czhuang/coconet>)
