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

How to run python example on Linux #5

Closed
4SkyNet opened this issue Nov 23, 2016 · 10 comments
Closed

How to run python example on Linux #5

4SkyNet opened this issue Nov 23, 2016 · 10 comments
Labels

Comments

@4SkyNet
Copy link

4SkyNet commented Nov 23, 2016

Hi, I've got some troubles with the given example in:

~/doc/examples

I try to run:

python_example.py path_to_game_rom

But it fails with issues wrt argv[2], where I should provide some core_file (*.so)

I try again:

python_example.py path_to_game_rom path_to_librle_c.so

But it fails again with this error:

Failed to load symbol 'retro_init'': ../../rle_python_interface/librle_c.so: undefined symbol: retro_init

It seems to that there should be some corrections wrt symbols
(it can be linux specific as previous commit to setup.py from my buddy)

@nadavbh12
Copy link
Owner

The .so file should be of the core (Atari or Snes).
For snes it should be in snes9x2010/snes9x2010-libretro.so.

I'll add the instructions to help avoid confusion.

@4SkyNet
Copy link
Author

4SkyNet commented Nov 23, 2016

Thx, it loads! ...but then I've got a segmentation fault

Warning: couldn't load settings file:
R.L.E: Retro Learning Environment (version 0.5.0)
[Based upon the Arcade Learning Environment (A.L.E)]
[Powered by LibRetro]
Use -help for help screen.
[inf] Frontend supports RGB565 - will use that instead of XRGB1555.

Sound buffer size: 128000 (32000 samples)
Core loaded

[inf] No ROM file header found.

Map_LoROMMap

PPU.RenderSub = 0
PPU.FullClipping = 1
Settings.Transparency = 1
Settings.SpeedhackGameID = 0
PPU.SFXSpeedupHack = 0
coldata_update_screen = 1
[inf] "MORTAL KOMBAT" [checksum ok] LoROM, 16Mbits, ROM, NTSC, SRAM:0Kbits, ID:____, CRC32:DEF42945
Running ROM file...
Random seed is 123

Process finished with exit code 139 (interrupted by signal 11: SIGSEGV)

@nadavbh12
Copy link
Owner

Sorry for the delayed response, didn't notice your comment earlier.
Please give it another try and let me know if you still have this issue.

@tohnperfect
Copy link

tohnperfect commented Feb 6, 2017

I also got the same error with v1.0.2 .

Warning: couldn't load settings file:
R.L.E: Retro Learning Environment (version 1.0.0)
[Based upon the Arcade Learning Environment (A.L.E)]
[Powered by LibRetro]
Use -help for help screen.
[inf] Frontend supports RGB565 - will use that instead of XRGB1555.
Sound buffer size: 128000 (32000 samples)
Core loaded
[inf] No ROM file header found.
Map_LoROMMap
PPU.RenderSub = 0
PPU.FullClipping = 1
Settings.Transparency = 1
Settings.SpeedhackGameID = 7
PPU.SFXSpeedupHack = 0
coldata_update_screen = 0
[inf] "SUPER MARIOWORLD" [checksum ok] LoROM, 4Mbits, ROM+RAM+BAT, NTSC, SRAM:16Kbits, ID:____, CRC32:B19ED489
Running ROM file...
Random seed is 123
Segmentation fault (core dumped)

@nadavbh12
Copy link
Owner

Please make sure that the name of the rom on your file system is identical to that in the rom file.

@tohnperfect
Copy link

tohnperfect commented Feb 6, 2017

Thank you very much @nadavbh12, I am able run the example code now.

Supposedly, tutorial, more examples, and how to use the RLE can be found in the ALE?

@nadavbh12
Copy link
Owner

You're welcome.
Not sure what you're asking. Could you rephrase that?

@tohnperfect
Copy link

tohnperfect commented Feb 6, 2017 via email

@nadavbh12
Copy link
Owner

Basically any repository you find online which uses ALE can easily be replaced by RLE.
You can check out this fork of deep_q_rl to run DQN with RLE.

@tohnperfect
Copy link

tohnperfect commented Feb 6, 2017 via email

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants