Probability: Theory and practice Philipp Slusallek Karol - - PowerPoint PPT Presentation

probability theory and practice
SMART_READER_LITE
LIVE PREVIEW

Probability: Theory and practice Philipp Slusallek Karol - - PowerPoint PPT Presentation

Probability: Theory and practice Philipp Slusallek Karol Myszkowski Gurprit Singh 1 Realistic Image Synthesis SS2018 A la Carte algebra and measure - Random Variables Probability distribution functions (PDFs and PMFs)


slide-1
SLIDE 1

Realistic Image Synthesis SS2018

Probability: Theory and practice

Philipp Slusallek Karol Myszkowski Gurprit Singh

  • 1
slide-2
SLIDE 2

Realistic Image Synthesis SS2018

A la Carte

2

  • algebra and measure
  • Random Variables
  • Probability distribution functions (PDFs and PMFs)
  • Conditional and Marginal PDFs
  • Expected value and Variance of a random variable

σ-

slide-3
SLIDE 3

Realistic Image Synthesis SS2018

Motivation: Ray Tracing

3

slide-4
SLIDE 4

Realistic Image Synthesis SS2018 4

Scene designed by David Coeurjolly

Ray Tracing

Image Plane

slide-5
SLIDE 5

Realistic Image Synthesis SS2018 5

Ray Tracing

Image Plane Scene designed by David Coeurjolly

slide-6
SLIDE 6

Realistic Image Synthesis SS2018 6

Direct Illumination

4 spp

Image rendered using PBRT

slide-7
SLIDE 7

Realistic Image Synthesis SS2018 7

Direct Illumination

256 spp

Image rendered using PBRT

slide-8
SLIDE 8

Realistic Image Synthesis SS2018 8

Direct and Indirect Illumination

4096 spp

Image rendered using PBRT

slide-9
SLIDE 9

Realistic Image Synthesis SS2018 9

Path Tracing

slide-10
SLIDE 10

Realistic Image Synthesis SS2018 10

Path Tracing

slide-11
SLIDE 11

Realistic Image Synthesis SS2018 11

Path Tracing

slide-12
SLIDE 12

Realistic Image Synthesis SS2018 12

Path Tracing

slide-13
SLIDE 13

Realistic Image Synthesis SS2018 13

4 spp

Direct and Indirect Illumination

Image rendered using PBRT

slide-14
SLIDE 14

Realistic Image Synthesis SS2018

How can we analyze the noise present in the images ?

14

slide-15
SLIDE 15

Realistic Image Synthesis SS2018

Probability Theory and/or Number Theory

15

slide-16
SLIDE 16

Realistic Image Synthesis SS2018

Probability Theory

16

slide-17
SLIDE 17

Realistic Image Synthesis SS2018

  • Discrete Probability Space
  • Continuous Probability Space

17

slide-18
SLIDE 18

Realistic Image Synthesis SS2018

Rolling a fair dice

18

Ω = {1, 2, 3, 4, 5, 6}

  • Finite outcomes: discrete random experiment
  • Can ask the outcome is a number: 1 or 6
  • Can ask the outcome is a subset, e.g. all prime numbers:

{2, 3, 5}

slide-19
SLIDE 19

Realistic Image Synthesis SS2018

Rolling a fair dice

19

Ω = {1, 2, 3, 4, 5, 6}

  • R1: Apart from elementary values, the focus lies on subsets of
  • R2:

A probability assigns each element or each subset of a positive real value 


Ω Ω

The first requirement leads to the concept of -algebra

σ

The second to the mathematical construct of a measure

slide-20
SLIDE 20

Realistic Image Synthesis SS2018

Random number in [0,1]

20

1

  • Uncountably infinite outcomes: continuous random experiment
  • Does not make sense to ask for one number as output, e.g. 0.245
  • We need to ask for the probability of a region, e.g. [0.2,0.4] or [0.36,0.89]

slide-21
SLIDE 21

Realistic Image Synthesis SS2018

Random number in [0,1]

21

  • R1: As in discrete case, focus lies on subsets of , also called events
  • R2: A probability assigns each subset of a positive real value.

Ω Ω

The first requirement leads to the concept of Borel -algebra

σ

The second to the mathematical construct of a Lebesgue measure

1

slide-22
SLIDE 22

Realistic Image Synthesis SS2018

  • Algebra

