Documentation Overview¶
This document provides a quick index of all available documentation and what each covers.
Documentation Structure¶
Entry Points (Start Here!)¶
Start here based on your learning style:
- Gentle Introduction - New users
- Basic concepts of Petri Nets and Action-Evolution Petri Nets
- How to create your first environment
- Step-by-step tutorial
-
Perfect for: Complete beginners
-
Complete Example - Practical learners
- Full end-to-end example with all components
- Real-world scenario (Supply Chain)
- Shows best practices
-
Perfect for: Those who learn by doing
-
Algorithms Guide - Algorithm enthusiasts
- Detailed explanation of PPO-Clip, PPO-Penalty and PG
- Hyperparameter tuning guide
- When to use each algorithm
- Perfect for: Understanding algorithm details
Core Concepts¶
These documents explain key concepts and features:
Agents Guide - PPOAgent: Standard policy gradient agent - Custom solver creation - Agent comparison and selection - When to use which agent - ~40 minutes read
Advanced Features - Graph Neural Networks (GNNs) for observations - Parallelization and performance optimization - Custom reward functions - ~45 minutes read
Specialized Topics¶
Net-Factored Credit (NF-GAE) ⭐ Main method - Why whole-net rewards are noise for decisions in independent parts - Net components and how gympn derives them from the net - The per-component SMDP-GAE estimator and its conditions - A worked two-component example - ~30 minutes read
Deep Controlled Learning (DCL) - Approximate policy iteration: a rollout planner labels states, a network imitates them - Sequential Halving, keyed common random numbers, restricted rollouts, coalescing - Soft targets, rounds, and model selection on held-out episodes - Certificate-factored DCL: component-local labels and component-factored collection - ~30 minutes read
Postponement and Net-Factored Credit ⭐ Most Advanced - Postponement feature: defer decisions strategically - Net-factored credit (NF-GAE) for nets with independent parts - Implementation details - Use cases and best practices - ~60 minutes read
Extending GymPN - Create custom environments - Custom Petri Net models - Custom policy networks - Custom solvers - Integration patterns - ~50 minutes read
Practical Guides¶
API Quick Reference - Quick lookup for classes and functions - Common parameters and options - Return values and exceptions - Code snippets for common tasks - Perfect for: Quick lookups while coding
Benchmarks - Algorithm performance comparison - Hyperparameter sensitivity - Hardware requirements - Scaling recommendations - Use-case specific recommendations - Perfect for: Choosing algorithms and settings
Troubleshooting - Common errors and solutions - Debugging techniques - Performance tips - TensorBoard/W&B setup - FAQ - Perfect for: Problem solving
Contributing¶
Contributing Guide - How to contribute to GymPN - Code standards - Testing requirements - Documentation guidelines - PR process
Reading Paths¶
Path 1: Learning for the First Time ⭐ Recommended¶
- Gentle Introduction - 30 min
- Complete Example - 40 min
- API Quick Reference - 15 min (bookmark for later)
- Start experimenting!
- When you need advanced features, read Advanced Features
Total time: ~1.5 hours to get started
Path 2: Deep Learning (Understanding Everything)¶
- Gentle Introduction - 30 min
- Algorithms Guide - 40 min
- Agents Guide - 40 min
- Advanced Features - 45 min
- Postponement and Net-Factored Credit - 60 min
- Extending GymPN - 50 min
Total time: ~5 hours for comprehensive understanding
Path 3: Quick Setup for Production¶
- Complete Example - 40 min
- Benchmarks - 20 min (select hyperparameters)
- API Quick Reference - 15 min
- Troubleshooting - 10 min (bookmark for later)
- Start using!
Total time: ~1.5 hours to production-ready
Path 4: Advanced Features Only¶
- Algorithms Guide - for algorithm details
- Agents Guide - for agent setup
- Advanced Features - for GNNs and optimization
- Postponement and Net-Factored Credit - for postponement and per-component credit
- Extending GymPN - for custom components
Quick Reference by Use Case¶
"I want to solve a task assignment problem"¶
→ Complete Example + Benchmarks
"I want to create a custom Petri Net model"¶
→ Gentle Introduction + Extending GymPN
"I want to understand the PPO variants"¶
"I want to optimize performance"¶
→ Benchmarks + Advanced Features
"My training is unstable"¶
→ Troubleshooting + Algorithms Guide
"My net has several independent processes"¶
→ Postponement and Net-Factored Credit + Agents Guide
"I want to extend the framework"¶
→ Extending GymPN + API Quick Reference
"I need quick answers"¶
→ API Quick Reference + Troubleshooting
Document Details¶
| Document | Length | Difficulty | Topics |
|---|---|---|---|
| Gentle Introduction | ~30 min | Beginner | Basics, first environment |
| Complete Example | ~40 min | Beginner | Full example, best practices |
| Algorithms | ~40 min | Intermediate | PPO variants, hyperparameters |
| Agents Guide | ~40 min | Intermediate | Agent selection, custom solvers |
| Advanced Features | ~45 min | Advanced | GNNs, parallelization, optimization |
| Postponement & NF-GAE | ~60 min | Advanced | Postponement, credit assignment |
| Extending GymPN | ~50 min | Advanced | Custom environments, networks |
| API Reference | ~15 min | Any | Quick lookups, code snippets |
| Benchmarks | ~20 min | Intermediate | Performance, recommendations |
| Troubleshooting | ~30 min | Any | Common issues, solutions |
| Contributing | ~20 min | Intermediate | How to contribute code |
Key Concepts by Document¶
Core Concepts¶
- Action-Evolution Petri Nets (AEPN): Gentle Introduction, Complete Example
- Gymnasium Integration: Gentle Introduction, Extending GymPN
- Graph Observations: Advanced Features, API Reference
Algorithms¶
- Policy Gradient (PG): Algorithms, Benchmarks
- Proximal Policy Optimization (PPO): Algorithms, Agents Guide, Benchmarks
- PPO-Clip: Algorithms, Agents Guide, Benchmarks
- PPO-Penalty: Algorithms, Agents Guide, Benchmarks
Features¶
- Postponement: Postponement & NF-GAE, Extending GymPN
- Net-factored credit: Postponement & NF-GAE
- Graph Neural Networks: Advanced Features, Extending GymPN
- Custom Solvers: Agents Guide, Extending GymPN
- Parallel Training: Advanced Features, Benchmarks
Practical¶
- Environment Setup: Gentle Introduction, Complete Example, Extending GymPN
- Training: Complete Example, Algorithms, Benchmarks
- Hyperparameter Tuning: Algorithms, Benchmarks
- Debugging: Troubleshooting, Advanced Features
- Performance Optimization: Advanced Features, Benchmarks
Updated Frequently¶
These sections are updated regularly: - Benchmarks: When new hardware configurations are tested - Troubleshooting: When new issues are discovered and solved - API Reference: When new classes/functions are added - Contributing: When the contribution process changes
Last updated: January 2026