![]() Again, with much waving of my hands in the air, this should extend to more than two distributions. However, since we have a batch of two distributions, this contributes to the final shape of the tensor. In this case, we may argue that per distribution, the elementary shape of the event did not change. The illustration below should help clarify how this is different from the first. Now, what if I had a second Gaussian, say, with a different mean and/or variance? If I were to draw one number from the first Gaussian alongside one number from the second Gaussian, and then concatenate them into a vector, we can represent this as us drawing numbers from independent Gaussians. With my hands waving in the air, I will claim that this holds true even with K samples drawn from the distribution. However, the elementary event of drawing a single number did not fundamentally change when we drew two numbers, as we merely repeated the same event to draw two. What if we were to draw two numbers from this one Gaussian? We could use a vector with two slots to represent those draws. ![]() Over the course of this blog post, the shape concepts will be disambiguated sit tight and enjoy the ride! The distribution we are drawing from is on the left, and a draw is represented by a line (on the same numerical axis as the probability distribution), and the event shape, batch shape and sample shape shown to their right, followed by a "plain English" description. If we drew out the distribution, and drew out the process of drawing numbers from the distribution, it might look like the following: In tensor space, a scalar is a rank 0 tensor, and this colloquially means that there’s no dimensions involved. Drawing one number from the standard Gaussian yields a scalar. Let’s start by thinking about a single draw from a standard Gaussian. Let’s start by thinking about a few questions involving the most venerable distribution of them all: the Gaussian, also known as the Normal distribution. I wanted to share a bit about something new about tensors that I learned here: the different types of shapes involved in a probabilistic programming language. Yet, communicating clearly about tensors is important, because if problems can be cast into a tensor-space operation, vectorization can help speed up many operations that we wish to handle. Prior to this summit, it never dawned on me how interfacing tensors with probability distributions could be such a minefield of overloaded ideas and terminology. I’m here with the PyMC4 dev team and Tensorflow Probability developers Rif, Brian and Chris in Google Montreal, and have found the time thus far to be an amazing learning opportunity.
0 Comments
Leave a Reply. |