22

  • Mathematical construct used in probability and measure theory
  • 1. Take on the role of system of events in probability theory
  • Simply spoken: Collection of subsets of a given set
  • A. A non-empty collection of subsets of that is closed under the set

theoretical operations of: countable unions, countable intersections, and complement

σ

slide-23
SLIDE 23

Realistic Image Synthesis SS2018

  • Algebra

23

  • For discrete set :
  • 1. The sigma-algebra corresponds to the power set of omega (set of all

subsets)

σ

slide-24
SLIDE 24

Realistic Image Synthesis SS2018

  • Algebra

24

  • For discrete set :
  • 1. The sigma-algebra corresponds to the power set of omega (set of all

subsets)

σ

Σ = {{φ}, {0}, {1}, {0, 1}} Ω = {0, 1}

slide-25
SLIDE 25

Realistic Image Synthesis SS2018

  • Algebra

25

  • For discrete set :
  • 1. The sigma-algebra corresponds to the power set of omega (set of all

subsets)

σ

Ω = {a, b, c, d} Σ = {{φ}, {0}, {1}, {0, 1}} Ω = {0, 1} Σ = {{φ}, {a, b}, {c, d}, {a, b, c, d}}

slide-26
SLIDE 26

Realistic Image Synthesis SS2018

  • Algebra

26

σ

  • For continuous set :
  • A. The associated sigma algebras are the Borel sets over , i.e., the collection
  • f all open sets over omega that can be generated via countable unions,

countable intersections, and complement of open sets

slide-27
SLIDE 27

Realistic Image Synthesis SS2018

  • Algebra

27

σ

  • For continuous set :
  • A. The associated sigma algebras are the Borel sets over , i.e., the collection
  • f all open sets over omega that can be generated via countable unions,

countable intersections, and complement of open sets

I = [p, q), p, q ∈ R

Fixed half-interval

slide-28
SLIDE 28

Realistic Image Synthesis SS2018

  • Algebra

28

σ

  • For continuous set :
  • A. The associated sigma algebras are the Borel sets over , i.e., the collection
  • f all open sets over omega that can be generated via countable unions,

countable intersections, and complement of open sets

I = [p, q), p, q ∈ R T = [α, β) ⊆ [p, q)

Fixed half-interval Collection of all half-intervals

slide-29
SLIDE 29

Realistic Image Synthesis SS2018

  • Algebra

29

σ

  • For continuous set :
  • A. The associated sigma algebras are the Borel sets over , i.e., the collection
  • f all open sets over omega that can be generated via countable unions,

countable intersections, and complement of open sets

I = [p, q), p, q ∈ R T = [α, β) ⊆ [p, q)

Fixed half-interval Collection of all half-intervals

Here, is not a -algebra because, generally speaking, neither the union nor the difference of two half-intervals is a half-interval.

T σ

slide-30
SLIDE 30

Realistic Image Synthesis SS2018

  • Algebra

30

σ

It is the mathematical construct that allows defining a measure

slide-31
SLIDE 31

Realistic Image Synthesis SS2018

Measure

31

  • In probability theory, it plays the role of a probability distribution
  • A real-valued set function defined on a sigma-algebra that assigns each

subset of a sigma-algebra a non-negative real number.

  • A sigma-additive set function: i.e., the measure of the union of disjoint

sets is equal to the sum of the measures of the individual sets

slide-32
SLIDE 32

Realistic Image Synthesis SS2018

Lebesgue Measure

32

  • Standard way of assigning measure to subsets of n-dimensional

Euclidean space.

  • For n = 1,2 or 3, it coincides with the standard measure of length, area or

volume, respectively.

Length Area Volume

slide-33
SLIDE 33

Realistic Image Synthesis SS2018

Random Variable

33

  • Central concept in probability theory
  • Enables to construct a simpler probability space from a rather complex
  • ne
  • Correspond to a measurable function defined on a -algebra that

assigns each element to a real number

σ

slide-34
SLIDE 34

Realistic Image Synthesis SS2018

Random Variable

34

  • A random variable is a value chosen by some random process
  • Random variables are always drawn from a domain: discrete (e.g., a fixed

set of probabilities) or continuous (e.g., real numbers)

  • Applying a function to a random variable results in a new random

variable

X f X Y = f(X)

slide-35
SLIDE 35

Realistic Image Synthesis SS2018

Discrete Probability Space

35

slide-36
SLIDE 36

Realistic Image Synthesis SS2018

Discrete Random Variable

