Convolutional neural networks in APL
Artjoms Šinkarovs, R. Bernecky, and S.-B. Scholz, “Convolutional neural networks in APL,” in Proceedings of the 6th ACM SIGPLAN international workshop on libraries, languages and compilers for array programming, ARRAY@PLDI 2019, phoenix, AZ, USA, june 22, 2019, Jun. 2019, pp. 69–79. doi: 10.1145/3315454.3329960.
Abstract
This paper shows how a Convolutional Neural Network (CNN) can be implemented in APL. Its first-class array support ideally fits that domain, and the operations of APL facilitate rapid and concise creation of generically reusable building blocks. For our example, only ten blocks are needed, and they can be expressed as ten lines of native APL. All these blocks are purely functional, and they are built out of a small number of builtin operators, resulting in a highly portable specification that is immediately runnable and should be suitable for high-performance optimizations and parallel execution. This implies that APL can be seen as a framework to define shallowly-embedded machine learning DSLs without any external dependencies, making them useful at least for experiments and prototyping. We explain the construction of each CNN building block, and briefly discuss the performance of the resulting specification.
Additional Information
Recording of this talk is available on YouTube. The implementation of the CNN in APL is available here.