Skip to main content

Environment-specific plugins for the DPCT framework

Project description

dpct-env

Environment-specific plugins for the DPCT framework.

This package provides:

  • Fitness functions — class-based fitness computation for specific environments
  • Results processors — Comet ML logging for environment-specific metrics
  • Environment evaluations — documentation on environment suitability for DPCT

Installation

pip install dpct-env

Usage

Fitness Functions

from dpct_env.fitness import get_fitness_functions, ControlEffortFitness

# Get all fitness functions registered for CartPole-v1
fns = get_fitness_functions("CartPole-v1")

# Compute a fitness value
fitness = fns["stability_ratio"](observation_history=obs, action_history=acts)

# Use a fitness function directly
effort_fn = ControlEffortFitness(mode="changes")
fitness = effort_fn(observation_history=obs, action_history=acts)

Results Processors

from dpct_env.processors import create_environment_results_processor

processor = create_environment_results_processor("CartPole-v1")
processor.log_results(experiment=exp, individual=ind, history=history)

Registered Environments

Environment Fitness Functions
CartPole-v1 control_effort, observation_variance, stability_ratio
MountainCar-v0 control_effort, height_achieved
Acrobot-v1 control_effort, height_achieved
Pendulum-v1 control_effort, observation_variance

Architecture

dpct-env  ──depends on──▶  dpct
     │                        │
     └── provides plugins ───┘

dpct-env is a pure plugin package — it imports from dpct but dpct never imports from dpct-env. This keeps the core framework clean while allowing environment-specific functionality to evolve independently.

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

dpct_env-0.0.1.tar.gz (12.8 kB view details)

Uploaded Source

Built Distribution

If you're not sure about the file name format, learn more about wheel file names.

dpct_env-0.0.1-py3-none-any.whl (13.7 kB view details)

Uploaded Python 3

File details

Details for the file dpct_env-0.0.1.tar.gz.

File metadata

  • Download URL: dpct_env-0.0.1.tar.gz
  • Upload date:
  • Size: 12.8 kB
  • Tags: Source
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for dpct_env-0.0.1.tar.gz
Algorithm Hash digest
SHA256 997947561b7d5078b2b4e546acfd78b0c2f5ab269836d58e92019fd827e079a9
MD5 b5f5f5bf7868aa72e73bb5e55aa3dc3c
BLAKE2b-256 f84c31237a286a1882f41702cf047f09ff10c9e773787d5c9e4c13bb06791266

See more details on using hashes here.

File details

Details for the file dpct_env-0.0.1-py3-none-any.whl.

File metadata

  • Download URL: dpct_env-0.0.1-py3-none-any.whl
  • Upload date:
  • Size: 13.7 kB
  • Tags: Python 3
  • Uploaded using Trusted Publishing? No
  • Uploaded via: twine/6.2.0 CPython/3.11.15

File hashes

Hashes for dpct_env-0.0.1-py3-none-any.whl
Algorithm Hash digest
SHA256 e59f88f9e0319015929de83c32421ecce3e04ac9e1e0f2150bea5ac194f765aa
MD5 ffc86413721eee5863b1079619d7e3fe
BLAKE2b-256 01d326e73d75d49e97cf308a2eae0bcb7afe9023d47d5eafe0704898eaf55581

See more details on using hashes here.

Supported by

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