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

[2048] Fix bug in legal action mask #1049

Merged
merged 10 commits into from
Nov 6, 2023
Merged

[2048] Fix bug in legal action mask #1049

merged 10 commits into from
Nov 6, 2023

Conversation

sotetsuk
Copy link
Owner

@sotetsuk sotetsuk commented Sep 26, 2023

Legal action mask is wrong. In this case, agent cannot select action left (0) but currently it's legal action.

    [[ 8  2  0  0]
     [ 8  0  0  0]
     [ 8  0  0  0]
     [ 8  0  0  0]]
  • Fix above bug
  • legal action mask at init state

@sotetsuk sotetsuk changed the title [2048] Add test case for legal action mask [2048] Fix bug in legal action mask Sep 26, 2023
@codecov
Copy link

codecov bot commented Sep 26, 2023

Codecov Report

Merging #1049 (51eab94) into main (2af728c) will decrease coverage by 0.47%.
Report is 1 commits behind head on main.
The diff coverage is 100.00%.

@@            Coverage Diff             @@
##             main    #1049      +/-   ##
==========================================
- Coverage   88.05%   87.58%   -0.47%     
==========================================
  Files          54       54              
  Lines        5908     5913       +5     
==========================================
- Hits         5202     5179      -23     
- Misses        706      734      +28     
Files Coverage Δ
pgx/play2048.py 95.87% <100.00%> (+0.27%) ⬆️

... and 4 files with indirect coverage changes

Copy link
Collaborator

@OkanoShinri OkanoShinri left a comment

Choose a reason for hiding this comment

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

確かに……
できた気になっていました🙇

@sotetsuk sotetsuk merged commit 16d2450 into main Nov 6, 2023
3 of 4 checks passed
@sotetsuk sotetsuk deleted the sotetsuk/test/2048 branch November 6, 2023 06:55
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Projects
None yet
Development

Successfully merging this pull request may close these issues.

2 participants