tensor-optix 2.0.7__tar.gz → 2.0.8__tar.gz

This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
Files changed (168) hide show
  1. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/PKG-INFO +8 -5
  2. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/README.md +7 -4
  3. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/pyproject.toml +1 -1
  4. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/factory.py +1 -1
  5. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/multi_agent/multi_agent_runtime.py +671 -671
  6. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/multi_agent/self_play.py +292 -292
  7. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/agent/graph_agent.py +174 -156
  8. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/brain_network.py +4 -1
  9. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/controller/topology_controller.py +122 -63
  10. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/graph/neuron.py +13 -15
  11. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/graph/neuron_graph.py +472 -52
  12. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/graph/topology_ops.py +7 -8
  13. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/hebbian.py +104 -39
  14. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/optimizer/topology_aware_adam.py +62 -1
  15. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix.egg-info/PKG-INFO +8 -5
  16. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/setup.cfg +0 -0
  17. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/__init__.py +0 -0
  18. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/adapters/__init__.py +0 -0
  19. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/adapters/jax/__init__.py +0 -0
  20. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/adapters/jax/flax_agent.py +0 -0
  21. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/adapters/jax/flax_evaluator.py +0 -0
  22. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/adapters/pytorch/__init__.py +0 -0
  23. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/adapters/pytorch/torch_agent.py +0 -0
  24. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/adapters/pytorch/torch_evaluator.py +0 -0
  25. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/adapters/tensorflow/__init__.py +0 -0
  26. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/adapters/tensorflow/tf_agent.py +0 -0
  27. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/adapters/tensorflow/tf_evaluator.py +0 -0
  28. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/__init__.py +0 -0
  29. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/flax_ppo.py +0 -0
  30. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/tf_dqn.py +0 -0
  31. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/tf_ppo.py +0 -0
  32. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/tf_ppo_continuous.py +0 -0
  33. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/tf_sac.py +0 -0
  34. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/tf_td3.py +0 -0
  35. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/torch_dqn.py +0 -0
  36. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/torch_ppo.py +0 -0
  37. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/torch_ppo_continuous.py +0 -0
  38. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/torch_rainbow_dqn.py +0 -0
  39. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/torch_recurrent_ppo.py +0 -0
  40. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/torch_sac.py +0 -0
  41. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/algorithms/torch_td3.py +0 -0
  42. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/callbacks/__init__.py +0 -0
  43. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/callbacks/rich_dashboard.py +0 -0
  44. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/callbacks/tensorboard_callback.py +0 -0
  45. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/callbacks/wandb_callback.py +0 -0
  46. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/cli.py +0 -0
  47. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/config.py +0 -0
  48. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/__init__.py +0 -0
  49. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/async_callback.py +0 -0
  50. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/backoff_scheduler.py +0 -0
  51. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/base_agent.py +0 -0
  52. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/base_evaluator.py +0 -0
  53. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/base_optimizer.py +0 -0
  54. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/base_pipeline.py +0 -0
  55. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/checkpoint_confirmation.py +0 -0
  56. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/checkpoint_registry.py +0 -0
  57. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/device.py +0 -0
  58. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/diagnostic_controller.py +0 -0
  59. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/ensemble_agent.py +0 -0
  60. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/her_buffer.py +0 -0
  61. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/loop_controller.py +0 -0
  62. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/meta_controller.py +0 -0
  63. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/noisy_linear.py +0 -0
  64. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/normalizers.py +0 -0
  65. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/obs_utils.py +0 -0
  66. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/policy_manager.py +0 -0
  67. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/regime_detector.py +0 -0
  68. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/replay_buffer.py +0 -0
  69. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/resume_state.py +0 -0
  70. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/reward_shape.py +0 -0
  71. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/trajectory_buffer.py +0 -0
  72. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/core/types.py +0 -0
  73. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/distributed/__init__.py +0 -0
  74. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/distributed/async_learner.py +0 -0
  75. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/distributed/vtrace.py +0 -0
  76. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/encoders/__init__.py +0 -0
  77. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/encoders/obs_encoder.py +0 -0
  78. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/encoders/obs_encoder_tf.py +0 -0
  79. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/exploration/__init__.py +0 -0
  80. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/exploration/rnd.py +0 -0
  81. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ledger/__init__.py +0 -0
  82. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ledger/callback.py +0 -0
  83. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ledger/provenance.py +0 -0
  84. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ledger/records.py +0 -0
  85. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ledger/schema.py +0 -0
  86. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ledger/store.py +0 -0
  87. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml/__init__.py +0 -0
  88. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml/dataset_pipeline.py +0 -0
  89. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml/loss_registry.py +0 -0
  90. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml/ml_agent.py +0 -0
  91. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/__init__.py +0 -0
  92. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/adapters/__init__.py +0 -0
  93. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/adapters/flax_model.py +0 -0
  94. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/adapters/tf_model.py +0 -0
  95. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/adapters/torch_model.py +0 -0
  96. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/base_model.py +0 -0
  97. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/lr_schedules.py +0 -0
  98. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/metrics.py +0 -0
  99. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/metrics_impl/__init__.py +0 -0
  100. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/metrics_impl/classification.py +0 -0
  101. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/metrics_impl/regression.py +0 -0
  102. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/trainer.py +0 -0
  103. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/ml_core/transfer.py +0 -0
  104. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/multi_agent/__init__.py +0 -0
  105. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/multi_agent/aec_pipeline.py +0 -0
  106. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/multi_agent/multi_agent_episode.py +0 -0
  107. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/multi_agent/parallel_pipeline.py +0 -0
  108. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/multi_agent/seat_env.py +0 -0
  109. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/nanonets/__init__.py +0 -0
  110. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/nanonets/abstention.py +0 -0
  111. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/nanonets/features.py +0 -0
  112. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/nanonets/pooling.py +0 -0
  113. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/nanonets/selector.py +0 -0
  114. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/nanonets/smalln.py +0 -0
  115. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/__init__.py +0 -0
  116. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/agent/__init__.py +0 -0
  117. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/controller/__init__.py +0 -0
  118. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/controller/topology_callback.py +0 -0
  119. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/graph/__init__.py +0 -0
  120. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/neuromodulator.py +0 -0
  121. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/neuroevo/optimizer/__init__.py +0 -0
  122. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/optimizer.py +0 -0
  123. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/optimizers/__init__.py +0 -0
  124. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/optimizers/adaptive_optimizer.py +0 -0
  125. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/optimizers/backoff_optimizer.py +0 -0
  126. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/optimizers/momentum_optimizer.py +0 -0
  127. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/optimizers/pbt_optimizer.py +0 -0
  128. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/optimizers/spsa_optimizer.py +0 -0
  129. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/orchestrator.py +0 -0
  130. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/pipeline/__init__.py +0 -0
  131. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/pipeline/batch_pipeline.py +0 -0
  132. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/pipeline/live_pipeline.py +0 -0
  133. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/pipeline/vector_pipeline.py +0 -0
  134. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/runtime/__init__.py +0 -0
  135. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/runtime/baseline.py +0 -0
  136. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/runtime/experiment_stage.py +0 -0
  137. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/runtime/live_runtime.py +0 -0
  138. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/runtime/observer.py +0 -0
  139. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/runtime/promote.py +0 -0
  140. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/scheduler/__init__.py +0 -0
  141. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/scheduler/_mp_common.py +0 -0
  142. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/scheduler/budget.py +0 -0
  143. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/scheduler/dedup.py +0 -0
  144. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/scheduler/isolation.py +0 -0
  145. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/scheduler/pool.py +0 -0
  146. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/scheduler/retry.py +0 -0
  147. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/scheduler/worker.py +0 -0
  148. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/selection/__init__.py +0 -0
  149. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/selection/backfill.py +0 -0
  150. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/selection/selector.py +0 -0
  151. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/selection/uncertainty.py +0 -0
  152. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/simple.py +0 -0
  153. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/strategy/__init__.py +0 -0
  154. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/strategy/candidate.py +0 -0
  155. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/strategy/comparator.py +0 -0
  156. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/strategy/grammar.py +0 -0
  157. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/strategy/promotion.py +0 -0
  158. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/strategy/runner.py +0 -0
  159. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/strategy/worker.py +0 -0
  160. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/utils/__init__.py +0 -0
  161. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/utils/console.py +0 -0
  162. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix/utils/window_size.py +0 -0
  163. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix.egg-info/SOURCES.txt +0 -0
  164. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix.egg-info/dependency_links.txt +0 -0
  165. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix.egg-info/entry_points.txt +0 -0
  166. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix.egg-info/requires.txt +0 -0
  167. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tensor_optix.egg-info/top_level.txt +0 -0
  168. {tensor_optix-2.0.7 → tensor_optix-2.0.8}/tests/test_ml.py +0 -0
