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

Major refactoring gymnasium et al #88

Merged
merged 20 commits into from
Sep 30, 2023
Merged
Show file tree
Hide file tree
Changes from 8 commits
Commits
Show all changes
20 commits
Select commit Hold shift + click to select a range
5a34d54
Add timer to RAM states
alexpalms Jul 14, 2023
d49629d
Major refactoring, see details below:
alexpalms Aug 2, 2023
00170d9
Add gymnasium interface
alexpalms Aug 24, 2023
6f6ddbb
Make new gymnasium-based 2.2 candidate working with SB
alexpalms Sep 4, 2023
83b90ee
Make new gymnasium-based 2.2 candidate working with SB3
alexpalms Sep 6, 2023
75cf0c5
Make new gymnasium-based 2.2 candidate working with Ray RLlib
alexpalms Sep 8, 2023
b182ccc
Fix splash screen when multiple TK windows are open
alexpalms Sep 12, 2023
fba8bed
Relax requirements, add logging in controller, refactor enumerating
alexpalms Sep 13, 2023
0770bff
Use PB type for actions space and for ram states type, acquire new ca…
alexpalms Sep 14, 2023
f46a6b2
Update settings to use None for Random values
alexpalms Sep 17, 2023
4a3b27a
Multiple changes:
alexpalms Sep 17, 2023
b1e24d2
Rework settings exposing classes directly instead of dicts
alexpalms Sep 22, 2023
292e5b0
Update sb3 make function
alexpalms Sep 22, 2023
21d0c31
Update SB interface with new settings
alexpalms Sep 23, 2023
2585777
Update lib for ray examples and dependencies versions
alexpalms Sep 23, 2023
b869c8e
Update tests and add new ones to CICD
alexpalms Sep 27, 2023
1b0412d
Restore wheel installation in CICD
alexpalms Sep 27, 2023
bc2fec4
Remove episode data loader example from tests
alexpalms Sep 27, 2023
b54a636
Update wrappers settings naming
alexpalms Sep 28, 2023
66a7f97
Update agents tests reusable tests and build docs for release branch too
alexpalms Sep 29, 2023
File filter

Filter by extension

Filter by extension


Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
170 changes: 168 additions & 2 deletions .vscode/launch.json
Original file line number Diff line number Diff line change
Expand Up @@ -10,17 +10,183 @@
"diambra_arena_gist.py",
"single_player_env.py",
"multi_player_env.py",
"wrappers_options.py"
"wrappers_options.py",
"episode_recording.py",
"episode_data_loader.py",
],
},
{
"id": "pytest_script",
"type": "pickString",
"description": "Example script:",
"default": "diambra_arena_gist.py",
"options": [
"test_gym_settings.py",
"test_imitation_learning.py",
"test_integration.py",
"test_random.py",
"test_recording_settings.py",
"test_speed.py",
"test_wrappers_settings.py",
],
},
{
"id": "game_id",
"type": "pickString",
"description": "Game ID:",
"default": "diambra_arena_gist.py",
"options": [
"doapp",
"sfiii3n",
"tektagt",
"umk3",
"samsh5sp",
"kof98umh",
],
},
{
"id": "n_players",
"type": "pickString",
"description": "Number of Players:",
"default": "1",
"options": [
"1",
"2",
],
},
{
"id": "role0",
"type": "pickString",
"description": "Role 0:",
"default": "Random",
"options": [
"P1",
"P2",
"Random",
],
},
{
"id": "role1",
"type": "pickString",
"description": "Role 1:",
"default": "Random",
"options": [
"P1",
"P2",
"Random",
],
},
{
"id": "continue_game",
"type": "pickString",
"description": "Continue Game:",
"default": "0.0",
"options": [
"0.0",
"-1.0",
"0.5",
],
},
{
"id": "no_action",
"type": "pickString",
"description": "No Action:",
"default": "0",
"options": [
{ "label": "True", "value": "1" },
{ "label": "False", "value": "0" },

],
},
{
"id": "interactive",
"type": "pickString",
"description": "Interactive:",
"default": "0",
"options": [
{ "label": "True", "value": "1" },
{ "label": "False", "value": "0" },

],
},
{
"id": "wrappers",
"type": "pickString",
"description": "Wrappers Active:",
"default": "0",
"options": [
{ "label": "True", "value": "1" },
{ "label": "False", "value": "0" },
],
},
],
"configurations": [
{
"name": "[Arena] (conda diambra-arena) Script",
"name": "[Arena] (conda diambra-arena) Examples",
"type": "python",
"request": "launch",
"program": "${workspaceFolder}/examples/${input:example_script}",
"console": "integratedTerminal",
},
{
"name": "[Arena] (conda diambra-arena) Tests",
"type": "python",
"request": "launch",
"program": "${workspaceFolder}/tests/${input:pytest_script}",
"console": "integratedTerminal",
},
{
"name": "[Arena] (conda diambra-arena) Run Engine Mock",
"type": "python",
"request": "launch",
"program": "${workspaceFolder}/tests/run_engine_mock.py",
"args": [
"--gameId", "${input:game_id}",
"--nPlayers", "${input:n_players}",
"--role0", "${input:role0}",
"--role1", "${input:role1}",
"--character0", "Random",
"--character1", "Random",
"--character0_2", "Random",
"--character1_2", "Random",
"--character0_3", "Random",
"--character1_3", "Random",
"--difficulty", "0",
"--stepRatio", "3",
//"--continueGame", "${input:continue_game}",
"--noAction", "${input:no_action}",
//"--interactive", "${input:interactive}",
"--render", "1",
],
"console": "integratedTerminal",
},
{
"name": "[Arena] (conda diambra-arena) Manual Random Test",
"type": "python",
"request": "launch",
"program": "${workspaceFolder}/tests/man_test_random.py",
"args": [
"--gameId", "${input:game_id}",
"--nPlayers", "${input:n_players}",
"--role0", "${input:role0}",
"--role1", "${input:role1}",
"--character0", "Random",
"--character1", "Random",
"--character0_2", "Random",
"--character1_2", "Random",
"--character0_3", "Random",
"--character1_3", "Random",
"--difficulty", "0",
"--stepRatio", "3",
"--nEpisodes", "1",
"--continueGame", "${input:continue_game}",
"--actionSpace", "discrete",
"--noAction", "${input:no_action}",
"--interactive", "${input:interactive}",
"--render", "1",
"--wrappers", "${input:wrappers}",
],
"console": "integratedTerminal",
}
]
}
32 changes: 32 additions & 0 deletions .vscode/settings.json
Original file line number Diff line number Diff line change
@@ -0,0 +1,32 @@
{
"python.testing.cwd": "${workspaceFolder}/tests/",
"python.testing.pytestArgs": [
"--rootdir",
"${workspaceFolder}/tests",
"-s"
],
"python.testing.unittestEnabled": false,
"python.testing.pytestEnabled": true,
"editor.tokenColorCustomizations": {
"textMateRules": [
{
"scope": "googletest.failed",
"settings": {
"foreground": "#f00"
}
},
{
"scope": "googletest.passed",
"settings": {
"foreground": "#0f0"
}
},
{
"scope": "googletest.run",
"settings": {
"foreground": "#0f0"
}
}
]
}
}
1 change: 0 additions & 1 deletion diambra/arena/__init__.py
Original file line number Diff line number Diff line change
@@ -1,3 +1,2 @@
from .make_env import make
from .arena_imitation_learning_gym import ImitationLearning, ImitationLearningHardcore
from .utils.gym_utils import available_games, game_sha_256, check_game_sha_256, get_num_envs
Loading