Skip to main content

Simulation environment for data collection.

Project description

Datadynamics

pypi Test Status Documentation Status code style: black Imports: isort pre-commit License

Datadynamics is a Python library and environment for simulating (multi-agent) data collection dynamics. The library is built on top of PettingZoo and is distributed under the BSD 3-Clause License.

The documentation is available at lfwa.github.io/datadynamics/.

Installation

Datadynamics can be installed via PyPI from Python 3.10 and higher:

$ pip install datadynamics

Alternatively, you can install from source by downloading the latest release or by cloning the GitHub repository, navigating into the directory, and installing via Poetry: poetry install.

Usage

Visit the documentation site at lfwa.github.io/datadynamics/ for full usage guides.

Quick Start

# See tutorials/collector/wrapper_example.py
from datadynamics.environments import collector_v0
from datadynamics.policies import greedy_policy_v0

env = collector_v0.env(
    n_points=300, n_agents=2, max_collect=[120, 180], render_mode="human"
)
policy = greedy_policy_v0.policy(env=env)
env.reset()
for agent in env.agent_iter():
    observation, reward, termination, truncation, info = env.last()
    action = policy.action(observation, agent)
    env.step(action)

Project details


Download files

Download the file for your platform. If you're not sure which to choose, learn more about installing packages.

Source Distribution

datadynamics-0.0.1.tar.gz (29.9 kB view hashes)

Uploaded Source

Built Distribution

datadynamics-0.0.1-py3-none-any.whl (39.7 kB view hashes)

Uploaded Python 3

Supported by

AWS AWS Cloud computing and Security Sponsor Datadog Datadog Monitoring Fastly Fastly CDN Google Google Download Analytics Microsoft Microsoft PSF Sponsor Pingdom Pingdom Monitoring Sentry Sentry Error logging StatusPage StatusPage Status page