@@ -1,6 +1,6 @@
1
1
  Metadata-Version: 2.4
2
2
  Name: tensor-optix
3
- Version: 2.0.7
3
+ Version: 2.0.8
4
4
  Summary: Autonomous training loop for any sequential learning model — PPO, DQN, SAC, TD3, Rainbow DQN, Recurrent PPO for TensorFlow, PyTorch, and JAX/Flax; distributed async actor-learner (IMPALA + V-trace)
5
5
  Author: sup3rus3r
6
6
  License-Expression: MIT
@@ -518,7 +518,7 @@ All types implement the same protocol: `step()`, `importance()`, `can_merge_with
518
518
 
519
519
  ### Trainable recurrent neurons
520
520
 
521
- `TrainableGRUNeuron` and `TrainableLSTMNeuron` set `is_recurrent = True`. `RecurrentGraphAgent` detects this flag and switches from shuffled-minibatch PPO to sequential chunk training with truncated BPTT.
521
+ `TrainableGRUNeuron` and `TrainableLSTMNeuron` let gradients flow back through their hidden state. Use them with `RecurrentGraphAgent`, which keeps the graph's state across `act()` calls (reset at episode start via `reset_hidden()`) and trains with sequential chunks and truncated BPTT, replaying exactly what `act()` computed.
522
522
 
523
523
  ```python
