maddening 0.1.0__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 (328) hide show
  1. maddening-0.1.0/.claude/skills/commit-and-push/SKILL.md +158 -0
  2. maddening-0.1.0/.github/ISSUE_TEMPLATE/anomaly.md +67 -0
  3. maddening-0.1.0/.github/workflows/ci.yml +95 -0
  4. maddening-0.1.0/.github/workflows/publish.yml +62 -0
  5. maddening-0.1.0/.gitignore +18 -0
  6. maddening-0.1.0/.skyignore +14 -0
  7. maddening-0.1.0/CHANGELOG.md +139 -0
  8. maddening-0.1.0/CITATION.cff +23 -0
  9. maddening-0.1.0/CLAUDE.md +0 -0
  10. maddening-0.1.0/CLOUD_ROADMAP.md +435 -0
  11. maddening-0.1.0/CONTRIBUTING.md +108 -0
  12. maddening-0.1.0/DESIGN.md +702 -0
  13. maddening-0.1.0/DOCUMENTATION_ARCHITECTURE.md +3817 -0
  14. maddening-0.1.0/LICENSE +504 -0
  15. maddening-0.1.0/PKG-INFO +247 -0
  16. maddening-0.1.0/PLAN_accuracy_and_usd.md +797 -0
  17. maddening-0.1.0/README.md +127 -0
  18. maddening-0.1.0/ROADMAP.md +308 -0
  19. maddening-0.1.0/SECURITY.md +45 -0
  20. maddening-0.1.0/TODO_perf.md +94 -0
  21. maddening-0.1.0/docker/Dockerfile.cloud +89 -0
  22. maddening-0.1.0/docs/algorithm_guide/coupling/unit_transforms.md +135 -0
  23. maddening-0.1.0/docs/algorithm_guide/nodes/_template.md +114 -0
  24. maddening-0.1.0/docs/algorithm_guide/nodes/heat_node.md +110 -0
  25. maddening-0.1.0/docs/algorithm_guide/uq/index.md +36 -0
  26. maddening-0.1.0/docs/bibliography.bib +31 -0
  27. maddening-0.1.0/docs/developer_guide/documentation_standards.md +148 -0
  28. maddening-0.1.0/docs/developer_guide/node_authoring.md +429 -0
  29. maddening-0.1.0/docs/developer_guide/testing_standards.md +126 -0
  30. maddening-0.1.0/docs/index.md +56 -0
  31. maddening-0.1.0/docs/regulatory/downstream_integration.md +142 -0
  32. maddening-0.1.0/docs/regulatory/eu_mdr_guidelines.md +35 -0
  33. maddening-0.1.0/docs/regulatory/iec62304_mapping.md +20 -0
  34. maddening-0.1.0/docs/regulatory/intended_use.md +42 -0
  35. maddening-0.1.0/docs/regulatory/mdcg_2019_11.md +38 -0
  36. maddening-0.1.0/docs/user_guide/installation.md +163 -0
  37. maddening-0.1.0/docs/user_guide/quickstart.md +139 -0
  38. maddening-0.1.0/docs/validation/cou_template.md +56 -0
  39. maddening-0.1.0/docs/validation/framework_verification.md +38 -0
  40. maddening-0.1.0/docs/validation/known_anomalies.yaml +54 -0
  41. maddening-0.1.0/docs/validation/soup_package.md +76 -0
  42. maddening-0.1.0/pyproject.toml +173 -0
  43. maddening-0.1.0/sbom.json +11018 -0
  44. maddening-0.1.0/scripts/check_anomalies.py +44 -0
  45. maddening-0.1.0/scripts/check_citations.py +117 -0
  46. maddening-0.1.0/scripts/check_impl_mapping.py +134 -0
  47. maddening-0.1.0/scripts/check_transforms.py +95 -0
  48. maddening-0.1.0/src/maddening/__init__.py +49 -0
  49. maddening-0.1.0/src/maddening/api/README.md +111 -0
  50. maddening-0.1.0/src/maddening/api/__init__.py +9 -0
  51. maddening-0.1.0/src/maddening/api/binary_encoder.py +118 -0
  52. maddening-0.1.0/src/maddening/api/frame_renderer.py +589 -0
  53. maddening-0.1.0/src/maddening/api/frame_renderer_3d.py +668 -0
  54. maddening-0.1.0/src/maddening/api/frame_renderer_base.py +73 -0
  55. maddening-0.1.0/src/maddening/api/server.py +1008 -0
  56. maddening-0.1.0/src/maddening/api/static/app.html +835 -0
  57. maddening-0.1.0/src/maddening/api/static/graph.html +631 -0
  58. maddening-0.1.0/src/maddening/api/static/render.html +313 -0
  59. maddening-0.1.0/src/maddening/api/static/vessel_flow.html +508 -0
  60. maddening-0.1.0/src/maddening/api/static/webrtc_client.html +188 -0
  61. maddening-0.1.0/src/maddening/api/vessel_renderer.py +280 -0
  62. maddening-0.1.0/src/maddening/cloud/__init__.py +143 -0
  63. maddening-0.1.0/src/maddening/cloud/_auth.py +27 -0
  64. maddening-0.1.0/src/maddening/cloud/_health.py +121 -0
  65. maddening-0.1.0/src/maddening/cloud/_skypilot.py +133 -0
  66. maddening-0.1.0/src/maddening/cloud/entrypoint.py +118 -0
  67. maddening-0.1.0/src/maddening/cloud/group.py +215 -0
  68. maddening-0.1.0/src/maddening/cloud/launcher.py +1086 -0
  69. maddening-0.1.0/src/maddening/cloud/mock_session.py +208 -0
  70. maddening-0.1.0/src/maddening/cloud/mock_streaming.py +119 -0
  71. maddening-0.1.0/src/maddening/cloud/multigpu/__init__.py +5 -0
  72. maddening-0.1.0/src/maddening/cloud/multigpu/coordinator.py +303 -0
  73. maddening-0.1.0/src/maddening/cloud/multigpu/device_mesh.py +30 -0
  74. maddening-0.1.0/src/maddening/cloud/multigpu/partition.py +89 -0
  75. maddening-0.1.0/src/maddening/cloud/multigpu/sharded_node.py +115 -0
  76. maddening-0.1.0/src/maddening/cloud/multigpu/sharded_step.py +114 -0
  77. maddening-0.1.0/src/maddening/cloud/multigpu/worker_client.py +268 -0
  78. maddening-0.1.0/src/maddening/cloud/providers.py +175 -0
  79. maddening-0.1.0/src/maddening/cloud/selkies_session.py +269 -0
  80. maddening-0.1.0/src/maddening/cloud/session.py +363 -0
  81. maddening-0.1.0/src/maddening/cloud/streaming.py +177 -0
  82. maddening-0.1.0/src/maddening/compliance/__init__.py +79 -0
  83. maddening-0.1.0/src/maddening/compliance/__main__.py +56 -0
  84. maddening-0.1.0/src/maddening/compliance/_validate.py +100 -0
  85. maddening-0.1.0/src/maddening/core/README.md +109 -0
  86. maddening-0.1.0/src/maddening/core/__init__.py +45 -0
  87. maddening-0.1.0/src/maddening/core/compliance/__init__.py +7 -0
  88. maddening-0.1.0/src/maddening/core/compliance/anomaly.py +51 -0
  89. maddening-0.1.0/src/maddening/core/compliance/audit.py +88 -0
  90. maddening-0.1.0/src/maddening/core/compliance/metadata.py +142 -0
  91. maddening-0.1.0/src/maddening/core/compliance/provenance.py +91 -0
  92. maddening-0.1.0/src/maddening/core/compliance/stability.py +69 -0
  93. maddening-0.1.0/src/maddening/core/compliance/uq.py +67 -0
  94. maddening-0.1.0/src/maddening/core/compliance/validation.py +88 -0
  95. maddening-0.1.0/src/maddening/core/coupling/__init__.py +11 -0
  96. maddening-0.1.0/src/maddening/core/coupling/acceleration.py +431 -0
  97. maddening-0.1.0/src/maddening/core/coupling/group.py +111 -0
  98. maddening-0.1.0/src/maddening/core/coupling/helpers.py +330 -0
  99. maddening-0.1.0/src/maddening/core/coupling/interface_mapping.py +295 -0
  100. maddening-0.1.0/src/maddening/core/edge.py +57 -0
  101. maddening-0.1.0/src/maddening/core/graph_manager.py +2592 -0
  102. maddening-0.1.0/src/maddening/core/node.py +285 -0
  103. maddening-0.1.0/src/maddening/core/schedule.py +157 -0
  104. maddening-0.1.0/src/maddening/core/simulation/__init__.py +13 -0
  105. maddening-0.1.0/src/maddening/core/simulation/adaptive.py +162 -0
  106. maddening-0.1.0/src/maddening/core/simulation/calibration.py +324 -0
  107. maddening-0.1.0/src/maddening/core/simulation/checkpoint.py +152 -0
  108. maddening-0.1.0/src/maddening/core/simulation/history_logger.py +113 -0
  109. maddening-0.1.0/src/maddening/core/simulation/hybrid_node.py +186 -0
  110. maddening-0.1.0/src/maddening/core/simulation/implicit.py +105 -0
  111. maddening-0.1.0/src/maddening/core/simulation/integrators.py +163 -0
  112. maddening-0.1.0/src/maddening/core/simulation/profiler.py +249 -0
  113. maddening-0.1.0/src/maddening/core/transforms.py +289 -0
  114. maddening-0.1.0/src/maddening/core/transforms_unit.py +223 -0
  115. maddening-0.1.0/src/maddening/examples/README.md +103 -0
  116. maddening-0.1.0/src/maddening/examples/__init__.py +0 -0
  117. maddening-0.1.0/src/maddening/examples/advanced/__init__.py +0 -0
  118. maddening-0.1.0/src/maddening/examples/advanced/adaptive_demo.py +151 -0
  119. maddening-0.1.0/src/maddening/examples/advanced/differentiable_optimization.py +206 -0
  120. maddening-0.1.0/src/maddening/examples/advanced/external_inputs_demo.py +333 -0
  121. maddening-0.1.0/src/maddening/examples/advanced/multirate_demo.py +224 -0
  122. maddening-0.1.0/src/maddening/examples/advanced/parameter_sweep_demo.py +146 -0
  123. maddening-0.1.0/src/maddening/examples/advanced/scan_performance.py +237 -0
  124. maddening-0.1.0/src/maddening/examples/advanced/surrogate_demo.py +102 -0
  125. maddening-0.1.0/src/maddening/examples/basics/__init__.py +0 -0
  126. maddening-0.1.0/src/maddening/examples/basics/bouncing_ball.py +146 -0
  127. maddening-0.1.0/src/maddening/examples/basics/bouncing_ball_combined.py +116 -0
  128. maddening-0.1.0/src/maddening/examples/basics/bouncing_ball_scene.py +100 -0
  129. maddening-0.1.0/src/maddening/examples/basics/bouncing_ball_terminal.py +69 -0
  130. maddening-0.1.0/src/maddening/examples/basics/heat_diffusion_demo.py +198 -0
  131. maddening-0.1.0/src/maddening/examples/basics/rigid_body_demo.py +208 -0
  132. maddening-0.1.0/src/maddening/examples/cloud/README.md +46 -0
  133. maddening-0.1.0/src/maddening/examples/cloud/__init__.py +0 -0
  134. maddening-0.1.0/src/maddening/examples/cloud/config/__init__.py +0 -0
  135. maddening-0.1.0/src/maddening/examples/cloud/config/cloud_credentials.example.yaml +12 -0
  136. maddening-0.1.0/src/maddening/examples/cloud/config/job_config.example.yaml +30 -0
  137. maddening-0.1.0/src/maddening/examples/cloud/launch/01_validate.py +62 -0
  138. maddening-0.1.0/src/maddening/examples/cloud/launch/02_runpod_launch.py +104 -0
  139. maddening-0.1.0/src/maddening/examples/cloud/launch/03_reconnect_test.py +89 -0
  140. maddening-0.1.0/src/maddening/examples/cloud/launch/__init__.py +0 -0
  141. maddening-0.1.0/src/maddening/examples/cloud/multigpu/09_real_gpu_benchmark.py +262 -0
  142. maddening-0.1.0/src/maddening/examples/cloud/multigpu/__init__.py +0 -0
  143. maddening-0.1.0/src/maddening/examples/cloud/multijob/08_two_vm_test.py +440 -0
  144. maddening-0.1.0/src/maddening/examples/cloud/multijob/__init__.py +0 -0
  145. maddening-0.1.0/src/maddening/examples/cloud/server/04_server_test.py +313 -0
  146. maddening-0.1.0/src/maddening/examples/cloud/server/05_websocket_test.py +310 -0
  147. maddening-0.1.0/src/maddening/examples/cloud/server/__init__.py +0 -0
  148. maddening-0.1.0/src/maddening/examples/cloud/streaming/06_selkies_test.py +269 -0
  149. maddening-0.1.0/src/maddening/examples/cloud/streaming/07_webrtc_streaming_test.py +449 -0
  150. maddening-0.1.0/src/maddening/examples/cloud/streaming/__init__.py +0 -0
  151. maddening-0.1.0/src/maddening/examples/coupling/__init__.py +0 -0
  152. maddening-0.1.0/src/maddening/examples/coupling/acceleration_comparison.py +173 -0
  153. maddening-0.1.0/src/maddening/examples/coupling/convergence_diagnostics_demo.py +216 -0
  154. maddening-0.1.0/src/maddening/examples/coupling/coupled_spring_ball.py +176 -0
  155. maddening-0.1.0/src/maddening/examples/coupling/coupling_demo.py +216 -0
  156. maddening-0.1.0/src/maddening/examples/coupling/flux_coupling_demo.py +440 -0
  157. maddening-0.1.0/src/maddening/examples/coupling/jacobi_vs_gauss_seidel.py +174 -0
  158. maddening-0.1.0/src/maddening/examples/coupling/spatial_interpolation_demo.py +258 -0
  159. maddening-0.1.0/src/maddening/examples/coupling/subcycling_demo.py +149 -0
  160. maddening-0.1.0/src/maddening/examples/coupling/vessel_bifurcation.py +263 -0
  161. maddening-0.1.0/src/maddening/examples/coupling/vessel_bifurcation_live.py +310 -0
  162. maddening-0.1.0/src/maddening/examples/coupling/vessel_flow_helpers.py +216 -0
  163. maddening-0.1.0/src/maddening/examples/servers/__init__.py +0 -0
  164. maddening-0.1.0/src/maddening/examples/servers/api_server.py +135 -0
  165. maddening-0.1.0/src/maddening/examples/servers/interactive_graph_server.py +99 -0
  166. maddening-0.1.0/src/maddening/examples/servers/launch_app.py +113 -0
  167. maddening-0.1.0/src/maddening/examples/servers/launch_server_render.py +174 -0
  168. maddening-0.1.0/src/maddening/examples/servers/lbm_pipe_interactive.py +553 -0
  169. maddening-0.1.0/src/maddening/examples/servers/lbm_pipe_replay.py +229 -0
  170. maddening-0.1.0/src/maddening/examples/servers/lbm_pipe_server.py +175 -0
  171. maddening-0.1.0/src/maddening/examples/servers/remote_sim_server.py +85 -0
  172. maddening-0.1.0/src/maddening/examples/servers/remote_viz_client.py +140 -0
  173. maddening-0.1.0/src/maddening/examples/servers/vessel_flow_server.py +449 -0
  174. maddening-0.1.0/src/maddening/nodes/README.md +75 -0
  175. maddening-0.1.0/src/maddening/nodes/__init__.py +16 -0
  176. maddening-0.1.0/src/maddening/nodes/ball.py +126 -0
  177. maddening-0.1.0/src/maddening/nodes/health_check.py +141 -0
  178. maddening-0.1.0/src/maddening/nodes/heart_pump.py +278 -0
  179. maddening-0.1.0/src/maddening/nodes/heat.py +452 -0
  180. maddening-0.1.0/src/maddening/nodes/lbm.py +802 -0
  181. maddening-0.1.0/src/maddening/nodes/lbm_geometry.py +142 -0
  182. maddening-0.1.0/src/maddening/nodes/lbm_pipe.py +876 -0
  183. maddening-0.1.0/src/maddening/nodes/rigid_body.py +347 -0
  184. maddening-0.1.0/src/maddening/nodes/rigid_body_2d.py +211 -0
  185. maddening-0.1.0/src/maddening/nodes/spring.py +188 -0
  186. maddening-0.1.0/src/maddening/nodes/table.py +60 -0
  187. maddening-0.1.0/src/maddening/serialization/README.md +54 -0
  188. maddening-0.1.0/src/maddening/serialization/__init__.py +3 -0
  189. maddening-0.1.0/src/maddening/serialization/config.py +34 -0
  190. maddening-0.1.0/src/maddening/surrogates/__init__.py +118 -0
  191. maddening-0.1.0/src/maddening/surrogates/architecture.py +80 -0
  192. maddening-0.1.0/src/maddening/surrogates/architectures/__init__.py +32 -0
  193. maddening-0.1.0/src/maddening/surrogates/architectures/_utils.py +69 -0
  194. maddening-0.1.0/src/maddening/surrogates/architectures/deeponet.py +377 -0
  195. maddening-0.1.0/src/maddening/surrogates/architectures/fno.py +429 -0
  196. maddening-0.1.0/src/maddening/surrogates/architectures/mlp.py +123 -0
  197. maddening-0.1.0/src/maddening/surrogates/callbacks.py +189 -0
  198. maddening-0.1.0/src/maddening/surrogates/checkpoint.py +170 -0
  199. maddening-0.1.0/src/maddening/surrogates/dataset.py +232 -0
  200. maddening-0.1.0/src/maddening/surrogates/node.py +125 -0
  201. maddening-0.1.0/src/maddening/surrogates/physics_losses.py +196 -0
  202. maddening-0.1.0/src/maddening/surrogates/replace.py +62 -0
  203. maddening-0.1.0/src/maddening/surrogates/trainer.py +335 -0
  204. maddening-0.1.0/src/maddening/surrogates/validator.py +166 -0
  205. maddening-0.1.0/src/maddening/usd/__init__.py +57 -0
  206. maddening-0.1.0/src/maddening/usd/geometry.py +179 -0
  207. maddening-0.1.0/src/maddening/usd/schema/generatedSchema.usda +62 -0
  208. maddening-0.1.0/src/maddening/usd/schema/plugInfo.json +38 -0
  209. maddening-0.1.0/src/maddening/usd/serialization.py +418 -0
  210. maddening-0.1.0/src/maddening/usd/writer.py +183 -0
  211. maddening-0.1.0/src/maddening/viz/README.md +150 -0
  212. maddening-0.1.0/src/maddening/viz/__init__.py +64 -0
  213. maddening-0.1.0/src/maddening/viz/_imports.py +35 -0
  214. maddening-0.1.0/src/maddening/viz/backends/__init__.py +50 -0
  215. maddening-0.1.0/src/maddening/viz/backends/matplotlib_renderer.py +370 -0
  216. maddening-0.1.0/src/maddening/viz/backends/pygfx_viewer.py +1011 -0
  217. maddening-0.1.0/src/maddening/viz/backends/pyvista_live.py +423 -0
  218. maddening-0.1.0/src/maddening/viz/backends/selkies_renderer.py +104 -0
  219. maddening-0.1.0/src/maddening/viz/backends/terminal_renderer.py +137 -0
  220. maddening-0.1.0/src/maddening/viz/history_viewer.py +1036 -0
  221. maddening-0.1.0/src/maddening/viz/network.py +257 -0
  222. maddening-0.1.0/src/maddening/viz/relay.py +69 -0
  223. maddening-0.1.0/src/maddening/viz/renderer.py +73 -0
  224. maddening-0.1.0/src/maddening/viz/runner.py +139 -0
  225. maddening-0.1.0/src/maddening/viz/usd_viewer.py +406 -0
  226. maddening-0.1.0/src/maddening/warnings.py +7 -0
  227. maddening-0.1.0/tests/__init__.py +0 -0
  228. maddening-0.1.0/tests/api/__init__.py +0 -0
  229. maddening-0.1.0/tests/api/test_api.py +260 -0
  230. maddening-0.1.0/tests/api/test_binary_encoder.py +113 -0
  231. maddening-0.1.0/tests/api/test_field_subscriptions.py +128 -0
  232. maddening-0.1.0/tests/api/test_frame_renderer.py +192 -0
  233. maddening-0.1.0/tests/api/test_frame_renderer_3d.py +234 -0
  234. maddening-0.1.0/tests/api/test_render_stride.py +151 -0
  235. maddening-0.1.0/tests/api/test_server_render.py +134 -0
  236. maddening-0.1.0/tests/cloud/__init__.py +0 -0
  237. maddening-0.1.0/tests/cloud/multigpu/__init__.py +0 -0
  238. maddening-0.1.0/tests/cloud/multigpu/conftest.py +14 -0
  239. maddening-0.1.0/tests/cloud/multigpu/test_device_mesh.py +37 -0
  240. maddening-0.1.0/tests/cloud/multigpu/test_graph_multigpu.py +180 -0
  241. maddening-0.1.0/tests/cloud/multigpu/test_partition.py +103 -0
  242. maddening-0.1.0/tests/cloud/multigpu/test_sharded_node.py +144 -0
  243. maddening-0.1.0/tests/cloud/multigpu/test_sharded_step.py +140 -0
  244. maddening-0.1.0/tests/cloud/test_auth.py +39 -0
  245. maddening-0.1.0/tests/cloud/test_cloud_group.py +143 -0
  246. maddening-0.1.0/tests/cloud/test_cloud_session.py +267 -0
  247. maddening-0.1.0/tests/cloud/test_coordinator.py +227 -0
  248. maddening-0.1.0/tests/cloud/test_health.py +68 -0
  249. maddening-0.1.0/tests/cloud/test_launcher.py +335 -0
  250. maddening-0.1.0/tests/cloud/test_mock_session.py +93 -0
  251. maddening-0.1.0/tests/cloud/test_providers.py +181 -0
  252. maddening-0.1.0/tests/cloud/test_selkies_renderer.py +186 -0
  253. maddening-0.1.0/tests/cloud/test_streaming.py +116 -0
  254. maddening-0.1.0/tests/cloud/test_worker_client.py +219 -0
  255. maddening-0.1.0/tests/compliance/__init__.py +0 -0
  256. maddening-0.1.0/tests/compliance/test_audit.py +63 -0
  257. maddening-0.1.0/tests/compliance/test_compliance_namespace.py +142 -0
  258. maddening-0.1.0/tests/compliance/test_metadata.py +135 -0
  259. maddening-0.1.0/tests/compliance/test_provenance.py +37 -0
  260. maddening-0.1.0/tests/compliance/test_stability.py +66 -0
  261. maddening-0.1.0/tests/compliance/test_uq.py +64 -0
  262. maddening-0.1.0/tests/compliance/test_validation_benchmark.py +71 -0
  263. maddening-0.1.0/tests/compliance/test_validator.py +208 -0
  264. maddening-0.1.0/tests/conftest.py +39 -0
  265. maddening-0.1.0/tests/core/__init__.py +0 -0
  266. maddening-0.1.0/tests/core/test_adaptive.py +631 -0
  267. maddening-0.1.0/tests/core/test_calibrate.py +234 -0
  268. maddening-0.1.0/tests/core/test_calibration.py +149 -0
  269. maddening-0.1.0/tests/core/test_checkpoint.py +311 -0
  270. maddening-0.1.0/tests/core/test_coupling.py +786 -0
  271. maddening-0.1.0/tests/core/test_coupling_acceleration.py +236 -0
  272. maddening-0.1.0/tests/core/test_coupling_convergence.py +702 -0
  273. maddening-0.1.0/tests/core/test_coupling_helpers.py +341 -0
  274. maddening-0.1.0/tests/core/test_coupling_predictor.py +249 -0
  275. maddening-0.1.0/tests/core/test_coupling_subcycling.py +323 -0
  276. maddening-0.1.0/tests/core/test_edge.py +100 -0
  277. maddening-0.1.0/tests/core/test_flux_coupling.py +401 -0
  278. maddening-0.1.0/tests/core/test_graph_manager.py +670 -0
  279. maddening-0.1.0/tests/core/test_history_logger.py +345 -0
  280. maddening-0.1.0/tests/core/test_hybrid_node.py +316 -0
  281. maddening-0.1.0/tests/core/test_implicit.py +250 -0
  282. maddening-0.1.0/tests/core/test_integration.py +204 -0
  283. maddening-0.1.0/tests/core/test_integrators.py +359 -0
  284. maddening-0.1.0/tests/core/test_interface_dof.py +413 -0
  285. maddening-0.1.0/tests/core/test_interface_mapping.py +290 -0
  286. maddening-0.1.0/tests/core/test_multirate.py +790 -0
  287. maddening-0.1.0/tests/core/test_node.py +116 -0
  288. maddening-0.1.0/tests/core/test_phases_5_7_8.py +684 -0
  289. maddening-0.1.0/tests/core/test_schedule.py +139 -0
  290. maddening-0.1.0/tests/core/test_spatial_accuracy.py +366 -0
  291. maddening-0.1.0/tests/core/test_sweep.py +293 -0
  292. maddening-0.1.0/tests/core/test_transforms.py +275 -0
  293. maddening-0.1.0/tests/nodes/__init__.py +0 -0
  294. maddening-0.1.0/tests/nodes/test_health_check.py +188 -0
  295. maddening-0.1.0/tests/nodes/test_heart_pump.py +368 -0
  296. maddening-0.1.0/tests/nodes/test_heat.py +287 -0
  297. maddening-0.1.0/tests/nodes/test_lbm.py +520 -0
  298. maddening-0.1.0/tests/nodes/test_lbm_pipe.py +640 -0
  299. maddening-0.1.0/tests/nodes/test_rigid_body.py +512 -0
  300. maddening-0.1.0/tests/nodes/test_rigid_body_2d.py +447 -0
  301. maddening-0.1.0/tests/nodes/test_spring.py +262 -0
  302. maddening-0.1.0/tests/nodes/test_vessel_coupling.py +288 -0
  303. maddening-0.1.0/tests/surrogates/__init__.py +0 -0
  304. maddening-0.1.0/tests/surrogates/test_callbacks.py +160 -0
  305. maddening-0.1.0/tests/surrogates/test_dataset.py +130 -0
  306. maddening-0.1.0/tests/surrogates/test_deeponet.py +301 -0
  307. maddening-0.1.0/tests/surrogates/test_fno.py +342 -0
  308. maddening-0.1.0/tests/surrogates/test_physics_losses.py +162 -0
  309. maddening-0.1.0/tests/surrogates/test_replace.py +167 -0
  310. maddening-0.1.0/tests/surrogates/test_surrogate_checkpoint.py +172 -0
  311. maddening-0.1.0/tests/surrogates/test_surrogate_integration.py +157 -0
  312. maddening-0.1.0/tests/surrogates/test_surrogate_node.py +299 -0
  313. maddening-0.1.0/tests/surrogates/test_trainer.py +101 -0
  314. maddening-0.1.0/tests/test_import_guards.py +205 -0
  315. maddening-0.1.0/tests/usd/__init__.py +0 -0
  316. maddening-0.1.0/tests/usd/conftest.py +18 -0
  317. maddening-0.1.0/tests/usd/test_usd_geometry.py +341 -0
  318. maddening-0.1.0/tests/usd/test_usd_schema.py +289 -0
  319. maddening-0.1.0/tests/usd/test_usd_serialization.py +332 -0
  320. maddening-0.1.0/tests/usd/test_usd_writer.py +152 -0
  321. maddening-0.1.0/tests/verification/__init__.py +0 -0
  322. maddening-0.1.0/tests/verification/test_gradient_health.py +376 -0
  323. maddening-0.1.0/tests/verification/test_heat_analytical.py +214 -0
  324. maddening-0.1.0/tests/viz/__init__.py +0 -0
  325. maddening-0.1.0/tests/viz/test_network.py +115 -0
  326. maddening-0.1.0/tests/viz/test_pygfx_viewer.py +328 -0
  327. maddening-0.1.0/tests/viz/test_serialization.py +76 -0
  328. maddening-0.1.0/tests/viz/test_viz.py +180 -0