36

  • Random variable (RV):
  • Probabilities:

{p1, p2, . . . , pn}

N

X

i=1

pi = 1

X : Ω → E Ω = {x1, x2, . . . , xn}

slide-37
SLIDE 37

Realistic Image Synthesis SS2018

Discrete Random Variable

37

  • Example: Rolling a Die

  • Probability of each event:


pi = 1/6 for i = 1, …, 6

x1 = 1, x2 = 2, x3 = 3, x4 = 4, x5 = 5, x6 = 6

P(X = i) = 1 6

slide-38
SLIDE 38

Realistic Image Synthesis SS2018

Discrete Random Variable

38

P(2 ≤ X ≤ 4) =

4

X

i=2

P(X = i) =

4

X

i=2

1 6 = 1 2

slide-39
SLIDE 39

Realistic Image Synthesis SS2018

Probability mass function

  • PMF is a function that gives the probability that a discrete

RV is exactly equal to some value.

  • PMF is different from PDF (probability density function)

which is for continuous RVs.

39

slide-40
SLIDE 40

Realistic Image Synthesis SS2018

Probability mass function

40

1 6 1 6 1 6 1 6 1 6 1 6

0.4 0.15 0.3 0.05 0.1

Constant PMF Non-uniform PMF

slide-41
SLIDE 41

Realistic Image Synthesis SS2018

Continuous Probability Space

41

slide-42
SLIDE 42

Realistic Image Synthesis SS2018

Continuous Random Variable

42

  • In rendering, discrete random variables are less common than continuous

random variables

  • Continuous random variables take on values that ranges of continuous

domains (e.g. real numbers or directions on the unit sphere)

  • A particularly important random variable is the canonical uniform random

variable, which we write as ξ

slide-43
SLIDE 43

Realistic Image Synthesis SS2018

Continuous Random Variable

43

1

ξ ∈ [0, 1)

slide-44
SLIDE 44

Realistic Image Synthesis SS2018 44

  • We can take a continuous, uniformly distributed random variable

and map to a discrete random variable, choosing if:

ξ ∈ [0, 1) Xi

Continuous Random Variable

1

slide-45
SLIDE 45

Realistic Image Synthesis SS2018 45

  • We can take a continuous, uniformly distributed random variable

and map to a discrete random variable, choosing if:

ξ ∈ [0, 1) Xi

i−1

X

j=1

pj < ξ ≤

i

X

j=1

pj

Xi = {1, 2, 3, 4, 5, 6}

Continuous Random Variable

1

slide-46
SLIDE 46

Realistic Image Synthesis SS2018

Continuous Random Variable

Image rendered using PBRT

Visual Break

slide-47
SLIDE 47

Realistic Image Synthesis SS2018

Continuous Random Variable

Image rendered using PBRT

Visual Break

slide-48
SLIDE 48

Realistic Image Synthesis SS2018

Continuous Random Variable

pi = Φi P

j Φj

Φi

  • For lighting application, we might want to define probability of sampling

illumination from each light source in the scene based on its power Here, the probability is relative to the total power

48

slide-49
SLIDE 49

Realistic Image Synthesis SS2018

Probability Density Functions

49

slide-50
SLIDE 50

Realistic Image Synthesis SS2018

Probability density function

  • Consider a continuous RV that ranges over real numbers: , where

the probability of taking on any particular value is proportional to the value

2

[0, 2) x 2 − x

  • It is twice as likely for this random variable to take on a value around 0 as

it is to take around 1, and so forth.

50

x

slide-51
SLIDE 51

Realistic Image Synthesis SS2018

Probability density function

  • The probability density function (PDF) formalizes this idea: it describes

the relative probability of a RV taking on a particular value.

  • Unlike PMF

, the values of the PDFs are not the probabilities as such: a PDF must be integrated over an interval to yield a probability

51

slide-52
SLIDE 52

Realistic Image Synthesis SS2018 52

