diambra/arena

Unable to Run DIAMBRA Env on Mac

Closed this issue · 1 comments

Hello Team,

I'm attempting to run the DIAMBRA environment locally on my MacBook Air, but it's failing with the following error. I've followed the setup instructions provided here: https://docs.diambra.ai/gettingstarted/#running-the-environment

Screenshot 2024-03-30 at 4 59 20 PM

The Docker container was successfully initiated as well.

Screenshot 2024-03-30 at 5 03 56 PM

colosseum diambra run -r ~/.diambra/roms diambra_arena_gist.py
🖥️ Starting DIAMBRA environment:
🖥️ logged in
v2.2: Pulling from diambra/engine
Digest: sha256:6b5df5c9522553a4505bf0b6b0f837dd2f945de1b0b6390d83fdf24e317de643
Status: Image is up to date for diambra/engine:v2.2
Stored credentials found.
Authorization granted.
Server listening on 0.0.0.0:50051
🖥️ DIAMBRA environment started
INFO:diambra.arena.engine.interface:Trying to connect to DIAMBRA Engine server (timeout=600s)...
INFO:diambra.arena.engine.interface:... done.
🏟️ (8dd2) (0)Overwriting sys_settings provided by the user with command line / CLI ones
(0)Provided by the user:
🏟️ (8dd2)
🏟️ (8dd2) (0)Set via command line / CLI:
🏟️ (8dd2) emu_pipes_path: "/tmp/DIAMBRA/"
roms_path: "/opt/diambraArena/roms/"
binary_path: "/opt/diambraArena/mame/"
username: "deepesh"


  .:-:-**#*#####+***+=-:.

..-++####+#################=+=:.
:+############################-.
.-+#############################=.
.-
###########################+.
.=######++======++##########=. ........ ... ....... ........... ........ ........ ............ ............ ...........
-=------:---------=########- .------..-----:. .------. .-----------. --------. :-------- --------------:. --------------:. :----------:
.:--------:---------:=#######* .------..-------..------. :-----:-----:. ---------. .--------- ------:..:-----: ------:..------: .------:-----.
.:------::---::--------:+#######..------. .------..------. .------.:-----. ----------.---------- ------:..------. ------: :-----. .:-----:.------.
:-----::.:---:-----::---:######* .------. .------..------. .:-----: .------. ------:-------------- ------::-----:.. ------:.-----:. .------..------.
.--:.. . :::.:.---.-:---.#####- .------. .------..------. .------.::------: ------:.-----.:------ ------: :-----: ------:.:------: .------:.:-------.
..:..:::.:::.::....:.::--:####
. .------::------:..------..------:.:::------. ------: .---. :-----: -------::------: ------: ------: :------..::------:
.-::::::---...:--. .-.:-::=###+. .::::::::::::.. .::::::..::::::. .::::::. ::::::. .:. ::::::: ::::::::::::::. ::::::: ::::::: ::::::. .::::::
.--:. .:--...::. ..::+####:
:--:.. .---:...:. .:+
+:.
.:---:::----.. .... .:.
.:------:..:... :.
....... ..:. ..

                                                               DIAMBRA™ | Dueling AI Arena
                                                          https://diambra.ai - info@diambra.ai

                               Usage of this software is subject to our Terms of Use described at https://diambra.ai/terms

                                                           DIAMBRA, Inc. © Copyright 2018-2024

(0)Environment initialization ...
🏟️ (8dd2) Error: Cannot open "/opt/diambraArena/roms/doapp.zip": No such file or directory.
You need to put the Game rom file in the roms directory.


    Contact support on DIAMBRA Discord Server: https://diambra.ai/discord
                                    AND / OR

Open a ticket on our GitHub repository issue Tracker: https://github.com/diambra/arena/issues


Traceback (most recent call last):
File "/Users/dmaheshwari/Documents/genai/colosseum/env/lib/python3.9/site-packages/diambra/arena/engine/interface.py", line 31, in env_init
response = self.client.EnvInit(env_settings_pb)
File "/Users/dmaheshwari/Documents/genai/colosseum/env/lib/python3.9/site-packages/grpc/_channel.py", line 1176, in call
return _end_unary_response_blocking(state, call, False, None)
File "/Users/dmaheshwari/Documents/genai/colosseum/env/lib/python3.9/site-packages/grpc/_channel.py", line 1005, in _end_unary_response_blocking
raise _InactiveRpcError(state) # pytype: disable=not-instantiable
grpc._channel._InactiveRpcError: <_InactiveRpcError of RPC that terminated with:
status = StatusCode.CANCELLED
details = "Cannot open "/opt/diambraArena/roms/doapp.zip": No such file or directory.
You need to put the Game rom file in the roms directory.
"
debug_error_string = "UNKNOWN:Error received from peer {grpc_message:"Cannot open "/opt/diambraArena/roms/doapp.zip": No such file or directory.\nYou need to put the Game rom file in the roms directory.\n", grpc_status:1, created_time:"2024-03-30T16:43:01.919338+05:30"}"

During handling of the above exception, another exception occurred:

Traceback (most recent call last):
File "/Users/dmaheshwari/Documents/genai/colosseum/diambra_arena_gist.py", line 34, in
main()
File "/Users/dmaheshwari/Documents/genai/colosseum/diambra_arena_gist.py", line 6, in main
env = diambra.arena.make("doapp", render_mode="human")
File "/Users/dmaheshwari/Documents/genai/colosseum/env/lib/python3.9/site-packages/diambra/arena/make_env.py", line 43, in make
env = DiambraGym1P(env_settings)
File "/Users/dmaheshwari/Documents/genai/colosseum/env/lib/python3.9/site-packages/diambra/arena/arena_gym.py", line 222, in init
super().init(env_settings)
File "/Users/dmaheshwari/Documents/genai/colosseum/env/lib/python3.9/site-packages/diambra/arena/arena_gym.py", line 38, in init
self.env_info = self.arena_engine.env_init(self.env_settings.get_pb_request(init=True))
File "/Users/dmaheshwari/Documents/genai/colosseum/env/lib/python3.9/site-packages/diambra/arena/engine/interface.py", line 33, in env_init
raise Exception(CONNECTION_FAILED_ERROR_TEXT)
Exception: DIAMBRA Arena failed to connect to the Engine Server. Are you running it with DIAMBRA CLI: diambra run python script.py?

See the docs (https://docs.diambra.ai) for additional details, or join DIAMBRA Discord Server (https://diambra.ai/discord) for support.
🖥️ Couldn't run: exit status 1

Hi @deepesh17feb , thanks for reaching out.

As the environment says:

status = StatusCode.CANCELLED
details = "Cannot open "/opt/diambraArena/roms/doapp.zip": No such file or directory.
You need to put the Game rom file in the roms directory.
"

it was not able to find the "doapp.zip" rom in the roms directory.

In fact, your check-roms command shows that you only have one and is Street Fighter III, while the diambra_arena_gist.py example by default launched Dead Or Alive:

env = diambra.arena.make("doapp", render_mode="human")

So, you have to either add Dead Or Alive rom to the roms folder, or change the environment name in diambra_arena_gist.py to launch SFIII

Please confirm this solves the error and if so close the issue, thanks!