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.2.tar.gz (16.4 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.2-py3-none-any.whl (17.5 kB view details)

Uploaded Python 3

File details

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

File metadata

  • Download URL: dpct_env-0.0.2.tar.gz
  • Upload date:
  • Size: 16.4 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.2.tar.gz
Algorithm Hash digest
SHA256 c52796013c4512ab59df18a7da2218b10e19160ad72f49ed6be59292dc8e4021
MD5 e6e86ae6f1f9230402f8d8d9e19a2dc0
BLAKE2b-256 0a23dcf969604416f4fada9201c0e3255350e52ef82a68749694573bee74b329

See more details on using hashes here.

File details

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

File metadata

  • Download URL: dpct_env-0.0.2-py3-none-any.whl
  • Upload date:
  • Size: 17.5 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.2-py3-none-any.whl
Algorithm Hash digest
SHA256 070c6574383bab74cd0fe93975865a4f7449ba19d587ba53296b6a9b1cef24a7
MD5 9df9673da2f24ea024ffd3fc391d72a0
BLAKE2b-256 777229f76b93d4f60103c9a10930fae8570748bc170b56809f0a506599fe8b71

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