524
524
  from tensor_optix.neuroevo import TrainableGRUNeuron, TrainableLSTMNeuron, RecurrentGraphAgent
@@ -532,7 +532,8 @@ agent = RecurrentGraphAgent(
532
532
  graph, obs_dim=4, n_actions=2,
533
533
  hyperparams=HyperparamSet(params={"chunk_len": 64}),
534
534
  )
535
- # Falls back to standard shuffled-minibatch PPO if no recurrent neurons are present
535
+ # Falls back to standard shuffled-minibatch PPO if the graph holds no state
536
+ # (no GRU/LSTM neurons, no delayed edges)
536
537
  ```
537
538
 
538
539
  ### Topology controller
@@ -660,15 +661,17 @@ w = graph.effective_weight(edge_id) # reads post-softplus value
660
661
 
661
662
  ### TopologyAwareAdam
662
663
 
663
- Drop-in Adam replacement that resets (m, v) momentum state for parameters touched by a grow, prune, or merge operation. Stale momentum estimates from before a structural change would otherwise corrupt the first update on modified parameters.
664
+ Drop-in Adam replacement for graphs whose parameters get replaced by topology changes. `GraphAgent` uses it and carries Adam's (m, v) moments across every grow, prune or merge by edge id, so surviving edges keep their momentum and new edges start from zero. You can also reset the state of specific parameters yourself:
664
665
 
665
666
  ```python
666
667
  from tensor_optix.neuroevo import TopologyAwareAdam
667
668
 
668
669
  optimizer = TopologyAwareAdam(graph.parameters(), lr=3e-4)
669
- optimizer.notify_topology_change(new_params) # call after any topology mutation
670
+ optimizer.notify_topology_change(new_params) # reset (m, v) for these Parameters
670
671
  ```
671
672
 
673
+ After a rebuild, `new_optimizer.carry_over(old_optimizer, old_packed=..., old_ids=..., new_packed=..., new_ids=...)` moves the state across. See the [reference](https://sup3rus3r.github.io/tensor-optix/reference/neuroevo/topology-aware-adam/).
674
+
672
675
  ### Compiled forward
673
676
 
674
677
  `NeuronGraph` runs in **eager mode by default**. Because `_raw_forward` mutates Python-side neuron state (`neuron._current`, `push_history`), `torch.compile` cannot safely trace it without replaying those side effects. The default eager path is safe for training, recurrent neurons, and dynamic topologies.
@@ -447,7 +447,7 @@ All types implement the same protocol: `step()`, `importance()`, `can_merge_with
447
447
 
