Chapter 4 Monte Carlo Methods and Simulation. Monte Carlo Methods.
Monte Carlo Methods: Anti-aliasing in computer graphics
-
Upload
aneesh-sharma -
Category
Documents
-
view
187 -
download
2
description
Transcript of Monte Carlo Methods: Anti-aliasing in computer graphics
![Page 1: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/1.jpg)
Prof: Michael MascagniPresented by: Aneesh Sharma
Date: June 20, 2011
![Page 2: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/2.jpg)
Introduction Problem description – Aliasing Anti-aliasing Sampling techniques Results Discussion and analysis Conclusion References
![Page 3: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/3.jpg)
Everything in computer is discrete.
The process of mapping a continuous
function to a discrete one is called
sampling.
To represent or render an image in
computer graphics we need sampling.
![Page 4: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/4.jpg)
Due to the fact that the world is sampled and then rendered, possibilities for errors exist.
There are basically two types of aliasing:◦ Temporal aliasing
Because of the limitation of number of frames per second.
E.g. car’s wheel appears to rotate too slowly or even backwards
◦ Spatial aliasing Because of the fact that only a finite number of rays
can be sampled from the scene. E.g. representing a high-resolution image at a lower
resolution. (downsampling)
![Page 5: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/5.jpg)
One of the causes of aliasing in computer graphics is the fact that we looses information while down-sampling the data.
![Page 6: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/6.jpg)
Technique of minimizing the distortion when representing continuous objects in discrete systems.
Left: aliased image, right: antialiased image.
focus: different sampling techniques.
![Page 7: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/7.jpg)
Because pixels are discrete, computer graphics(CG) is inherently a sampling process.
Ray tracing, and other forms of point sampling are important techniques in CG.
The purpose of ray tracing is to recreate photo-realistic 3D images on a 2D computer screen.
Because of regularly spaced samples, these techniques suffer from Aliasing.
![Page 8: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/8.jpg)
Discrepancy analysis measures sample point equi-distribution.
Gives an idea of how sampling pattern captures details in a picture.
Two low discrepancy sequences:◦ Hammersley◦ Halton
![Page 9: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/9.jpg)
Each non-negative integer k, is represented using prime base p.
So, a k-th d-dimensional Hammersely point is
Where n = total number of Hammersely points.
![Page 10: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/10.jpg)
Problem with Hammersley pointset: non-heirarchial.
Means, different values of n results in different sets of points.
Halton pointset: heirarchial
φ function is heirarchial, and so are the halton point sets.
![Page 11: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/11.jpg)
The work considers 2-D plane, and uses different prime base for the experiment.
Total number of sampled points considered = 500.
Comparison between random, Hammersley, and Halton point sets.
![Page 12: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/12.jpg)
![Page 13: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/13.jpg)
![Page 14: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/14.jpg)
![Page 15: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/15.jpg)
![Page 16: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/16.jpg)
![Page 17: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/17.jpg)
Solution: Scrambling – method used RR2 (reverse radix sampling)
![Page 18: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/18.jpg)
Hammersley points with p=2 gives the most uniform distributed patterns.
Halton point set gives patterns with varying uniformity and regularity.
Halton point set suffers from holes when higher dimensions (3-D or more) is considered.
![Page 19: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/19.jpg)
As p1 increases hammersley points tends to align and reduce their usefulness.
Halton point doesn’t suffer from this problem and it allows incremental sampling.
Further, author applied these methods to ray tracing applications with significant improvement in pixel error.
The complexity of both Hammersley and Halton points generation algorithms is O( NlogpN ).
![Page 20: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/20.jpg)
These sampling techniques are applied to path planning paradigm.
3 link (equal length) manipulator (robotic arm).
![Page 21: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/21.jpg)
End location: (19.501032, 9.984035)
Distance to goal: 0.499223 cm
Path length: 56.182854 cm Path steps: 53 Iterations: 3024 Used samples: 1565/13516
(11.5789 %) Computation time: 0.067694
s
End location: (20.028568, 9.795012)
Distance to goal: 0.206970 cm
Path length: 63.798946 cm
Path steps: 65 Iterations: 3185 Used samples:
1642/14230 (11.539 %) Computation time:
0.013087 s
Halton sampling Random Sampling
![Page 22: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/22.jpg)
Computer graphics Monte Carlo volume rendering
◦ Medical x-ray images◦ The quality of images is strongly influenced by
the transfer function, which maps a data value onto a sampling probability.
Quasi-Monte Carlo integration
![Page 23: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/23.jpg)
1. Robert A. Cross. Sampling patterns optimized for uniform distribution of edges. In Graphics Gems V, pages 359–363. AP Professional, 1995.
2. D. P. Dobkin and D. Eppstein. Computing the discrepancy. In Proceedings of the 9th ACM Symposium on Computational Geometry, pages 47–52, 1993.
3. D. P. Dobkin and D. P. Mitchell. Random-edge discrepancy of supersampling patterns, In Graphics Interface, pages 62–69, 1993.
4. StefanHeinrich andAlexanderKeller. Quasi-monte carlomethods in computer graphics, part i: The qmc buffer. Technical report, University of Kaiserslautern, 1994.
5. R. L. Cook, Stochastic Sampling in Computer Graphics. ACM Transactions on Graphics, Vol. 5, No. 1, pages 51-72, 1986.
6. T. T. Wong, W. S. Luk, and P. A. Heng, Sampling with Hammersley and Halton Points, Graphics tools: The jgt editors' choice, 2005.
7. KennethChiu, Peter Shirley, and ChangyawWang. Multi-jittered sampling. In GraphicsGems IV, pages 370–374. AP Professional, 1994.
![Page 24: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/24.jpg)
![Page 25: Monte Carlo Methods: Anti-aliasing in computer graphics](https://reader033.fdocuments.us/reader033/viewer/2022061304/5501811c4a7959ac638b5016/html5/thumbnails/25.jpg)