Metadata-Version: 2.1
Name: karasu
Version: 0.0.3
Summary: Karasu Engine games as Python environments: pixel observations, exact ground truth, seeded and vectorised
Keywords: reinforcement-learning,environment,gymnasium,game-engine,research
Classifier: Programming Language :: Python :: 3
Classifier: Programming Language :: C++
Classifier: Topic :: Scientific/Engineering :: Artificial Intelligence
Classifier: Operating System :: MacOS
Classifier: Operating System :: Microsoft :: Windows
Classifier: Operating System :: POSIX :: Linux
Project-URL: Homepage, https://github.com/prooheckcp/KarasuEngine
Project-URL: Source, https://github.com/prooheckcp/KarasuEngine
Requires-Python: >=3.11
Requires-Dist: numpy>=1.24
Provides-Extra: gym
Requires-Dist: gymnasium>=0.29; extra == "gym"
Provides-Extra: stats
Requires-Dist: pandas>=2; extra == "stats"
Requires-Dist: matplotlib>=3.7; extra == "stats"
Description-Content-Type: text/markdown

# karasu

Games made in the [Karasu Engine](https://github.com/prooheckcp/KarasuEngine) editor, as Python environments for
machine-learning research: pixel observations, exact ground truth (what is walkable, where the agents are), seeded
episodes, and many copies stepped at once with the Gymnasium vector API.

```bash
pip install karasu
```

```python
import karasu

env = karasu.Env(karasu.examples.path("meadow_topdown"), seed=1)   # a demo, downloaded once
obs = env.reset()                    # {"rgb": (H, W, 3), "mask": (H, W), "info": {...}}
obs = env.step(karasu.LEFT)

envs = karasu.VecEnv("path/to/my_game", 16, threads=8)   # N copies, the Gymnasium vector API

import karasu.env3d                  # 3D projects: rgb, depth, segmentation, walkable
import karasu.stats as st            # what runs recorded: st.load(path).table("Episode").df()
```

- Projects are the folders the editor makes. `karasu new my_game --template topdown` starts one from a template.
- Game scripts written in Python run in your interpreter: a game that imports `torch` needs `torch` installed here.
- 3D environments need a GPU (Metal, Vulkan or Direct3D 12). 2D ones run anywhere.
- `import walkenv` still works (the old name) and warns.

The editor, the docs and the source: <https://github.com/prooheckcp/KarasuEngine>.