p(x) = ( 1 x ∈ [0, 1)

  • therwise

For uniform random variables: For non-uniform random variables:

p(x) could be any function

Probability density function

slide-53
SLIDE 53

Realistic Image Synthesis SS2018 53

constant pdf

Uniform distribution Non-uniform distribution

Probability density function

slide-54
SLIDE 54

Realistic Image Synthesis SS2018 54

constant pdf

Uniform distribution Non-uniform distribution

Probability density function

slide-55
SLIDE 55

Realistic Image Synthesis SS2018 55

p(x) > 0

Z ∞

−∞

p(x)dx = 1

Some properties of PDFs:

Probability density function

slide-56
SLIDE 56

Realistic Image Synthesis SS2018 56

Z b

a

p(x)dx = 1 x ∈ [a, b)

constant pdf

b a

Probability density function

slide-57
SLIDE 57

Realistic Image Synthesis SS2018 57

Z b

a

p(x)dx = 1 x ∈ [a, b)

constant pdf

b a

Z b

a

C dx = 1

C Z b

a

dx = 1 C(b − a) = 1 p(x) = C C C = 1 b − a

Probability density function

slide-58
SLIDE 58

Realistic Image Synthesis SS2018 58

x ∈ [a, b)

constant pdf

b a

Z b

a

p(x)dx = 1

Z b

a

C dx = 1

C Z b

a

dx = 1 C(b − a) = 1 p(x) = 1 b − a p(x) = C C

Probability density function

C = 1 b − a

slide-59
SLIDE 59

Realistic Image Synthesis SS2018 59

Cumulative distribution function

  • The PDF is the derivative of the random variable's CDF:

p(x)

slide-60
SLIDE 60

Realistic Image Synthesis SS2018 60

Cumulative distribution function

  • The PDF is the derivative of the random variable's CDF:

p(x) p(x) = dP(x) dx

: cumulative distribution function (CDF) , also called cumulative density function

P(x)

slide-61
SLIDE 61

Realistic Image Synthesis SS2018 61

Cumulative distribution function

  • The PDF is the derivative of the random variable's CDF:

p(x) p(x) = dP(x) dx P(x) P(x) = Z x

−∞

p(x)dx

: cumulative distribution function (CDF) , also called cumulative density function

slide-62
SLIDE 62

Realistic Image Synthesis SS2018 62

1

Cumulative distribution function

P(x) = Z x

−∞

p(x)dx p(x) = ( 1 x ∈ [0, 1)

  • therwise

constant pdf

slide-63
SLIDE 63

Realistic Image Synthesis SS2018 63

Non-constant pdf

1

Cumulative distribution function

p(x) P(x) = Z x

−∞

p(x)dx

slide-64
SLIDE 64

Realistic Image Synthesis SS2018 64

Image rendered using PBRT

Visual Break

slide-65
SLIDE 65

Realistic Image Synthesis SS2018 65

Probability: Integral of PDF

P(x ∈ [a, b]) = Z b

a

p(x)dx

  • Given the arbitrary interval in the domain, integrating the PDF gives

the probability that a RV lies inside that interval:

[a, b] p(x)

a b

slide-66
SLIDE 66

Realistic Image Synthesis SS2018

Examples: Sampling PDFs

66

slide-67
SLIDE 67

Realistic Image Synthesis SS2018

Constant Sampling PDFs

67

Random 2D

1 1

Jittered 2D

1 1

slide-68
SLIDE 68

Realistic Image Synthesis SS2018 68

Sampling a unit domain with uniform random samples

1

ξ ∈ [0, 1)

Random 1D

Constant Sampling PDFs

slide-69
SLIDE 69

Realistic Image Synthesis SS2018 69

Sampling a unit domain with uniform random samples

Random 1D

Constant Sampling PDFs

1

ξ ∈ [0, 1)

Random 1D

slide-70
SLIDE 70

Realistic Image Synthesis SS2018 70

Sampling a unit domain with uniform random samples

p(x) = ( C x ∈ [0, 1)

  • therwise

1

ξ ∈ [0, 1)

Random 1D

Constant Sampling PDFs

slide-71
SLIDE 71

Realistic Image Synthesis SS2018 71

Sampling each stratum with uniform random samples

1

Jittered 1D

Constant Sampling PDFs

slide-72
SLIDE 72

Realistic Image Synthesis SS2018 72

Sampling each stratum with uniform random samples

1

Jittered 1D

∆ = 1 N

Constant Sampling PDFs

slide-73
SLIDE 73

Realistic Image Synthesis SS2018 73

Sampling each stratum with uniform random samples

1

Jittered 1D

∆ = 1 N

i

Constant Sampling PDFs

p(xi) = ???

Probability density of generating a sample in an -th stratum is given by:

i

slide-74
SLIDE 74

Realistic Image Synthesis SS2018 74

Constant Sampling PDFs

1

Jittered 1D

∆ = 1 N

Probability density of generating a sample in an -th stratum is given by:

i i

Sampling each stratum with uniform random samples

p(xi) = ( N x ∈ [ i

N , i+1 N )

  • therwise
slide-75
SLIDE 75

Realistic Image Synthesis SS2018 75

1

Jittered 1D

∆ = 1 N

i

Joint PDFs

First, we divide the domain into equal strata. Second, we sample the domain. This implies that two samples are correlated to each other.

slide-76
SLIDE 76

Realistic Image Synthesis SS2018 76

1

Jittered 1D

∆ = 1 N

i

Joint PDFs

p(xi, xj) = ???

what is the joint PDF for jittered sampling ?

i j

For two different strata and

,

First, we divide the domain into equal strata. Second, we sample the domain. This implies that two samples are correlated to each other.

slide-77
SLIDE 77

Realistic Image Synthesis SS2018

Conditional and Marginal PDFs

77

slide-78
SLIDE 78

Realistic Image Synthesis SS2018

Joint PDF

For two random variables and , the joint PDF is given by:

78

X1 X2 p(x1, x2)

slide-79
SLIDE 79

Realistic Image Synthesis SS2018

Joint PDF

For two random variables and , the joint PDF is given by:

79

X1 X2 p(x1, x2) p(x1, x2) = p(x2|x1)p(x1)

slide-80
SLIDE 80

Realistic Image Synthesis SS2018

Joint PDF

For two random variables and , the joint PDF is given by:

80

X1 X2 X1 = x1 X2 = x2 p(x1, x2) p(x1, x2) = p(x2|x1)p(x1)

where,

p(x2|x1) p(x1)

: conditional density function : marginal density function

slide-81
SLIDE 81

Realistic Image Synthesis SS2018

Joint PDF

For two random variables and , the joint PDF is given by:

81

X1 X2 X1 = x1 X2 = x2 p(x1, x2) p(x1, x2) = p(x2|x1)p(x1)

where,

p(x2|x1) p(x1)

: conditional density function : marginal density function

slide-82
SLIDE 82

Realistic Image Synthesis SS2018

Joint PDF

For two random variables and , the joint PDF is given by:

82

X1 X2 X1 = x1 X2 = x2 p(x1, x2) p(x1, x2) = p(x1|x2)p(x2)

where,

p(x1|x2) p(x2)

: conditional density function : marginal density function

slide-83
SLIDE 83

Realistic Image Synthesis SS2018

Marginal PDF

83

p(x1) = Z

R

p(x1, x2)dx2 p(x2) = Z

R

p(x1, x2)dx1

We integrate out one of the variable.

slide-84
SLIDE 84

Realistic Image Synthesis SS2018

Conditional PDF

84

p(x1|x2) = p(x1, x2) p(x2) p(x2|x1) = p(x1, x2) p(x1)

The conditional density function is the density function for given that some particular has been chosen.

xi xj

slide-85
SLIDE 85

Realistic Image Synthesis SS2018

Conditional PDF

85

If both and are independent then:

p(x1|x2) = p(x1) p(x2|x1) = p(x2) x1 x2

slide-86
SLIDE 86

Realistic Image Synthesis SS2018

Conditional PDF

86

If both and are independent then:

p(x1|x2) = p(x1) p(x2|x1) = p(x2) x1 x2 p(x1, x2) = p(x1)p(x2)

That gives:

slide-87
SLIDE 87

Realistic Image Synthesis SS2018 87

1

Joint PDF of Jittered 1D Sampling

p(xi, xj) = ???

what is the joint PDF for jittered sampling ?

i j

For two different strata and

,

i

j

slide-88
SLIDE 88

Realistic Image Synthesis SS2018 88

1

Joint PDF of Jittered 1D Sampling

p(x1, x2) = p(x1|x2)p(x2) i

j

slide-89
SLIDE 89

Realistic Image Synthesis SS2018 89

1

Joint PDF of Jittered 1D Sampling

p(x1, x2) = p(x1|x2)p(x2) p(x1, x2) = p(x1)p(x2) i

j

slide-90
SLIDE 90

Realistic Image Synthesis SS2018 90

1

Joint PDF of Jittered 1D Sampling

p(xi, xj) = ( p(xi)p(xj) i 6= j

  • therwise

i

j

slide-91
SLIDE 91

Realistic Image Synthesis SS2018 91

1

Joint PDF of Jittered 1D Sampling

p(xi, xj) = ( p(xi)p(xj) i 6= j

  • therwise

p(xi, xj) = ( N 2 i 6= j

  • therwise

p(xi) = N

Since,

i

j

slide-92
SLIDE 92

Realistic Image Synthesis SS2018 92

Image rendered using PBRT

Visual Break

slide-93
SLIDE 93

Realistic Image Synthesis SS2018

Expected Value

93

slide-94
SLIDE 94

Realistic Image Synthesis SS2018

Expected value

94

  • Expected value: average value of the variable
  • example: rolling a die

E[X] = 1 · 1 6 + 2 · 1 6 + 3 · 1 6 + 4 · 1 6 + 5 · 1 6 + 6 · 1 6 = 3.5

E[X] =

N

X

i=1

xipi

slide-95
SLIDE 95

Realistic Image Synthesis SS2018

Expected value

95

  • Expected value: average value of the variable
  • example: rolling a die

E[X] = 1 · 1 6 + 2 · 1 6 + 3 · 1 6 + 4 · 1 6 + 5 · 1 6 + 6 · 1 6 = 3.5

E[X] =

N

X

i=1

xipi

slide-96
SLIDE 96

Realistic Image Synthesis SS2018

Expected value

96

  • Properties:

E[X + Y ] = E[X] + E[Y ] E[X + c] = E[X] + c E[cX] = cE[X]

slide-97
SLIDE 97

Realistic Image Synthesis SS2018

Expected value

97

  • Properties:

E[X + Y ] = E[X] + E[Y ] E[X + c] = E[X] + c E[cX] = cE[X]

slide-98
SLIDE 98

Realistic Image Synthesis SS2018

Expected value

98

  • Properties:

E[X + Y ] = E[X] + E[Y ] E[X + c] = E[X] + c E[cX] = cE[X]

slide-99
SLIDE 99

Realistic Image Synthesis SS2018

Estimating expected values

  • To estimate the expected value of a variable
  • choose a set of random values based on the probability
  • average their results
  • example: rolling a die
  • roll 3 times: {3, 1, 6} → E[x] ≈ (3 + 1 + 6)/3 = 3.33
  • roll 9 times: {3, 1, 6, 2, 5, 3, 4, 6, 2} → E[x] ≈ 3.51

99

E[X] ≈ 1 N

N

X

i=1

xi

slide-100
SLIDE 100

Realistic Image Synthesis SS2018

Estimating expected values

  • To estimate the expected value of a variable
  • choose a set of random values based on the probability
  • average their results
  • example: rolling a die
  • roll 3 times: {3, 1, 6} → E[x] ≈ (3 + 1 + 6)/3 = 3.33
  • roll 9 times: {3, 1, 6, 2, 5, 3, 4, 6, 2} → E[x] ≈ 3.51

100

E[X] ≈ 1 N

N

X

i=1

xi

slide-101
SLIDE 101

Realistic Image Synthesis SS2018

Estimating expected values

  • To estimate the expected value of a variable
  • choose a set of random values based on the probability
  • average their results
  • example: rolling a die
  • roll 3 times: {3, 1, 6} → E[x] ≈ (3 + 1 + 6)/3 = 3.33
  • roll 9 times: {3, 1, 6, 2, 5, 3, 4, 6, 2} → E[x] ≈ 3.51

101

E[X] ≈ 1 N

N

X

i=1

xi

slide-102
SLIDE 102

Realistic Image Synthesis SS2018

Estimating expected values

  • To estimate the expected value of a variable
  • choose a set of random values based on the probability
  • average their results
  • example: rolling a die
  • roll 3 times: {3, 1, 6} → E[x] ≈ (3 + 1 + 6)/3 = 3.33
  • roll 9 times: {3, 1, 6, 2, 5, 3, 4, 6, 2} → E[x] ≈ 3.51

102

E[X] ≈ 1 N

N

X

i=1

xi

slide-103
SLIDE 103

Realistic Image Synthesis SS2018

Estimating expected values

  • To estimate the expected value of a variable
  • choose a set of random values based on the probability
  • average their results
  • example: rolling a die
  • roll 3 times: {3, 1, 6} → E[x] ≈ (3 + 1 + 6)/3 = 3.33
  • roll 9 times: {3, 1, 6, 2, 5, 3, 4, 6, 2} → E[x] ≈ 3.51

103

E[X] ≈ 1 N

N

X

i=1

xi

slide-104
SLIDE 104

Realistic Image Synthesis SS2018

Estimating expected values

  • To estimate the expected value of a variable
  • choose a set of random values based on the probability
  • average their results
  • example: rolling a die
  • roll 3 times: {3, 1, 6} → E[x] ≈ (3 + 1 + 6)/3 = 3.33
  • roll 9 times: {3, 1, 6, 2, 5, 3, 4, 6, 2} → E[x] ≈ 3.51

104

E[X] ≈ 1 N

N

X

i=1

xi

slide-105
SLIDE 105

Realistic Image Synthesis SS2018

Law of large numbers

  • By taking infinitely many samples, the error between the

estimate and the expected value is statistically zero

  • the estimate will converge to the right value

105

slide-106
SLIDE 106

Realistic Image Synthesis SS2018

Variance

106

slide-107
SLIDE 107

Realistic Image Synthesis SS2018

Variance

107

  • Variance: how much different from the average

σ2[X] = E[(X − E[X])2] = E[X2 + E[X]2 − 2XE[X]] = E[X2] + E[E[X]2] − 2E[X]E[E[X]]] = E[X2] + E[X]2 − 2E[X]2 = E[X2] − E[X]2

slide-108
SLIDE 108

Realistic Image Synthesis SS2018

Variance

108

  • Variance: how much different from the average

σ2[X] = E[(X − E[X])2] = E[X2 + E[X]2 − 2XE[X]] = E[X2] + E[E[X]2] − 2E[X]E[E[X]]] = E[X2] + E[X]2 − 2E[X]2 = E[X2] − E[X]2

slide-109
SLIDE 109

Realistic Image Synthesis SS2018

Variance

109

  • Variance: how much different from the average

σ2[X] = E[(X − E[X])2] = E[X2 + E[X]2 − 2XE[X]] = E[X2] + E[E[X]2] − 2E[X]E[E[X]]] = E[X2] + E[X]2 − 2E[X]2 = E[X2] − E[X]2

slide-110
SLIDE 110

Realistic Image Synthesis SS2018

Variance

110

  • Variance: how much different from the average

σ2[X] = E[(X − E[X])2] = E[X2 + E[X]2 − 2XE[X]] = E[X2] + E[E[X]2] − 2E[X]E[E[X]]] = E[X2] + E[X]2 − 2E[X]2 = E[X2] − E[X]2

slide-111
SLIDE 111

Realistic Image Synthesis SS2018

Variance

111

  • Variance: how much different from the average

σ2[X] = E[(X − E[X])2] = E[X2 + E[X]2 − 2XE[X]] = E[X2] + E[E[X]2] − 2E[X]E[E[X]]] = E[X2] + E[X]2 − 2E[X]2 = E[X2] − E[X]2

slide-112
SLIDE 112

Realistic Image Synthesis SS2018

Variance

112

  • Variance: how much different from the average

σ2[X] = E[(X − E[X])2] = E[X2 + E[X]2 − 2XE[X]] = E[X2] + E[E[X]2] − 2E[X]E[E[X]]] = E[X2] + E[X]2 − 2E[X]2 = E[X2] − E[X]2

σ2[X] = E[X2] − E[X]2

slide-113
SLIDE 113

Realistic Image Synthesis SS2018

Variance

113

  • example: Rolling a die
  • variance:

σ2[X] = . . . = 2.917

σ2[X] = E[X2] − E[X]2 E[X] = 1 · 1 6 + 2 · 1 6 + 3 · 1 6 + 4 · 1 6 + 5 · 1 6 + 6 · 1 6 = 3.5

slide-114
SLIDE 114

Realistic Image Synthesis SS2018

Variance

114

  • example: Rolling a die
  • variance:

σ2[X] = . . . = 2.917

σ2[X] = E[X2] − E[X]2 E[X] = 1 · 1 6 + 2 · 1 6 + 3 · 1 6 + 4 · 1 6 + 5 · 1 6 + 6 · 1 6 = 3.5

slide-115
SLIDE 115

Realistic Image Synthesis SS2018

Variance

115

  • example: Rolling a die
  • variance:

σ2[X] = . . . = 2.917

σ2[X] = E[X2] − E[X]2

slide-116
SLIDE 116

Realistic Image Synthesis SS2018

Monte Carlo Integration

116

I = Z

D

f(x) dx Z

Slide after Wojciech Jarosz

slide-117
SLIDE 117

Image rendered using PBRT

Questions ?