Skip to main content

Solve the weather problem to predict the possibility of a rain happening under known parameters for e.g., temperature, humidity, wind flow, sunny or cloudy etc. using Bayesian Learning.

 

Experiment-2

Objective: Solve the weather problem to predict the possibility of a rain happening under known parameters for e.g., temperature, humidity, wind flow, sunny or cloudy etc. using Bayesian Learning.

Theory: The basic idea of Bayesian networks (BNs) (BNs) is to reproduce the most important dependencies and independencies among a set of variables in a graphical form (a directed acyclic graph) which is easy to understand and interpret. Let us consider the subset of climatic stations shown in the graph in Fıgure, where the variables (rainfall) are represented pictorially by a set of nodes; one node for each variable (for clarity of exposition, the set of nodes is denoted {y1, yn}). These nodes are connected by arrows, which represent a cause and

effect relationship. That is, if there is an arrow from node yi to node yj , we say that yi is the cause of yj , or equivalently, yj is the effect of yi. Another popular terminology of this is to say that yi is a parent of yj or yj is a child of yi. For example, in Figure, the nodes Gijon and Amieva and

Proaza are a child of Gijon and Rioseco (the set of parents of a node yi is denoted by πi). Directed graphs provide a simple defınition of independence (d-separation) based on the existence or not of certain paths between the variables.

The dependency/independency structure displayed by an acyclic directed graph can be also expressed in terms of a the Joint Probability Distribution (JPD) factorized as a product of several conditional distributions as follows:

Pr(y1,y2, …., yn) = n∏i=1 P(yi | Ï€i)

Therefore, the independencies from the graph are easily translated to the probabilistic model in a sound form. For instance, the JPD of a BN defıned by the graph given in Fıgure requires the specifıcation of 100 conditional probability tables, one for each variable conditioned to its parents’ set. Hereafter we shall consider rainfall discretized into three different states (0=“no rain”, 1=“weak rain”, 2=“heavy rain”), associated with the thresholds 0, 2, and 10 mm, respectively.



Procedure:


Learning Bayesian Networks from Data-

In addition to the graph structure, a BN requires that we specify the conditional probability of each node given its parents. However, in many practical problems, we do not know neither the complete topology of the graph, nor some of the required probabilities. For this reason, several methods have been recently introduced for learning the graphical structure (structure learning) and estimating probabilities (parametric learning) from data. A learning algorithm consists of two parts:

  1. A quality measure, which is used for computing the quality of the candidate BNs. This is a global measure, since it measures both the quality of the graphical structure and the quality of the estimated parameters.
  2. A search algorithm, which is used to effıciently search the space of possible BNs to fınd the one with highest quality. Note that the number of all possible networks, even for a small number of variables and, therefore, the search space is huge.


Among the different quality measures proposed in the literature the basic idea of Bayesian quality measures is to assign to every BN a quality value that is a function of the posterior probability distribution of the available data D = {y 1, …, y 100} (with the index t running daily from 1979 to 1993), given the BN (M,θ) with network structure M and the corresponding estimated probabilities θ. The posterior probability distribution p(M, θ|D) is calculated as follows:




Geiger and Heckerman consider multinomial networks and assume certain hypothesis about the prior distributions of the parameters, leading to the quality measure

where n is the number of variables, ri is the cardinal of the i-th variable, si the number of realizations of the parent’s set ∏i , ηijk are the “a priori” Dirichlet hyper-parameters for the conditional distribution of node i, Nijk is the number of realizations in the database consistent with yi = j and Ï€i = k, Nik is the number of realizations in the database consistent with Ï€i = k and Г is the gamma function.

  1. Inference- Once a model describing the relationships among the set of variables has been selected, it can then be used to answer queries when evidence becomes available.
  1. Validation of the Bayesian Network Forecast Model- To check the quality of BN in a simple case, we shall apply this methodology to a nowcasting problem. In this case we are given a forecast in a given subset of stations and we need to infer a prediction for the remaining stations in the network. To this aim, consider that we are given predictions in the fıve stations of the primary network. These predictions shall be plugged in the network as evidence, obtaining the probabilities for the remaining stations in the secondary network.
  1. Connecting With Numerical Atmospheric Models- Since we are interested in rainfall forecasts, we shall use the gridded forecasts of total precipitation given by the operative ECMWF model (these values are obtained by adding both the convective and the large scale precipitation outputs). The forecasts are obtained 24 hours ahead; therefore, they give a numeric estimation of the future precipitation pattern (one day ahead) on a coarse-grained resolution grid.

Output:

Bayesian network of precipitation grid points and local precipitation at the network of local stations.

Conclusion: We have used bayesian network learning and show their applicability for local weather forecasting and downscaling. The preliminary results presented how such models can be built and how they can be used for performing inferen

Comments

Popular posts from this blog

The Future of Web Development: Why Next.js is Going Viral

  Are you ready to level up your web development game? Look no further than Next.js, the latest sensation in the world of web development that's taking the industry by storm. With its powerful features, flexibility, and performance optimizations, Next.js is becoming the go-to framework for building modern web applications. In this blog post, we'll explore why Next.js is going viral and how it's changing the landscape of web development. Supercharged Performance: One of the main reasons why Next.js is making waves is its superior performance capabilities. With built-in optimizations like automatic static site generation (SSG) and server-side rendering (SSR), Next.js allows you to create blazing-fast web applications that load quickly and deliver seamless user experiences. This is especially important in today's fast-paced digital world, where users demand instant gratification and have little patience for slow-loading websites. Flexibility and Scalability: Next.js provid...

Importants Links of Leetcode

  Here are all the important discussion posts which contain brief descriptions about a topic with its problem list. Recursion:- A.   https://leetcode.com/tag/recursion/discuss/1733447/Become-Master-In-Recursion Binary Tree and Binary Search Tree:- A.   https://leetcode.com/tag/binary-tree/discuss/1212004/Binary-Trees-study-guide B.   https://leetcode.com/tag/binary-tree/discuss/1820334/Become-Master-in-Tree C.   https://leetcode.com/tag/binary-tree/discuss/1094690/Views-and-Traversal-of-binary-tree-or-Important-topics-or-Must-Read-%3A- ) Dynamic Programming:- A.   https://leetcode.com/discuss/study-guide/458695/Dynamic-Programming-Patterns B.   https://leetcode.com/tag/dynamic-programming/discuss/1437879/Dynamic-Programming-Patterns C.   https://leetcode.com/tag/dynamic-programming/discuss/662866/DP-for-Beginners-Problems-or-Patterns-or-Sample-Solutions D.   https://leetcode.com/tag/dynamic-programming/discuss/1050391/Must-do-Dynamic-programm...

The Ultimate Guide: How to Become a Tech YouTuber

 The Ultimate Guide: How to Become a Tech YouTuber Are you passionate about technology and want to share your knowledge with others? Becoming a tech YouTuber can be a rewarding and exciting venture that allows you to create content about your favorite gadgets, software, and tech-related topics. With millions of viewers and subscribers on YouTube, the potential for success is immense. However, starting a tech YouTube channel requires careful planning, creativity, and dedication. In this blog, we will provide you with the ultimate guide on how to become a tech YouTuber. Identify Your Niche: Technology is a broad field, and it's essential to identify your specific niche before starting your YouTube channel. Consider what aspects of technology you are most passionate about and have expertise in. It could be smartphone reviews, software tutorials, gaming, programming, or any other tech-related topic. Choosing a specific niche will help you target a particular audience and create content...