Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Incorrect reward for blue agent reaching max_steps #10

Closed
john-cardiff opened this issue Sep 6, 2022 · 1 comment
Closed

Incorrect reward for blue agent reaching max_steps #10

john-cardiff opened this issue Sep 6, 2022 · 1 comment
Assignees
Labels
bug Something isn't working fix_version:1.1.0 Fixed in version 1.1.0

Comments

@john-cardiff
Copy link

if self.network_interface.reward_end_multiplier:

It should be the following.

            if self.network_interface.reward_end_multiplier:
                # FIXED
                reward = self.network_interface.reward_success * (
                    len(self.network_interface.get_nodes(filter_true_safe=True))
                    / self.network_interface.get_number_of_nodes()
                )
                # incorrect below
                # reward = self.network_interface.reward_end_multiplier * (
                #     len(self.network_interface.get_nodes(filter_true_safe=True))
                #     / self.network_interface.get_number_of_nodes()
                # )

since in the NetworkInterface class the variables are defined as following (although their names should likely be swapped).

    self.reward_success = self.reward_settings["rewards_for_reaching_max_steps"]
    self.reward_end_multiplier = self.reward_settings[
        "end_rewards_are_multiplied_by_end_state"
    ]
@jamesshort1
Copy link
Collaborator

Added as a new IDT Jira issue (AIDT-64)

@ChrisMcCarthyDev ChrisMcCarthyDev added the bug Something isn't working label Dec 2, 2022
@ChrisMcCarthyDev ChrisMcCarthyDev self-assigned this Feb 23, 2023
@ChrisMcCarthyDev ChrisMcCarthyDev added the fix_version:1.1.0 Fixed in version 1.1.0 label Feb 23, 2023
ChrisMcCarthyDev pushed a commit that referenced this issue Mar 8, 2023
…eps (GitHub Issue #10)

Correct calculation for the reward multiplier.
Was multiplying a boolean instead of the reward for reaching max steps
ChrisMcCarthyDev pushed a commit that referenced this issue Jun 5, 2023
…eps (GitHub Issue #10)

Correct calculation for the reward multiplier.
Was multiplying a boolean instead of the reward for reaching max steps
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
bug Something isn't working fix_version:1.1.0 Fixed in version 1.1.0
Projects
None yet
Development

No branches or pull requests

3 participants