Skip to content

Commit

Permalink
small adjustment of docs
Browse files Browse the repository at this point in the history
  • Loading branch information
Stefan Schneider committed Jan 12, 2022
1 parent dfb2b75 commit ff33bce
Show file tree
Hide file tree
Showing 5 changed files with 28 additions and 10 deletions.
2 changes: 1 addition & 1 deletion README.md
Original file line number Diff line number Diff line change
Expand Up @@ -34,7 +34,7 @@ Documentation and API: [ReadTheDocs](https://mobile-env.readthedocs.io/en/latest

### From PyPI (Recommended)

The simplest option is to install the latest release of `mobile-env` from PyPI using pip:
The simplest option is to install the latest release of `mobile-env` from [PyPI](https://pypi.org/project/mobile-env/) using pip:

```bash
pip install mobile-env
Expand Down
10 changes: 8 additions & 2 deletions docs/components.md
Original file line number Diff line number Diff line change
@@ -1,8 +1,14 @@
(components)=

# Modules
# Packages

## Simulation
`mobile-env` is structured into four main packages, each with multiple modules: Core, handlers, scenarios, and wrappers.
These packages are described in the following.


## Core

The core package contains the core simulation logic of `mobile-env`.

The [base environment](https://mobile-env.readthedocs.io/en/latest/source/mobile_env.core.html#mobile_env.core.base.MComCore) class simulates cell assignment of many user equipments (UEs) to possibly multiple basestations (BSs) in a mobile communication setting. Our simulation is mainly composed of five components that implement their functionality in a replacable manner:

Expand Down
14 changes: 12 additions & 2 deletions docs/examples.md
Original file line number Diff line number Diff line change
Expand Up @@ -2,13 +2,14 @@

# Examples

## Examples on Google Colab
## Example on Google Colab
We provide an in-depth example of mobile-env's usage on Google Colab! The notebook shows how to train multi-agent reinforcement learning policies with [RLlib](https://docs.ray.io/en/stable/rllib.html) and centralized control policies with [stable-baselines3](https://stable-baselines3.readthedocs.io/en/master/index.html).


[![Open in colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/stefanbschneider/mobile-env/blob/master/examples/tutorial.ipynb)
[![Open in colab](https://colab.research.google.com/assets/colab-badge.svg)](https://colab.research.google.com/github/stefanbschneider/mobile-env/blob/master/examples/demo.ipynb)

## Environment Creation
`mobile-env` follows the OpenAI Gym interface.
Here is an example of how mobile-env's environments can be created:
```python
import gym
Expand All @@ -23,4 +24,13 @@ env = gym.make('mobile-large-central-v0')
# small environment; multi-agent control
env = gym.make('mobile-large-ma-v0')
...

# then run the environment
obs = env.reset()
done = False

while not done:
action = ... # Your agent code here
obs, reward, done, info = env.step(action)
env.render()
```
6 changes: 4 additions & 2 deletions docs/index.rst
Original file line number Diff line number Diff line change
Expand Up @@ -9,12 +9,14 @@
:target: https://mobile-env.readthedocs.io/en/latest/?badge=latest
.. |Publish| image:: https://github.com/stefanbschneider/mobile-env/actions/workflows/python-publish.yml/badge.svg
:target: https://github.com/stefanbschneider/mobile-env/actions/workflows/python-publish.yml
.. |Colab| image:: https://colab.research.google.com/assets/colab-badge.svg
:target: https://colab.research.google.com/github/stefanbschneider/mobile-env/blob/master/examples/demo.ipynb

|Python package| |Documentation Status| |Publish|
|Python package| |Documentation Status| |Publish| |Colab|

Welcome to Mobile-Env's documentation!
======================================
This project open-sources a minimalist environment for cell selection in wireless mobile networks.
This project is a minimalist, open-source environment for cell selection in wireless mobile networks.

This documentation provides:

Expand Down
6 changes: 3 additions & 3 deletions docs/installation.md
Original file line number Diff line number Diff line change
Expand Up @@ -7,11 +7,11 @@ This project requires python3 (>=3.7)
## Stable release
To install the latest stable version with `pip`, run:
```bash
pip install mobile_env
pip install -U mobile-env
```

## Development version
The development version can be installed with `poetry`:
The development version can be installed after cloning the [GitHub repository](https://github.com/stefanbschneider/mobile-env):
```bash
poetry add git+https://github.com/stefanbschneider/mobile-env
pip install -e .
```

0 comments on commit ff33bce

Please sign in to comment.