8000 [rllib] IMPALA fix no attribute '_minibatch_size' by lukaskiss222 · Pull Request #53620 · ray-project/ray · GitHub
[go: up one dir, main page]
More Web Proxy on the site http://driver.im/
Skip to content

[rllib] IMPALA fix no attribute '_minibatch_size' #53620

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

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

lukaskiss222
Copy link

Why are these changes needed?

Fix no attribute '_minibatch_size'

  • I've signed off every commit(by using the -s flag, i.e., git commit -s) in this PR.
  • I've run scripts/format.sh to lint the changes in this PR.
  • I've included any doc changes needed for https://docs.ray.io/en/master/.
    • I've added any new APIs to the API Reference. For example, if I added a
      method in Tune, I've added it in doc/source/tune/api/ under the
      corresponding .rst file.
  • I've made sure the tests are passing. Note that there might be a few flaky tests, see the recent failures at https://flakey-tests.ray.io/
  • Testing Strategy
    • Unit tests
    • Release tests
    • This PR is not tested :(

@Copilot Copilot AI review requested due to automatic review settings June 6, 2025 19:46
@lukaskiss222 lukaskiss222 requested a review from a team as a code owner June 6, 2025 19:46
Copy link
Contributor
@Copilot Copilot AI left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Pull Request Overview

Fixes an AttributeError by replacing references to the nonexistent internal _minibatch_size attribute with the public minibatch_size property in Impala’s validation logic.

  • Updated error message to use self.minibatch_size instead of self._minibatch_size.

@lukaskiss222
Copy link
Author

Plus want to verify if this code is correct:
419-422 impala.py

            if self.minibatch_size is not None and not (
                (self.minibatch_size % self.rollout_fragment_length == 0)
                and self.minibatch_size <= self.total_train_batch_size
            ):

Should not it be: ?

            if self.minibatch_size is not None and not (
                (self.rollout_fragment_length  % self.minibatch_size == 0)
                and self.minibatch_size <= self.total_train_batch_size
            ):

Swapped self.rollout_fragment_length and self.minibatch_size in modulo operation.

Copy link

This pull request has been automatically marked as stale because it has not had
any activity for 14 days. It will be closed in another 14 days if no further activity occurs.
Thank you for your contributions.

You can always ask for help on our discussion forum or Ray's public slack channel.

If you'd like to keep this open, just leave any comment, and the stale label will be removed.

@github-actions github-actions bot added the stale The issue is stale. It will be closed within 7 days unless there are further conversation label Jun 21, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
stale The issue is stale. It will be closed within 7 days unless there are further conversation
Projects
None yet
Development

Successfully merging this pull request may close these issues.

1 participant
0