melee-env
melee-env wraps the fantastic libmelee as a more gym-esque environment with less boilerplate and setup. Additionally, melee-env provides a convenient and highly flexible framework for creating your own agents. For more information on these topics and melee-env, see the README in the agents folder.
Code example:
from melee import enums
from melee_env.env import MeleeEnv
from melee_env.agents.basic import *
import argparse
players = [Rest(), NOOP(enums.Character.FOX)]
env = MeleeEnv('path/to/iso', players, fast_forward=True)
episodes = 10; reward = 0
env.start()
for episode in range(episodes):
gamestate, done = env.setup(enums.Stage.BATTLEFIELD)
while not done:
for i in range(len(players)):
players[i].act(gamestate)
gamestate, done = env.step()
Video Demonstration
This library has been designed with flexibility in mind. The action space, observation space, and the agents are completely modular, and there are only a few requirements to build your own.
Note
This library requires Slippi, which in turn requires an SSBM 1.02 NTSC/PAL ISO. This library does not and will not distribute this. You must acquire this on your own!
Installation
Install from pip: pip install melee-env. Test by running agents_example.py --iso=/path/to/your/iso
Platform support
- Linux
- Windows
Metadata
Release files for melee-env 0.30.0
For a detailed explanation of source distributions (sdists) and built distributions (wheels), please see the package formats documentation.
Source distribution (sdist)
| File | Size | Uploaded | |
|---|---|---|---|
| melee-env-0.30.0.tar.gz | 13.2 kB | Details |
Built distribution (wheel)
| File | Interpreter | ABI | Platform | Reset |
|---|---|---|---|---|
| melee_env-0.30.0-py3-none-any.whl | Python 3 | none | any | Details |
Total release size: 28.4 kB
Release files / melee-env-0.30.0.tar.gz
| Download URL | melee-env-0.30.0.tar.gz |
|---|---|
| Size | 13.2 kB |
| Tags | Source |
|
SHA-256 checksum How to use checksums |
ebbfc0901985de0f1cb77703a5e237e512de032aedaeac7581412b9965c74192
|
|
BLAKE2b-256 checksum How to use checksums |
f24e0a5c1aec923c50fbe59074fb3adafc7755cb0e514eaa8216b46e1ecb8daa
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.9.6
|
Release files / melee_env-0.30.0-py3-none-any.whl
| Download URL | melee_env-0.30.0-py3-none-any.whl |
|---|---|
| Size | 15.3 kB |
| Tags | Python 3 |
|
SHA-256 checksum How to use checksums |
22165417e5e90cf8a32a26514aee69b9fb9dc4770b9bee0a9cb7e7b8db0dab5b
|
|
BLAKE2b-256 checksum How to use checksums |
76cf951073766c680d0697dab645d872d1803876e390128eae856eea1fde04be
|
| Upload date | |
|
Uploaded using Trusted Publishing? What is trusted publishing? |
No |
| Uploaded via |
twine/3.4.1 importlib_metadata/4.6.1 pkginfo/1.7.0 requests/2.25.1 requests-toolbelt/0.9.1 tqdm/4.61.2 CPython/3.9.6
|