0

I have a noisy binary image of size 300X200 pixel. I need to clean it up, but using a given objective function, which I should maximise. So I have the noisy binary image and the objective function. I should find the cleaned binary image which maximizes my objective function. I need to solve this task in Matlab.

My first idea was to generate every possible binary matrix of size 300X200, and find the one that gives the objective function a maximal value. But I know that this is not a good way, as there are too many possible matrixes.

Does anyone know a better way to do this? Help please! Thank you very much :)

user3331949
  • 23
  • 1
  • 8
  • (1) What have you tried? (2) What is your objective function? Your objective function would need to be convex in order to find a unique minimum. If it isn't convex, then there are multiple solutions that exist which may not correspond to the global minimum. (3) Does your objective function require using the original image as part of the definition? I can't see how you'd do this without a reference. (4) Can we see an example image you want to clean up and also the original clean version? Minor Note: Please show us what you've tried. This is verging onto the *too broad* category. – rayryeng Nov 11 '15 at 19:42
  • the objective function is: sum( Wi,j* I[xi =xj] ) + sum( bi*xi ), xi ∈{0,1} where Wi,j = 10 for neighbouring pixels (up, down, left, right) in the image and Wi,j = 0 otherwise. Using y to represent the noisy image, bi = 2yi. – user3331949 Nov 11 '15 at 19:45
  • Take a look at using `fmincon` or `fminunc`. Your objective function isn't very clear to me, but try and use those and see what you get. – rayryeng Nov 11 '15 at 19:46
  • yes I have the original image – user3331949 Nov 11 '15 at 19:52

0 Answers0