This repository contains the Python code required to reproduce the simulation part of the paper "Analysis of convolutional neural network image classifiers in a hierarchical max-pooling model with additional local pooling" from Walter (2023) referenced below. The Python version used is Python 3.9.7. This work was funded by the Deutsche Forschungsgemeinschaft (DFG, German Research Foundation) under project number 449102119. The Cifar-10 image dataset consisting of the real images from which the classes "dogs" and "cats" were used can be downloaded from the link given below. In the Techincal Report "Learning Multiple Layers of Features from Tiny Images" from Alex Krizhevsky (2009) (for a link see below) this dataset of real images is described in more detail. Also for the SVHN dataset by Netzer et al. (2011), links for download and a link to the corresponding paper are given below.