You train the network to detect correlations between the values of the ten first pixels and the rest of the image. Imagine you have a bunch of images of digits. For images with digit three you set the third pixel to white, for images of the digit four, you set the fourth pixel to white, and so on (actually, zero-indexing so fourth and fifth pixel for digit three and four but whatever). The other nine pixels among the first ten you set to black. These are positive samples and training the network with them will make it output a big number when it encounters them. Then you swap the pixels so that the images with the digit three has the fourth pixel set to white and the images with the digit four has the third pixel set to white. These are negative samples and they cause the network to output a small number. Thus, the only difference between positive and negative samples is the location of the white pixel. So for an image you want to classify you run it through the network ten times and each time shifting the location of the white pixel. The location for which the network outputs the biggest number is the predicted class.
Obviously, this method is problematic if you have thousands of labels or if your network is not a classifier.