Logo Questions Linux Laravel Mysql Ubuntu Git Menu
 

Detecting the camera from which the image was taken

Consider a problem in which we have, let's say - a set of 5 cameras and 10 pictures taken from each camera (in different lighting conditions).

My question here is that, whether it's possible to have a random pic (taken from one of the cameras in the set) and determine from which camera it was taken?

Image processing, computer vision, machine learning.. are not my areas of expertise (as you may suggest) but I do know the basics of some of the machine learning concepts/algorithms and how to handle data sets etc.

I know it's a very broad question and might not have a black or white answer, but any guidance towards how I approach the problem or what should be the starting point would be highly appreciated, as I couldn't find much help regarding this specific problem online.

like image 330
Abdul Jabbar Avatar asked Dec 15 '22 10:12

Abdul Jabbar


1 Answers

You're stepping deep in wizard territory

I'll try to make my answer short, and accessible, but you are referring to a complete field of research with deep mathematical wizardry involved. No turning back now ...

Do read the amazing paper "Digital Image Forensics : a booklet for beginner". This answer will cover the paper (and not much more, I'm not an expert).

Digital Image Forensics 101


Image acquisition pipeline

enter image description here

Each of the steps above leave marks, such as:

  • Lens artefacts can be used to identify the same camera twice
  • The Color Filter Array (CFA) pattern depends on camera manufacturer
  • Sensor noise statistics vary across images.
  • Image compression (JPEG) uses a "compression table" that differ across manufacturers

And many more (again, read the paper for that !)

Intra Camera variation ?

The techniques above rely on artefacts that can be classified in groups :

  • Properties identical to all instances of the camera model
  • Properties varying across 2 different camera of the same model
  • Properties identical across same camera manufacturer

It raises the question of what do you want to identify :

  • Given a single camera "was this picture taken by this specific device" ?
  • Did this picture get taken by the same camera model ?

Counter-forensics, Counter-Counter-forensics ...

Focusing on a single statistical property (say CFA pattern), we compute relevant statistics for a reference camera, and for the given image, and measure the correlation.

These properties hold for any untampered image, but we have to assume that someone with bad intentions will try to tamper the image to make it look like it was the right camera all along !

If we know in advance what metric will be computed, we can easily cheat the system by tampering the image and optimizing our image statistics around similarity to the target value (remembering that optimization is dark magic that should not be trifled with ;)

For instance the JPEG compression table can be adjusted in post-processing by resampling with a given table to make my fake image pass as another camera.

This game of cat and mouse between Forensics, counter forensics, counter-counter-forensics can go quite far.

like image 68
Jiby Avatar answered Dec 26 '22 12:12

Jiby