<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def get_reward_function(self):
 """ Returns the reward function as nested dict in the case of table- type parameter and a nested structure in case of decision diagram parameter Example -------- [{'Var': 'reward_rover', 'Parent': ['action_rover', 'rover_0', 'rock_0'], 'Type': 'TBL', 'Parameter': [{'Instance': ['ame', 's1', '*'], 'ValueTable': ['10']}, ] }] """

        reward_function = []
        for variable in self.network.findall('RewardFunction'):
            for var in variable.findall('Func'):
                func = defaultdict(list)
                func['Var'] = var.find('Var').text
                func['Parent'] = var.find('Parent').text.split()
                if not var.find('Parameter').get('type'):
                    func['Type'] = 'TBL'
                else:
                    func['Type'] = var.find('Parameter').get('type')
                func['Parameter'] = self.get_parameter(var)
                reward_function.append(func)

        return reward_function