Posts

Showing posts from January, 2019

Terraform Part 2

In the previous post ' Intro to Terraform ', I provided an introduction to Terraform. In this post, I will be digging a little bit deeper into how Terraform could be used in real world usecases. How to use organize Terraform files? We can organize Terraform files so that, each component which we would provision would go into its own .tf file. That way, we can have a modularized approach. provider.tf This file would have the provider configuration details, so that any change to provider related config could be done in one place. vars.tf This file would have the variables used by every different file. We can variabilize different parts of our infrastructure configuration, like for eg, the CIDR ranges which will be used in VPC and subnet. This way, we can parameterize our provisioning code. One tf file per Component: We can have one .tf file per component, for instance, a vpc.tf file, a subnet.tf file etc. This way we can isolate changes. Data Selecto

Bayes Theorem

Image
In this article, let us try to understand Bayes Theorem. This article has been inspired by the two videos provided in References section. The illustrations used here are my own. Bayes theorem helps us draw inferences from data. It also challenges our beliefs which could be often biased. Let us say that we came across a group of athletes from many countries with the athletes from top 2 or 3 popular sports from those countries.  We will consider a group of athletes who play either soccer or basketball. The height of one of the athletes is more than 7 feet. What do you think this athlete plays?  Soccer or Basketball. Our intuition definitely says that he must be playing basketball. Now, let us do the math. The most popular sport played across the globe is soccer (No offense to Basketball!). Let us say we have total of 100 athletes and 90% of them play soccer and 10% play basketball. That means 90 athletes play soccer. Now let us see how many of soccer players are more tha