448
448
  ### Trainable recurrent neurons
449
449
 
450
- `TrainableGRUNeuron` and `TrainableLSTMNeuron` set `is_recurrent = True`. `RecurrentGraphAgent` detects this flag and switches from shuffled-minibatch PPO to sequential chunk training with truncated BPTT.
450
+ `TrainableGRUNeuron` and `TrainableLSTMNeuron` let gradients flow back through their hidden state. Use them with `RecurrentGraphAgent`, which keeps the graph's state across `act()` calls (reset at episode start via `reset_hidden()`) and trains with sequential chunks and truncated BPTT, replaying exactly what `act()` computed.
451
451
 
452
452
  ```python
453
453
  from tensor_optix.neuroevo import TrainableGRUNeuron, TrainableLSTMNeuron, RecurrentGraphAgent
@@ -461,7 +461,8 @@ agent = RecurrentGraphAgent(
461
461
  graph, obs_dim=4, n_actions=2,
462
462
  hyperparams=HyperparamSet(params={"chunk_len": 64}),
463
463
  )
464
- # Falls back to standard shuffled-minibatch PPO if no recurrent neurons are present
464
+ # Falls back to standard shuffled-minibatch PPO if the graph holds no state
465
+ # (no GRU/LSTM neurons, no delayed edges)
465
466
  ```
466
467
 
467
468
  ### Topology controller
@@ -589,15 +590,17 @@ w = graph.effective_weight(edge_id) # reads post-softplus value
589
590
 
590
591
  ### TopologyAwareAdam
591
592
 
592
- Drop-in Adam replacement that resets (m, v) momentum state for parameters touched by a grow, prune, or merge operation. Stale momentum estimates from before a structural change would otherwise corrupt the first update on modified parameters.
593
+ Drop-in Adam replacement for graphs whose parameters get replaced by topology changes. `GraphAgent` uses it and carries Adam's (m, v) moments across every grow, prune or merge by edge id, so surviving edges keep their momentum and new edges start from zero. You can also reset the state of specific parameters yourself:
593
594
 
594
595
  ```python
595
596
  from tensor_optix.neuroevo import TopologyAwareAdam
596
597
 
597
598
  optimizer = TopologyAwareAdam(graph.parameters(), lr=3e-4)
598
- optimizer.notify_topology_change(new_params) # call after any topology mutation
599
+ optimizer.notify_topology_change(new_params) # reset (m, v) for these Parameters
599
600
  ```
600
601
 
602
+ After a rebuild, `new_optimizer.carry_over(old_optimizer, old_packed=..., old_ids=..., new_packed=..., new_ids=...)` moves the state across. See the [reference](https://sup3rus3r.github.io/tensor-optix/reference/neuroevo/topology-aware-adam/).
603
+
601
604
  ### Compiled forward
602
605
 
603
606
  `NeuronGraph` runs in **eager mode by default**. Because `_raw_forward` mutates Python-side neuron state (`neuron._current`, `push_history`), `torch.compile` cannot safely trace it without replaying those side effects. The default eager path is safe for training, recurrent neurons, and dynamic topologies.
@@ -4,7 +4,7 @@ build-backend = "setuptools.build_meta"
4
4
 
5
5
  [project]
6
6
  name = "tensor-optix"
7
- version = "2.0.7"
7
+ version = "2.0.8"
8
8
  description = "Autonomous training loop for any sequential learning model — PPO, DQN, SAC, TD3, Rainbow DQN, Recurrent PPO for TensorFlow, PyTorch, and JAX/Flax; distributed async actor-learner (IMPALA + V-trace)"
9
9
  readme = "README.md"
10
10
  license = "MIT"
@@ -1063,7 +1063,7 @@ def _make_neuroevo_feature_extractor(
1063
1063
  def save_weights(self, path):
1064
1064
  super().save_weights(path)
1065
1065
  torch.save(
1066
- {"topology": graph.to_dict(), "graph": graph.state_dict(), "proj": _proj_cell["np"]},
1066
+ {"topology": graph.to_dict(include_weights=False), "graph": graph.state_dict(), "proj": _proj_cell["np"]},
1067
1067
  os.path.join(path, "neuro_graph.pt"),
1068
1068
  )
1069
1069