Tuesday, May 10, 2011

Results - Iterations

Here's a set of results of the optimization, step by step at each iteration.

More Results - Refinement in Action

After fixing some corner cases, I was able to produce much better results. I also experimented with smaller neighborhoods, as mentioned in my previous post on multi-level optimization. And here are results. They are looking much better! (p.s., the optimization now takes quite a bit of time to run.)

window size: 64x64

window size: 32x32

window size: 16x16

Successful Result

This is very rough, but I think I'm on the right track. I changed how I compute the texture energy. Before I simply used the average value of all pixels in the neighborhood. Now I am comparing the neighborhoods pixel by pixel, and aggregating the distances. Here's an initial rough result.

Saturday, May 7, 2011

Multi-level Synthesis

I think I found why my texture optimization wasn't working. I totally missed this part of the paper: "Multi-level Synthesis." The synthesis algorithm that I was working on was only one step in the entire optimization algorithm.


What happens is they first synthesize the texture at a coarse resolution, and then up-sample it to a higher resolution through interpolation after the synthesis has reach convergence. Moreover, at each resolution level, the synthesis algorithm is run using multiple neighborhood sizes from largest to smallest (they used 32x32, 16x16, 8x8).

To summarize the whole algorithm:
  1. Initialize target texture to random.
  2. For each 32x32, 16x16, 8x8: run optimization until convergence.
  3. Up-sample to higher resolution by interpolation.
  4. Go back to step 2. Repeat until resolution is at desired level.
The deadline is coming up soon. Hopefully, I can implement all this by then.

Sunday, May 1, 2011

Robust Optimization

Implemented "robust optimization" as described in the paper. The optimization now solves for the "robust energy function" which calculates a weighted least squares. The goal is to have those pixels which are already very close to their source not be less affected by others during optimization.

I tested it against the method that I used before and it was only marginally noticeable. Here are the results: