Question: IN PYTHON Task 3 - Main function You are supposed to complete the main function in the utility.py file. In the main function, you are

 IN PYTHON Task 3 - Main function You are supposed to

IN PYTHON

Task 3 - Main function You are supposed to complete the main function in the utility.py file. In the main function, you are provided with all the information you need: the distribution of So given evidence, the utility table of each state, and the transition table {$0: {a : {s': P(Result(s, a) = s'a)}}}. You need to complete the two dictionaries. The keys of the first dictionary (sPrime Distribution) are all possible actions. The values are dictionaries whose keys are all possible S' given the action and values are the corresponding probability P(s'a, e). ({a:{s: P(s'a, e)}}). You will need the function getsPrimeProb- ability to complete the sPrime Distribution dictionary. The keys of the second dictionary (EU) are all possible actions. The values are the expected utility of the action. ({a: EU (ale)}). You will need the function getEU to complete the EU dictionary. Task 3 - Main function You are supposed to complete the main function in the utility.py file. In the main function, you are provided with all the information you need: the distribution of So given evidence, the utility table of each state, and the transition table {$0: {a : {s': P(Result(s, a) = s'a)}}}. You need to complete the two dictionaries. The keys of the first dictionary (sPrime Distribution) are all possible actions. The values are dictionaries whose keys are all possible S' given the action and values are the corresponding probability P(s'a, e). ({a:{s: P(s'a, e)}}). You will need the function getsPrimeProb- ability to complete the sPrime Distribution dictionary. The keys of the second dictionary (EU) are all possible actions. The values are the expected utility of the action. ({a: EU (ale)}). You will need the function getEU to complete the EU dictionary

Step by Step Solution

There are 3 Steps involved in it

1 Expert Approved Answer
Step: 1 Unlock blur-text-image
Question Has Been Solved by an Expert!

Get step-by-step solutions from verified subject matter experts

Step: 2 Unlock
Step: 3 Unlock

Students Have Also Explored These Related Databases Questions!