@@ -0,0 +1,158 @@
1
+ # Commit and Push Compliance Skill
2
+
3
+ This skill enforces MADDENING's documentation architecture requirements on every commit and push. Run it before pushing to ensure all regulatory and documentation standards are met.
4
+
5
+ ## Trigger
6
+
7
+ When the user asks to commit and push, or invokes `/commit-and-push`.
8
+
9
+ ## Pre-Commit Checklist
10
+
11
+ Work through the following checklist systematically. Each section has a **gate** — if the gate fails, stop and fix before proceeding.
12
+
13
+ ### 1. Tests Pass
14
+
15
+ Run the full test suite:
16
+
17
+ ```bash
18
+ source ../venvs/.maddening/bin/activate
19
+ PYTEST_DISABLE_PLUGIN_AUTOLOAD=1 python -m pytest tests/ -v --tb=short --ignore=tests/viz
20
+ ```
21
+
22
+ **Gate**: All tests must pass. If any fail, fix them before continuing.
23
+
24
+ ### 2. Compliance CI Scripts Pass
25
+
26
+ Run all three compliance validation scripts:
27
+
28
+ ```bash
29
+ python scripts/check_anomalies.py
30
+ python scripts/check_impl_mapping.py
31
+ python scripts/check_citations.py
32
+ python scripts/check_transforms.py
33
+ ```
34
+
35
+ **Gate**: All four must exit 0. Fix any errors before continuing.
36
+
37
+ ### 3. Commit Message Convention
38
+
39
+ Use the correct prefix based on the nature of the change:
40
+
41
+ | Prefix | When to use |
42
+ |--------|-------------|
43
+ | `feat:` | New feature or capability |
44
+ | `fix:` | Bug fix |
45
+ | `refactor:` | Code restructuring (no behavior change) |
46
+ | `docs:` | Documentation-only changes |
47
+ | `test:` | Test additions or changes |
48
+ | `perf:` | Performance improvement |
49
+ | `verify:` | Verification/validation evidence |
50
+ | `break:` | Breaking API change |
51
+ | `deprecate:` | Deprecation notice |
52
+ | `security:` | Security-relevant change |
53
+
54
+ The commit message body should be concise (1-2 sentences) and focus on **why** the change was made, not what was changed (the diff shows what).
55
+
56
+ ### 4. CHANGELOG.md Updated
57
+
58
+ Check if the changes affect user-visible functionality. If yes, update `CHANGELOG.md` under `## [Unreleased]` in the appropriate section:
59
+
60
+ - **Added** — new features, new nodes, new capabilities
61
+ - **Changed** — changes to existing features or behavior
62
+ - **Deprecated** — features marked for future removal
63
+ - **Removed** — features removed in this change
64
+ - **Fixed** — bug fixes
65
+ - **Verification** — changes to V&V status, new benchmarks, benchmark results changes
66
+ - **Security** — security-relevant changes (required by MDCG 2019-16)
67
+ - **Known Anomalies** — changes to `known_anomalies.yaml` (required for IEC 62304 SOUP)
68
+
69
+ **When to skip**: Pure internal refactors, CI config changes, and developer tooling changes that don't affect the package's external behavior don't need changelog entries.
70
+
71
+ ### 5. New Node Checks (if applicable)
72
+
73
+ If the commit adds or modifies a `SimulationNode` subclass, verify:
74
+
75
+ - [ ] `meta` ClassVar has `NodeMeta` with: `algorithm_id`, `stability`, `description`, `assumptions`, `limitations`, `hazard_hints`
76
+ - [ ] `@stability(StabilityLevel.X)` decorator applied
77
+ - [ ] NumPy-style docstring present
78
+ - [ ] `update()` is JAX-traceable (uses `jnp` ops, no Python side effects)
79
+ - [ ] Algorithm guide in `docs/algorithm_guide/nodes/` follows `_template.md`
80
+ - [ ] Implementation Mapping table traces all equation terms to code
81
+ - [ ] Unit tests in `tests/nodes/`
82
+ - [ ] At least one `@verification_benchmark` in `tests/verification/`
83
+
84
+ ### 6. New Anomaly Checks (if applicable)
85
+
86
+ If the commit introduces or discovers a known limitation:
87
+
88
+ - [ ] Entry added to `docs/validation/known_anomalies.yaml` with all required fields
89
+ - [ ] `anomaly_id` uses `MADD-ANO-XXX` format
90
+ - [ ] `safety_relevance_rationale` is filled in (not empty)
91
+ - [ ] Changelog updated under `### Known Anomalies`
92
+ - [ ] `python scripts/check_anomalies.py` passes
93
+
94
+ ### 7. Bibliography/Citation Checks (if applicable)
95
+
96
+ If the commit modifies algorithm guide documents:
97
+
98
+ - [ ] All `[@Key]` citations have matching entries in `docs/bibliography.bib`
99
+ - [ ] YAML frontmatter includes `bibliography: ../../bibliography.bib`
100
+ - [ ] References section has human-readable inline descriptions alongside `[@Key]`
101
+ - [ ] `python scripts/check_citations.py` passes
102
+
103
+ ### 8. Implementation Mapping Checks (if applicable)
104
+
105
+ If the commit renames or moves any function referenced in an algorithm guide's Implementation Mapping table:
106
+
107
+ - [ ] Algorithm guide updated with new qualified name
108
+ - [ ] `python scripts/check_impl_mapping.py` passes
109
+
110
+ ### 8b. Transform Registry Checks (if applicable)
111
+
112
+ If the commit adds or modifies edge transforms used in production examples or scenarios:
113
+
114
+ - [ ] Transforms registered via `@register_transform` from `maddening.core.transforms`
115
+ - [ ] String transform references in production code resolve in the registry
116
+ - [ ] `python scripts/check_transforms.py` passes
117
+
118
+ ### 9. API Stability Checks (if applicable)
119
+
120
+ If the commit changes a public API surface:
121
+
122
+ - [ ] `@stability` decorator level is appropriate
123
+ - [ ] If `STABLE`: change is backward-compatible (or this is a major version bump)
124
+ - [ ] If `PROVISIONAL`: deprecation warning added for the old API
125
+ - [ ] If removing a `DEPRECATED` API: verify it's a major version bump
126
+
127
+ ## Execution Steps
128
+
129
+ After all checks pass:
130
+
131
+ 1. **Stage files**: Add specific files (avoid `git add -A` to prevent accidentally staging secrets or large files)
132
+ 2. **Commit**: Use the appropriate prefix and a concise message
133
+ 3. **Push**: Push to the remote
134
+
135
+ ```bash
136
+ git add <specific files>
137
+ git commit -m "prefix: concise description of why
138
+
139
+ Longer explanation if needed.
140
+
141
+ Co-Authored-By: Claude Opus 4.6 <noreply@anthropic.com>"
142
+ git push
143
+ ```
144
+
145
+ 4. **Verify CI**: After pushing, note that CI will run tests on Python 3.10/3.11/3.12 and the compliance job. If CI fails, fix and push again.
146
+
147
+ ## Quick Reference: What Goes Where
148
+
149
+ | Change Type | CHANGELOG | Anomaly YAML | Algorithm Guide | Bibliography |
150
+ |-------------|-----------|-------------|-----------------|--------------|
151
+ | New node | Added | If limitations | Yes (new doc) | If citing papers |
152
+ | Bug fix | Fixed | If it was a known anomaly | Update if affects equations | No |
153
+ | New limitation discovered | Known Anomalies | Yes (new entry) | Update Known Limitations | No |
154
+ | Renamed function | No | No | Update Impl Mapping | No |
155
+ | New verification benchmark | Verification | No | Update Verification Evidence | If citing reference |
156
+ | Documentation only | No (unless user-facing) | No | If algorithm guide | If adding citations |
157
+ | Security fix | Security | If safety-relevant | No | No |
158
+ | Deprecation | Deprecated | No | No | No |
@@ -0,0 +1,67 @@
1
+ ---
2
+ name: Anomaly Report
3
+ about: Report a known anomaly (incorrect results, numerical instability, unexpected behavior)
4
+ title: "[ANOMALY] "
5
+ labels: known-anomaly
6
+ ---
7
+
8
+ ## Severity
9
+
10
+ <!-- Select one: critical / major / minor -->
11
+
12
+ **Severity**:
13
+
14
+ ## Safety Relevance
15
+
16
+ <!-- Select one: safety_relevant / not_safety_relevant / context_dependent -->
17
+
18
+ **Safety relevance**:
19
+
20
+ ## Safety Relevance Rationale
21
+
22
+ <!-- Explain why this is or is not safety-relevant. If context_dependent, explain what contexts would make it safety-relevant. -->
23
+
24
+
25
+
26
+ ## Description
27
+
28
+ <!-- Precise technical description of the anomaly. -->
29
+
30
+
31
+
32
+ ## Affected Components
33
+
34
+ <!-- Which MADDENING modules/nodes are affected? -->
35
+
36
+ -
37
+
38
+ ## Affected Versions
39
+
40
+ <!-- Which MADDENING versions exhibit this anomaly? -->
41
+
42
+
43
+
44
+ ## Steps to Reproduce
45
+
46
+ <!-- Minimal code or steps to reproduce the anomaly. -->
47
+
48
+ ```python
49
+
50
+ ```
51
+
52
+ ## Expected Behavior
53
+
54
+ <!-- What should happen? -->
55
+
56
+
57
+
58
+ ## Actual Behavior
59
+
60
+ <!-- What actually happens? -->
61
+
62
+
63
+
64
+ ## Workaround
65
+
66
+ <!-- Is there a workaround? If so, describe it. If not, state "None known." -->
67
+
@@ -0,0 +1,95 @@
1
+ name: CI
2
+
3
+ on:
4
+ push:
5
+ branches: [main]
6
+ pull_request:
7
+ branches: [main]
8
+
9
+ jobs:
10
+ test:
11
+ runs-on: ubuntu-latest
12
+ strategy:
13
+ matrix:
14
+ python-version: ["3.10", "3.11", "3.12"]
15
+
16
+ steps:
17
+ - uses: actions/checkout@v4
18
+
19
+ - name: Set up Python ${{ matrix.python-version }}
20
+ uses: actions/setup-python@v5
21
+ with:
22
+ python-version: ${{ matrix.python-version }}
23
+
24
+ - name: Install dependencies
25
+ run: |
26
+ python -m pip install --upgrade pip
27
+ # Pin JAX to known-good version to avoid jaxlib segfaults
28
+ pip install "jax==0.5.1" "jaxlib==0.5.1"
29
+ pip install -e ".[ci]"
30
+
31
+ - name: Run tests
32
+ env:
33
+ JAX_PLATFORMS: cpu
34
+ XLA_FLAGS: "--xla_gpu_autotune_level=0"
35
+ PYTEST_DISABLE_PLUGIN_AUTOLOAD: "1"
36
+ run: |
37
+ python -m pytest tests/ -v --tb=short --ignore=tests/viz
38
+
39
+ test-usd:
40
+ runs-on: ubuntu-latest
41
+ steps:
42
+ - uses: actions/checkout@v4
43
+
44
+ - name: Set up Python
45
+ uses: actions/setup-python@v5
46
+ with:
47
+ python-version: "3.12"
48
+
49
+ - name: Install dependencies (with USD)
50
+ run: |
51
+ python -m pip install --upgrade pip
52
+ pip install "jax==0.5.1" "jaxlib==0.5.1"
53
+ pip install -e ".[ci,usd]"
54
+
55
+ - name: Run USD tests
56
+ env:
57
+ JAX_PLATFORMS: cpu
58
+ PYTEST_DISABLE_PLUGIN_AUTOLOAD: "1"
59
+ run: |
60
+ python -m pytest tests/usd/ -v --tb=short
61
+
62
+ compliance:
63
+ runs-on: ubuntu-latest
64
+ steps:
65
+ - uses: actions/checkout@v4
66
+
67
+ - name: Set up Python
68
+ uses: actions/setup-python@v5
69
+ with:
70
+ python-version: "3.12"
71
+
72
+ - name: Install dependencies
73
+ run: |
74
+ python -m pip install --upgrade pip
75
+ pip install "jax==0.5.1" "jaxlib==0.5.1"
76
+ pip install -e ".[ci]"
77
+
78
+ - name: Validate anomaly registry
79
+ run: python scripts/check_anomalies.py
80
+
81
+ - name: Check implementation mapping
82
+ run: python scripts/check_impl_mapping.py
83
+
84
+ - name: Check bibliography citations
85
+ run: python scripts/check_citations.py
86
+
87
+ - name: Check transform registry
88
+ run: python scripts/check_transforms.py
89
+
90
+ - name: Run compliance tests
91
+ env:
92
+ JAX_PLATFORMS: cpu
93
+ PYTEST_DISABLE_PLUGIN_AUTOLOAD: "1"
94
+ run: |
95
+ python -m pytest tests/compliance/ tests/verification/ -v --tb=short
@@ -0,0 +1,62 @@
1
+ name: Publish to PyPI
2
+
3
+ # Publishes `maddening` to PyPI on every GitHub Release whose tag starts
4
+ # with `v` (e.g. v0.1.0). Uses PyPI Trusted Publishing (OIDC) — no API
5
+ # token is stored in the repo; the publisher is configured at
6
+ # https://pypi.org/manage/account/publishing/ with:
7
+ # project : maddening
8
+ # owner : Microrobotics-Simulation-Framework
9
+ # repository : MADDENING
10
+ # workflow : publish.yml
11
+ # environment : pypi
12
+
13
+ on:
14
+ release:
15
+ types: [published]
16
+ workflow_dispatch:
17
+
18
+ permissions:
19
+ contents: read
20
+ id-token: write # required for Trusted Publishing OIDC
21
+
22
+ jobs:
23
+ build:
24
+ name: Build sdist + wheel
25
+ runs-on: ubuntu-latest
26
+ steps:
27
+ - uses: actions/checkout@v4
28
+
29
+ - name: Set up Python
30
+ uses: actions/setup-python@v5
31
+ with:
32
+ python-version: "3.12"
33
+
34
+ - name: Install build
35
+ run: python -m pip install --upgrade pip build
36
+
37
+ - name: Build distributions
38
+ run: python -m build
39
+
40
+ - name: Sanity-check distributions
41
+ run: |
42
+ python -m pip install --upgrade twine
43
+ python -m twine check dist/*
44
+
45
+ - uses: actions/upload-artifact@v4
46
+ with:
47
+ name: dist
48
+ path: dist/
49
+
50
+ publish:
51
+ name: Publish to PyPI
52
+ needs: build
53
+ runs-on: ubuntu-latest
54
+ environment: pypi
55
+ steps:
56
+ - uses: actions/download-artifact@v4
57
+ with:
58
+ name: dist
59
+ path: dist/
60
+
61
+ - name: Publish to PyPI
62
+ uses: pypa/gh-action-pypi-publish@release/v1
@@ -0,0 +1,18 @@
1
+ __pycache__/
2
+ *.pyc
3
+ *.egg-info/
4
+ dist/
5
+ build/
6
+ .claude/*
7
+ !.claude/skills/
8
+ *.png
9
+ *.npz
10
+ .venv/
11
+ *.jsonl
12
+
13
+ # For throwaway / convenience files that shouldn't be pushed
14
+ tmp/
15
+
16
+ # Cloud credentials — NEVER commit
17
+ src/maddening/examples/cloud/config/cloud_credentials.yaml
18
+ src/maddening/examples/cloud/config/.env
@@ -0,0 +1,14 @@
1
+ # SkyPilot workdir sync exclusions
2
+ # Only sync source code + config, not venvs/caches/artifacts
3
+ .venv/
4
+ __pycache__/
5
+ *.pyc
6
+ *.egg-info/
7
+ dist/
8
+ build/
9
+ .git/
10
+ .claude/
11
+ tmp/
12
+ *.npz
13
+ *.png
14
+ *.jsonl
@@ -0,0 +1,139 @@
1
+ # Changelog
2
+
3
+ All notable changes to MADDENING will be documented in this file.
4
+
5
+ The format is based on [Keep a Changelog](https://keepachangelog.com/en/1.1.0/),
6
+ and this project adheres to [Semantic Versioning](https://semver.org/spec/v2.0.0.html).
7
+
8
+ Additional sections per release: **Verification**, **Security**, and **Known Anomalies**.
9
+
10
+ ## [Unreleased]
11
+
12
+ ### Added
13
+ - Coupling convergence infrastructure: per-field mixed atol/rtol norm (`convergence_norm="mixed"`), convergence diagnostics (`diagnostics=True`), Aitken delta-squared acceleration (`acceleration="aitken"`), fixed under-relaxation (`acceleration="fixed"`), and Jacobi iteration mode (`iteration_mode="jacobi"`)
14
+ - `coupling_acceleration` module with standalone JAX-traceable residual norms, state flatten/unflatten, and acceleration functions
15
+ - `GraphManager.coupling_diagnostics()` method for retrieving iteration counts and final residuals
16
+ - IQN-ILS quasi-Newton coupling acceleration (`acceleration="iqn-ils"`) with Aitken fallback, pre-allocated matrices for fori_loop compatibility, and automatic column management
17
+ - Subcycling within coupling groups (`subcycling=True`) for mixed-timestep coupling with linear/constant boundary interpolation
18
+ - Spatial interpolation map factories in `interface_mapping` module: `nearest_neighbor_1d`, `linear_interpolation_1d`, `rbf_interpolation` (4 kernels), `conservative_projection_1d`
19
+ - `auto_couple()` and `add_coupling_group()` accept `**kwargs` forwarded to `CouplingGroup`
20
+ - Coupling examples: acceleration comparison, Jacobi vs Gauss-Seidel, subcycling, spatial interpolation, convergence diagnostics
21
+ - IQN-ILS/IMVJ auto interface-field detection: `flatten_coupled_state` accepts `fields` parameter to accelerate only coupling-edge fields, reducing V/W matrix size for nodes with many internal DOFs
22
+ - IQN-IMVJ multi-timestep Jacobian reuse (`acceleration="iqn-imvj"`, `jacobian_reuse=N`): warm-starts V/W from previous timestep for faster convergence
23
+ - Interface residual convergence norm (`convergence_norm="interface"`): checks coupling-edge values between iterations instead of full state change
24
+ - Quadratic subcycling boundary interpolation (`boundary_interpolation="quadratic"`): Lagrange interpolation through three successive iteration values
25
+ - Waveform relaxation for subcycled groups (`waveform_iterations=N`): repeats coupling block to improve boundary data quality
26
+ - Flux-based coupling: `SimulationNode.compute_boundary_fluxes()` exposes derived quantities (heat flux, spring force) consumable via edges; `SimulationNode.boundary_input_spec()` declares expected inputs with `BoundaryInputSpec` descriptors
27
+ - `EdgeSpec.additive` flag: edges with `additive=True` accumulate values instead of overwriting, enabling multi-source force/flux coupling
28
+ - `coupling_helpers` module: `add_value_coupling`, `add_flux_coupling`, `add_dirichlet_neumann_pair`, `add_symmetric_value_coupling`, `add_robin_coupling`, `check_conservation`
29
+ - `BoundaryInputSpec` dataclass and `boundary_input_spec()` on HeatNode, SpringDamperNode, BallNode, RigidBody2DNode
30
+ - `compute_boundary_fluxes()` on HeatNode (left/right heat flux) and SpringDamperNode (spring force)
31
+ - Flux coupling demo and node authoring guide sections on flux coupling patterns
32
+ - `TransformRegistry` with `@register_transform` decorator for named, serializable edge transforms; built-in transforms (`extract_first`, `extract_last`, `negate`, `scale`, `identity`); `GraphManager.add_edge` accepts string transform names
33
+ - `scripts/check_transforms.py` CI validation script for string transform references
34
+ - Gradient health audit: verified `jax.grad` finite through 1000-step coupled rollouts for springs, heat rods, and multi-physics systems
35
+ - Parameter recovery baseline: gradient-based recovery of spring stiffness and damping from trajectory data (inline physics, proving differentiability concept)
36
+ - Interface DOF awareness: `interface_dof_indices()` and `compute_interface_correction()` on SimulationNode; coupling system re-applies interface values after node update, fixing the DD coupling "cold lock" where HeatNode's Dirichlet BC enforcement prevented heat transfer
37
+ - Coupling iteration predictors (`predictor="linear"` or `"quadratic"` on CouplingGroup): extrapolates initial guess from previous timesteps' converged states, reducing iteration count
38
+ - `tune_coupling_params()` utility for grid-search optimization of coupling parameters (tolerance, max_iterations, acceleration)
39
+ - `HybridNode` wrapper: composes a physics node with an additive correction function; `generate_correction_data()` for training integration error correctors
40
+ - `derivatives()` method on SimulationNode with implementations on BallNode, SpringDamperNode, HeatNode; `integrators` module with `euler_step`, `heun_step`, `rk4_step` and convenience `integrate_node()`
41
+ - `calibrate()` utility for gradient-based parameter recovery from reference trajectories using `jax.grad`
42
+ - Implicit node support: `implicit_residual()` on SimulationNode with fixed-count Newton iteration via `jax.lax.fori_loop`; implemented for SpringDamperNode and HeatNode; unconditionally stable for stiff problems
43
+ - OpenUSD integration: codeless schemas (`MaddeningSimulationGraph`, `MaddeningNode`, `MaddeningEdge`, `MaddeningCouplingGroup`, `MaddeningExternalInput`), `USDWriter` for time-sampled state output, `save_graph_to_usd()` / `load_graph_from_usd()` for full graph serialization, late-registration guard with RuntimeError
44
+ - HeatNode 4th-order FD stencil (`stencil_order=4`), non-uniform grid support (`grid_points` parameter)
45
+ - 2D spatial interpolation: `nearest_neighbor_2d()`, `rbf_interpolation_2d()` in interface_mapping
46
+ - USD geometry reader: `load_grid_from_usd()`, `create_vessel_phantom()` (Y-shaped bifurcating vessel)
47
+ - `geometry_source` attribute on SimulationNode for USD-initialized nodes
48
+ - Vessel bifurcation coupling example: three HeatNodes initialized from USD geometry, coupled at Y-junction
49
+ - `HistoryViewer3D.add_curve_tube()`: render 3D centerline tubes colored by scalar fields (vessels, pipes, rods)
50
+ - `HistoryViewer3D.add_line_plot()`: render 1D fields as 3D line plots (temperature profiles, wave solutions)
51
+ - `viewer_from_usd()`, `viewer_from_usd_with_geometry()`, `render_usd_frame()`: bridge USD results data to the general-purpose HistoryViewer3D for interactive replay and screenshots
52
+ - USD tests skip gracefully when `usd-core` is not installed (CI compatibility for Python 3.10/3.11)
53
+ - `LBMNode`: general 3D Lattice Boltzmann on boolean mask domains with D3Q19/D2Q9 lattices, Zou-He pressure BCs, Guo forcing, runtime clot injection via `wall_mask_update`
54
+ - `lbm_geometry.voxelize_vessel()`: analytical Y-bifurcation voxelizer parametric by vessel geometry
55
+ - `RigidBodyNode`: full 6DOF rigid body (quaternion orientation, diagonal inertia, DOF constraints). `RigidBody2DNode` deprecated with thin wrapper.
56
+ - `HeartPumpNode`: 2-element Windkessel model with pulsatile cardiac output, configurable heart rate / stroke volume / resistance / compliance, bidirectional pressure coupling
57
+ - `PyVistaLiveRenderer`: real-time 3D visualization backend with timer callbacks, pause/resume/speed keyboard controls
58
+ - Vessel bifurcation live example: real-time simulation + USD recording + PyVista visualization + heat pulse injection demo
59
+ - Vessel flow server: FastAPI server with HeartPump+LBM coupling, REST endpoints for heart rate / resistance / clot injection, WebSocket live vitals streaming, browser UI with pressure waveform chart
60
+
61
+ - Cloud module (`maddening.cloud`): `StreamingSession` ABC and `StreamConfig`/`StreamInfo`/`QualityPreset`/`GPUFramebuffer` data types for WebRTC viewport streaming; `MockStreamSession` for zero-dep testing; HMAC-SHA256 session token auth; `SelkiesSession` GStreamer/WebRTC implementation (requires PyGObject)
62
+ - `CloudSession` state machine with SkyPilot VM orchestration, typed health probes (`HealthProbeError` with stage attribution), `CloudReadyResult` with per-stage pass/fail, `MockCloudSession` for testing; preemption detection with configurable policy (CHECKPOINT/FAILOVER/ABORT)
63
+ - `SelkiesRenderer(Renderer)`: wraps inner renderer + `StreamingSession`, auto-detects GPU/CPU framebuffer path, emits `PerformanceWarning` on CPU fallback
64
+ - Multi-GPU Jacobi coupling: `create_device_mesh()`, `assign_nodes_to_devices()` with coupling co-location, `build_sharded_jacobi_pass()` for distributed node updates; `GraphManager.enable_multigpu()` method
65
+ - Cloud container: `docker/Dockerfile.cloud` (CUDA + GStreamer + MADDENING), `entrypoint.py` with JSON config deserialization
66
+ - Cloud API endpoints on `SimulationServer`: `POST /cloud/launch`, `GET /cloud/status`, `POST /cloud/teardown` (unconditionally registered, returns 501 if unconfigured)
67
+ - `CloudLauncher`: user-facing cloud job orchestration with `CloudJob` handle, `JobConfig` YAML loading, `CostPolicy` cost guards, credential context manager with cleanup, and `CloudJob.from_cluster_name()` reconnect
68
+ - `CloudProvider` ABC with `RunPodProvider` and `LambdaLabsProvider` (stub); per-provider credential file management with write/delete lifecycle
69
+ - Cloud examples consolidated under `src/maddening/examples/cloud/`: `01_validate.py` (dry-run), `02_runpod_launch.py` (real launch), config templates
70
+ - Restructured package extras: per-provider cloud (`runpod`, `lambda`, `aws`, `gcp`), hardware acceleration (`cuda12`, `tpu`), task bundles (`server`, `client`), combo (`cloud`, `cloud-all`)
71
+ - Consistent import guards across all optional dependencies: missing extras now raise `ImportError` with the exact `pip install maddening[extra]` command
72
+ - User guide: `docs/user_guide/installation.md` (full install reference), `docs/user_guide/quickstart.md` (5-minute intro)
73
+ - `CostPolicy.spot_fallback`: when spot instances are unavailable, auto-retry on-demand (subject to same cost guards); configurable via job config YAML
74
+ - `retry_until_up` on all SkyPilot launches to handle transient SSH/provisioning failures
75
+ - Concise error message for spot unavailability (truncates verbose per-region table); other errors preserved in full
76
+ - Multi-GPU Phase 1: `enable_multigpu()` wired into `_build_step_fn()` — Jacobi coupling uses `jax.device_put` for per-node device placement; correctness validated (single step, 100 steps, `lax.scan` all match non-sharded)
77
+ - Multi-job architecture: `Coordinator` (ZMQ ROUTER-based rendezvous with registration, topology broadcast, heartbeat monitoring), `CloudGroup` (provision rank-0 first, inject `COORDINATOR_ADDR` into workers, `teardown_all` / `teardown_one` with `ISOLATE` mode), `SubgraphSpec` + `GroupConfig`
78
+ - Cloud examples organized into subdirectories: `config/`, `launch/`, `server/`, `streaming/`, `multigpu/`, `multijob/`
79
+ - `requires_halo` abstract property on `SimulationNode` — every node must declare whether it needs halo exchange for sharding
80
+ - `ShardedNode` wrapper for data-parallel distribution of pointwise nodes across device meshes; rejects stencil nodes automatically
81
+ - `WorkerClient` for multi-job rendezvous: `register_and_wait()`, heartbeat, shutdown/peer_dead callbacks
82
+ - Validated 2-VM multi-job rendezvous on RunPod (coordinator + worker across VMs via ZMQ)
83
+ - Real multi-GPU benchmark on 2xRTX4090: correctness validated, JIT fusion behaviour documented
84
+ - Core reorganized into `core/coupling/`, `core/simulation/`, `core/compliance/` subpackages (backward compatible via `core/__init__.py` re-exports)
85
+ - Docker image `ghcr.io/microrobotics-simulation-framework/maddening-cloud:latest` — pre-built with JAX CUDA, GStreamer, ZMQ, FastAPI; set as default `container_image` in `JobConfig`
86
+ - CycloneDX SBOM generation (`sbom.json`) for IEC 62304 SOUP compliance
87
+
88
+ ### Fixed
89
+ - Subcycling dividers were inverted: fast nodes now correctly take multiple sub-steps while slow nodes take one step
90
+ - Coupling diagnostics were lost in multi-rate graphs when step counter overwrote `_meta`
91
+ - `maddening.compliance` namespace with schema types, anomaly validator, and CLI
92
+ - `NodeMeta` dataclass with `hazard_hints`, `validated_regimes`, `implementation_map` fields
93
+ - `StabilityLevel` and `UQReadiness` enums
94
+ - `@verification_benchmark` decorator and `ValidationBenchmark` registry
95
+ - `@stability` decorator (identity decorator; functional machinery in Phase 4)
96
+ - `HealthCheckNode` for execution-layer fault detection
97
+ - `NodeMeta` attached to all existing nodes (BallNode, TableNode, SpringDamperNode, RigidBody2DNode, HeatNode, LBMPipeNode)
98
+ - `AuditLogger` with `NullSink` and `JSONFileSink`
99
+ - `SimulationProvenance` for reproducibility tracking
100
+ - `UncertaintySpec` and `UncertainParameter` for UQ interface
101
+ - Regulatory documentation: `intended_use.md`, `downstream_integration.md`, `iec62304_mapping.md`, `eu_mdr_guidelines.md`, `mdcg_2019_11.md`
102
+ - `known_anomalies.yaml` with MADD-ANO-001 and MADD-ANO-002
103
+ - `soup_package.md` (skeleton)
104
+ - `SECURITY.md`, `CONTRIBUTING.md`, `CITATION.cff`
105
+ - Algorithm guide template and HeatNode algorithm guide
106
+ - `scripts/check_anomalies.py`, `scripts/check_impl_mapping.py`, and `scripts/check_citations.py`
107
+ - GitHub issue template for anomalies
108
+ - Developer guide: `docs/developer_guide/` with `node_authoring.md`, `documentation_standards.md`, `testing_standards.md`
109
+ - Bibliography citation system: Pandoc-style `[@Key]` syntax with CI validation
110
+ - Claude skill `.claude/skills/commit-and-push/` for commit/push compliance checklist
111
+ - Migrated to `src/` layout with hatchling build backend
112
+ - Reorganized tests into subdirectories: `core/`, `nodes/`, `surrogates/`, `api/`, `viz/`, `compliance/`, `verification/`
113
+
114
+ ### Changed
115
+ - Build backend: setuptools → hatchling
116
+ - Package layout: flat → src/
117
+ - `pyproject.toml` URLs updated to Microrobotics-Simulation-Framework org
118
+
119
+ ### Verification
120
+ - 512+ existing tests pass after restructure
121
+ - New compliance test suite validates all Phase 0-4 artifacts
122
+
123
+ ### Security
124
+ - No security-relevant changes in this release
125
+
126
+ ### Known Anomalies
127
+ - MADD-ANO-001: LBM GPU segfault on CUDA 12.2 + jaxlib 0.5.1 (open, context_dependent)
128
+ - MADD-ANO-002: HeatNode CFL stability not enforced at runtime (open, context_dependent)
129
+
130
+ ## [0.1.0] - 2025-03-01
131
+
132
+ ### Added
133
+ - Initial release: modular simulation framework with functional state pattern
134
+ - Core: GraphManager, SimulationNode ABC, EdgeSpec, scheduling, coupling, adaptive timestepping, parameter sweeps, checkpoint/restore
135
+ - Nodes: BallNode, TableNode, SpringDamperNode, RigidBody2DNode, HeatNode, LBMPipeNode
136
+ - Surrogate framework: SurrogateArchitecture ABC, SurrogateNode, SurrogateTrainer, DatasetGenerator, architectures (MLP, DeepONet, SDeepONet, FNO)
137
+ - Visualization: matplotlib, terminal, PyVista, pygfx backends; ZMQ network transport
138
+ - API: FastAPI server with REST, WebSocket (JSON + binary), server-side rendering
139
+ - 545+ tests
@@ -0,0 +1,23 @@
1
+ cff-version: 1.2.0
2
+ title: "MADDENING: Modular Automatic Differentiation and Data-Enhanced Neural-network INteracting Graph"
3
+ type: software
4
+ version: 0.1.0
5
+ date-released: "2025-03-01"
6
+ license: LGPL-3.0-or-later
7
+ repository-code: "https://github.com/Microrobotics-Simulation-Framework/MADDENING"
8
+ abstract: >
9
+ A JAX-based modular simulation framework for multi-physics.
10
+ MADDENING provides a functional-state graph architecture for
11
+ composing, coupling, and differentiating physics simulations
12
+ with automatic differentiation and neural surrogates.
13
+ authors:
14
+ - family-names: Roy
15
+ given-names: Nicholas Ehsan
16
+ keywords:
17
+ - simulation
18
+ - multi-physics
19
+ - JAX
20
+ - automatic differentiation
21
+ - lattice Boltzmann
22
+ - neural surrogates
23
+ - microrobotics
File without changes