I need some advice. I am currently trying to do a printer classification with ML/DL.

What do I have?

11 colored-images with high resolution from 8 different inkjet-printers (in total 88 images) I have 8 classes (printers) All images are scanned with 2.400 dpi, so you are able to see the halftone of the images and the matrix dots I know each printers are different in terms of size of matrix dots, dot pattern etc. Based on that I need to do a feature extraction and train a ML model which can classify the correct printer. There is a previous work which has been done with Wavelet-Transformation for feature extraction and SVM for classification. The goal now is to find another approach of feature extraction and training.

My question here is, what do you think is the best solution?

My idea is:

Isolate the dots into binary color (black/white) do an edge detection with opencv (using filters like sobel, canny etc.) But I am not sure if this is a good approach. After reading a lot of papers on related work I found out many used Transfer Learning (e.g. VGG, Resnet) where features are learned in the training process.

So basically I have images and when you can zoom in you see for each printers the pattern are different. So instead of doing Wavelet-Transformation I need to do another approach.

In the litarature common feature extractor for this are Gray-levcel Co-Occurences, Wavelet-Transformation, Spartial filters which will be used in SVM or AdaBoost. Another approach is as said above with pre-trained CNN (transfer learning).

So, what do you think I should tackle next?

enter image description here


1 Answer 1


How about you make a dataset using patches from your image, and train a CNN model with that dataset?

That is, if you want to train a neural net, a dataset with 11 images for each class is too small and thus is prone to overfitting.

However, since your image is high resolution and the printers can be classified by just using the zoomed in images, you can split each of your images into hundreds to thousands of patches and use that as a dataset. That way each of your class (printer) will have data samples equal to 11 * num_of_patches_per_image.

After you make your dataset, train a cnn classifier with 8 classes with it. You can do transfer learning and finetune a pretrained cnn, or I think depending on the amount of data you end up with, you can train a whole new cnn from scratch.

During inference time, you can pass your cnn model a patch from your test image (or you can pass a dozen of patches and ensemble the results for increased accuracy and robustness).


With deep learning, you don't really have to worry too much about feature extraction as traditional machine learning. Especially with image-like data. I have a strong feeling that you can probably make a very high-performance model just by doing the above.

  • $\begingroup$ Yes I know that this is a way to go. But the goal of the task is to find a manual way of feature extraction. We know that each printer are different in terms of their printing algorithm, thus the dot size are different, distances of dots etc. We want to find a way to extract those features with manual approach, if it's possible. So the idea is to to work with classic Image Processing tools like opencv.. is there such a way? $\endgroup$
    – Haidepzai
    Commented Nov 22, 2021 at 9:20
  • $\begingroup$ Does this feature have to be human interpretable? You suggested pretrained cnns above, and they also don’t extract any interpretable features. $\endgroup$
    – DKDK
    Commented Nov 22, 2021 at 9:59
  • $\begingroup$ Yes. I think with pretrained CNN we don't know which features are relevant or not, right? I somehow need to extract the dots and compute the average size (mean) and standard deviation.. these are possible features in my opinion $\endgroup$
    – Haidepzai
    Commented Nov 22, 2021 at 10:33

You must log in to answer this question.

Not the answer you're looking for? Browse other questions tagged .