{
  "base_source_files": {
    "benchmarks/accuracy_regression.py": "4489397c669e9e273e0a4524844bc487223d03a412907f964721cff6a0e3d00a",
    "benchmarks/cpu_workflows.py": "0f3b40646db7f2e0ab3db9536a55f72b8031d2eccc2b462cf87b76228a5d1b0d",
    "benchmarks/rc_bench/__init__.py": "7da756e59fdcaa2b6efbd663ecd5eea2dd3299724fbd2f0b665b99a870ddd62c",
    "benchmarks/rc_bench/_threads.py": "5c6c8db3c8f47937af4ffdada12ec4b8d0d769097b4c4f0a8b8b5aa6819e2e30",
    "benchmarks/rc_bench/adapters/__init__.py": "b2cef27e2dc9398df0974ed409f854bd44de22a0d69596eefaf36c936d8633e2",
    "benchmarks/rc_bench/adapters/base.py": "e3c722badddd77005444b6b1c80dca48643e0f910d05f817baa1094747f7f964",
    "benchmarks/rc_bench/adapters/julia_adapter.py": "43cde719a0a9387fd97fed33aa5d3997dd374bda6a3854c9d264fb864fec85b3",
    "benchmarks/rc_bench/adapters/resdag_adapter.py": "9beb8f098759bf989354ecbf6fe07451b6fd0f13edbb6cbc97dd673971b399c1",
    "benchmarks/rc_bench/adapters/reservoirpy_adapter.py": "eebb3c8311e2d335fd930fed50b7ec26cbdc25c728b0c0be9b18e9f11bd95071",
    "benchmarks/rc_bench/budget.py": "ff1c415f8669e09eb86496960cae848a3c4491ad1ebdb656304e25f2934f44c9",
    "benchmarks/rc_bench/budget_adapters.py": "d5d37eec28e88376f0505d0cf15447a7cd381044aaa10219c1b2ee4ece8dc2e1",
    "benchmarks/rc_bench/config.py": "b1dafd96f4bd34805ccaac98b1910c09fac0aac2bb0c69b9c0639a90ded2ec0d",
    "benchmarks/rc_bench/data.py": "c692c733e1b070aabf049bbb0fb024705f3b30cfbf023343be5e7cbb89f3341a",
    "benchmarks/rc_bench/env.py": "a7f67b4d6d09616fc72ec36ee37aa2bd207f76125d2be9fa96d206d2807def56",
    "benchmarks/rc_bench/internal_cells.py": "b2055cbc51fd24c59dd4971b17f7536c515405b7ec899dc29050b479f25c74ec",
    "benchmarks/rc_bench/metrics.py": "80046a0934d83ac1b7e75dff22038fedc71f46b7246b541ceef39e4cc5b3f174",
    "benchmarks/rc_bench/report.py": "65dd443c41c4d48ddb88e6dd819994eac2c865ac26af37b8b314bec065031ea0",
    "benchmarks/rc_bench/run.py": "34105c4f4251722180b649c7b0d49ad4b3df767f81d173d4843ee48a75b9ddd4",
    "benchmarks/rc_bench/timing.py": "39498f8b6c64ab217813db551dfdca1f0f8cf1e24bf645e9d707c332de908008",
    "benchmarks/single_pass_training.py": "d39c665f72e78b6f3924e613e49d1c38c956378e15f0975cf747e5f14b48d349",
    "benchmarks/tuned_accuracy.py": "559c58878ef14a6ee620f57b8e86d85e6ea1bf618edabf2bd02919ba3f0ab91e",
    "src/resdag/__init__.py": "c42dac72173d616837fc4592c6f1621879394bfcadfb6d4d06c2d964a197177d",
    "src/resdag/_contracts.py": "88da074cc7adc865cba28ac6c07cbb0c674fd7d19776eb34f5ddcddfa98c7a10",
    "src/resdag/artifacts/__init__.py": "1f5cc28e3e414a7e66262bc405663ada64ccc4f7c13919757020fc6c8618b699",
    "src/resdag/artifacts/_api.py": "e23908e4c9a644578ca64542e0fe0c6904d04db64ad9d6f46fa55238849a9689",
    "src/resdag/artifacts/_codecs.py": "b52d6e87d37043a10a0b521d3300fa2b0e0f2dde83eb6c6025b9f9b195a046b5",
    "src/resdag/artifacts/_models.py": "6205af9db6b2734a3316cdd18e2a7ba554a200ef14e2a47ace0b3859b10bc001",
    "src/resdag/artifacts/_registry.py": "308c1ed43047f158d555acfc4e2a5e19eebdf2fa45f5a9eb9e78646d03d2d564",
    "src/resdag/core/__init__.py": "16d46d25e14ac133f4a3712037e487c0ac732ee1050926584e829b72ed7d1da5",
    "src/resdag/core/_diagram.py": "cd37ac3af23ac9113b4e8905ffcabab2aff01db528d80bccffc6a308919e2f1f",
    "src/resdag/core/_execution.py": "8f0bf7815bb3f28a83643498d4b8409d74f8e2c6fc5bff7d0eb300b378035483",
    "src/resdag/core/_feedback.py": "2f3f9f37200eea0bc91b423da79becfeebafd3b0f0c7e241e37854390927e069",
    "src/resdag/core/_flat_inference.py": "4dc5db94a4d3253b3262cb8550b6bd662bbb48ca8be21883884ecff5882dd1f1",
    "src/resdag/core/_forecast.py": "8c53e5cb9630b9a4f282995c55c9c3662cc79879fde924d40100242501572716",
    "src/resdag/core/_forecast_capabilities.py": "04516a200598ad78bcf30dad6b660c8195be40e7805f466d66a73760c6dded8b",
    "src/resdag/core/_forecast_stream.py": "daebbc8ba808d9819c7df585e72078b816443ed199af2cc445e85fd636c0ac98",
    "src/resdag/core/_hooks.py": "0dd3cb837ea4e209dd4d5b38761931e8ec40ec81bb57b35c1855984fdd90d58a",
    "src/resdag/core/_modes.py": "65860239bec09ab9d4a05fa568ce59148b6b6816a54035bab689052babeb1869",
    "src/resdag/core/_persistence.py": "b40b0bd744834065f2a49dfc6962a2ef0755bf3d42603bf6a767325828ae554d",
    "src/resdag/core/_preprocessing.py": "9df196372ae4aae55a7287d481c0a7d0ac3557b1a23694376ed8307554689780",
    "src/resdag/core/_workflow_backends.py": "11b7d458577d52c3dba86137db5e0d315031baa4d9e45edff81cb15a972b3662",
    "src/resdag/core/_workflow_transforms.py": "7ee5a2adaddc1e6f076c129c0bda6eb92fae48f9e82bfbe3758f55cb74270a37",
    "src/resdag/core/feature_extractor.py": "8bbb7c694aca535402f5e9cf03c0d066e418677eaac8eb829accd82ea6ae33ce",
    "src/resdag/core/model.py": "98e9fcbdb11e8f596c637e50e6d10af6198d7220600243d0c72e32932d1ec113",
    "src/resdag/core/workflow.py": "0cdf5c23f685fdd2d9b2b925e4584a8c26f9258a1c3ae2ee4812e171457efe12",
    "src/resdag/data/__init__.py": "07dd030ed3f94267802181d4870a26b3b02980ca6257120873747c900fe91c0e",
    "src/resdag/data/_trajectory.py": "0a74ff17d4a22f50ad355e38f43e1af6bb1bef54503060d4ab7d787231024fe4",
    "src/resdag/data/_trajectory_ports.py": "cdf72c65358bc16c8a5334c8be7d05b64a84f148fd5317dd546697e79492c9b4",
    "src/resdag/data/dataset.py": "72906ccf027725433de70a4a1cd9de6937a073227509d6465373593edea8667a",
    "src/resdag/data/io.py": "445eea54340bd46fd7d8d103b1f662a1cd65d2ae1984e604ac42ab4c8bf53573",
    "src/resdag/data/prepare.py": "9987cb73f009a0a4fb703082aa3812caf0b5971b8895b28eb38bbef7554f94a3",
    "src/resdag/datasets/__init__.py": "402a12335b950051a07920686453a954ecf89fdfc32a91673448b1350ee71bef",
    "src/resdag/ensemble/__init__.py": "9663bdc37ea7d35a2707e3877c9d534171d4d5856cf51832ce16ddbb0f22a5bd",
    "src/resdag/ensemble/aggregators/__init__.py": "4bb5444d0f53a5c07e26e903b14bcf2fd430f7eaaab758592c17ffed8ea388f9",
    "src/resdag/ensemble/aggregators/outliers_filtered_mean.py": "6768a76a989c85c5e289a62e040c2b7fea11111c35e38d01a88d8576307e876d",
    "src/resdag/ensemble/coupled.py": "91030d82e38ecba87c39e837a0d7b0f5526e70f373d7f6e56a30045e5d3f8446",
    "src/resdag/facade.py": "e9096a624dc021d61b59b7ae1351904ec121449da82bdb23daa6bc3826ff6a4f",
    "src/resdag/hpo/__init__.py": "443562e7bcc84e566872eb96e2058aaf9c0d6c92067666c71d2462fe6780dbd4",
    "src/resdag/hpo/_parallel.py": "de30a6a89a28793e862edc13f9fd9da1ba8d64da0fa4471562280497411b7dcc",
    "src/resdag/hpo/_provenance.py": "e582372ccf6e60735e4037a7888897b655570234006ff2ca2b4f42e0ae26a2c6",
    "src/resdag/hpo/_torch_losses.py": "49daaaf381d9a12e8f29089f3f24ec3f0d04403aa374eba9c952996fb861f7b8",
    "src/resdag/hpo/_trial_progress.py": "4a82ad385573ced752e133e34dfcfe6246d616e4ad5fe5ebacc2dbe49d7e51f3",
    "src/resdag/hpo/_tuning_data.py": "b7806297c49fee6e6c272520d0a2d2c615a67635af2cfef6a819533312c11c89",
    "src/resdag/hpo/_tuning_scores.py": "d95657d58e3b2fda468db36290e29f233154f947432aea67a4c8b9be94cca50a",
    "src/resdag/hpo/dispatch.py": "5ed2a5993545cbd05ed0153874be3dfd1a452dc7d35100d84d8271f6d9f3067f",
    "src/resdag/hpo/losses.py": "ce7fcc5818835af36d694470d5434e9c1aae06a51f7cf3ebafac81217f36c68c",
    "src/resdag/hpo/objective.py": "9029d3a0f6ff42356fa0db0b0bb18bc30bf0d05944a6945f4ed1bb5d406717e9",
    "src/resdag/hpo/pruners.py": "c69bec20658a03c9b640121d93ff743d842dc1e919118aef4ee660ec0715c8c2",
    "src/resdag/hpo/resources.py": "d8ceb668a06caa4340700b5bd2927deba6c8d2d000d079cefa55e7484bc70d51",
    "src/resdag/hpo/run.py": "1932bb4fe3f51c220f3e6af7746411eb08ad3d6a36ccc086fd567cd44ae7b812",
    "src/resdag/hpo/storage.py": "925a685184d4648bd2f8b0e7dd63b4f72682e183e2ac063448b1aa40b539fe6a",
    "src/resdag/hpo/transfer.py": "ead7c2efb06c2a9d70132c7b7d124ef2b1922084d7b0f8604e1ac5aee79f00b6",
    "src/resdag/hpo/trial_runner.py": "5cd5f0c53ac6d6868b476c073b019a9bad996d05f5883ab892ef1e5e51541782",
    "src/resdag/hpo/tuning.py": "bd6521926362efc4b9d4bbdf60e59f55cc2c2bbf5803a6ee7732ef1a390e6eac",
    "src/resdag/hpo/utils.py": "34e98a5584a9bbb496cf5954b1be625f635159db6ccd06fcec74a34e61eff5ec",
    "src/resdag/init/__init__.py": "693dea2d9076b80f240f01453fa1c1f7cdf19b76126e3c3e456009265a406fa4",
    "src/resdag/init/graphs/__init__.py": "72a620e96a6f611ebc8fc15bee581fa8cefbe453e5752ac586b8a4ed8c001f2a",
    "src/resdag/init/graphs/_dense.py": "63230c37085569f929155e4b58bf749036dbeec9333992ee56433933393217a4",
    "src/resdag/init/graphs/_sparse.py": "1f32032dc1a3a62aed94c63c9c00b051f12e92ae1ee339707fc3841efe75c073",
    "src/resdag/init/graphs/barabasi_albert.py": "16d1c4612e7a66666287829539d1518a4b52cc56c65b36e11bfa39e46a502825",
    "src/resdag/init/graphs/chord_dendrocycle.py": "767db6261bea6ade8d74e782577dfe7e6ee3261dae8291c49ef309fab6af298c",
    "src/resdag/init/graphs/complete.py": "57396b4b16c83c4a253834843ad18cbe32179fdc6b41e35e6d91f4a1213ea387",
    "src/resdag/init/graphs/connected_erdos_renyi.py": "11cac53111282a40e22e1a93f221e0d8aa5bf83ef6f41072163f59bd8f169fc1",
    "src/resdag/init/graphs/connected_watts_strogatz.py": "d5026a579ed242089facdba63a56f9ead2ad3bbcc5fbe6dae46b0a78a27ccaeb",
    "src/resdag/init/graphs/dendrocycle.py": "cd2d612a02fa79770bf82b819da1019d9d8bff842aa2fd7a848ee1bc3f2aae0f",
    "src/resdag/init/graphs/erdos_renyi.py": "f7d7cc1bafd9bad5dfcb0c5c8ed2f9c43b427b5a6f447eead3e550d8d98c1d88",
    "src/resdag/init/graphs/kleinberg_small_world.py": "c8282657ed3e0d5950c3b18510e9d639eb607818bc54dcddceecd5e3d39c27df",
    "src/resdag/init/graphs/multi_cycle.py": "d4e71f43d5f4850d05c14dc7a5ca53c6225ecf2c436b5b357ca26cf53d65e854",
    "src/resdag/init/graphs/newman_watts_strogatz.py": "22448a8775182eb632f7289618e7e8d62fa97c676e38039b8b5555a0804d165d",
    "src/resdag/init/graphs/random.py": "a5fd59473257a9e626408a04d3e5188611512c77e74652f14616258af9c6c904",
    "src/resdag/init/graphs/regular.py": "42b65129f4b9a491ca7afebee788ad21985f25b86fa57997cb36c0ec71e11b98",
    "src/resdag/init/graphs/ring_chord.py": "d2b241df32c18460ee5794514c42f683548f1a222b9cbee8212e474c5d6dc922",
    "src/resdag/init/graphs/simple_cycle_jumps.py": "d88e0c35a225dd84e78a179a630ae13e8d80b2154eb7635234302760577837cc",
    "src/resdag/init/graphs/spectral_cascade.py": "30ae1e8dda3593159b35f283d9cbe4372c5c72e85a10d83fbc7ffd1ea770516f",
    "src/resdag/init/graphs/watts_strogatz.py": "9e134327c097d0f2518594ecfdc85fee19b2888a5d4f386d1ff4a4da8cb7dddc",
    "src/resdag/init/graphs/zero.py": "f20b4c62c720afd3f05c2707b8a607d91eadf487bad988befa4f2895d9dd14ef",
    "src/resdag/init/input_feedback/__init__.py": "708ba4b80ac8983a1e944e85e65cc88e8f92d7b2a94ae1032a49770c11b2e82d",
    "src/resdag/init/input_feedback/_sign_sampling.py": "c27e79fc538a8b5f3305f8de5feda2de5f7dd68aa56fa7e4d7491a3fdf896a9d",
    "src/resdag/init/input_feedback/base.py": "a0093c432c69da7805378af14ca03bfb957cedfad5aa5485d52db6d9101b70f5",
    "src/resdag/init/input_feedback/bernoulli.py": "43d87f6cc8ef466e80854d9f480e29bad265cb22b15d69e3e65d0def992c75a2",
    "src/resdag/init/input_feedback/binary_balanced.py": "53675a1e9c70163ad97925e5c55dbc028f7682d248970f614b276be5f58781e8",
    "src/resdag/init/input_feedback/chain_of_neurons_input.py": "a725ff24c15c1825503a48eaeaf5261de7834e6c7e758ddbbb66c7a7111ed3e2",
    "src/resdag/init/input_feedback/chebyshev.py": "f168fd899c7e3c35d708c016128be7880cdf593b734f9e512eca98899fbf31d4",
    "src/resdag/init/input_feedback/chessboard.py": "8fb0626923cf42078ed17c61ca451e813f3a3f55bab914beaa99b89ffe8cf69f",
    "src/resdag/init/input_feedback/dendrocycle_input.py": "8a6288cc0d33d0a6855c93bfb08cc403ff97308dcade31eed782afd4f7a59614",
    "src/resdag/init/input_feedback/function.py": "8e72c5e3fd854d95bd610af04b23e2fe3a5c42b375e96b5d84f421c78d938c38",
    "src/resdag/init/input_feedback/informed.py": "be7f7db1c3eadbb2f538bcf8d3b2e919cd4274728380b50e4c2a71a274553813",
    "src/resdag/init/input_feedback/logistic_mapping.py": "d34741496fa9515b0f95073f6f0b90a5da767f2109ac3c7bc5170c2bb5f585d5",
    "src/resdag/init/input_feedback/minimal.py": "79655eedb8cb6daf86c6a4371cea76a2a5fb799d37ccfff8263ed117ca455460",
    "src/resdag/init/input_feedback/normal.py": "aca3c5a4cbe993722201072ab0299756c0d7c39e1b81c26345ada65a90d832e9",
    "src/resdag/init/input_feedback/opposite_anchors.py": "9a8c2a3894491758823263d666dfadd7a53433e495739de2334c01d3b1267471",
    "src/resdag/init/input_feedback/pseudo_diagonal.py": "aa64cc288836aa1cb35e7b4738508eb6ac13f0a8628a2ec9b9de682de40dc51f",
    "src/resdag/init/input_feedback/random.py": "b32018dcd7e11b1bfdf476ec3de9c5f8894faa3e83b111e399ccf683855fb100",
    "src/resdag/init/input_feedback/random_binary.py": "d0633ded78a4cb679ae57c74beb14316a86d2a83948e5a130df453878d0615cb",
    "src/resdag/init/input_feedback/registry.py": "aa407e5d92b296dfe518e83887e259a6e4c48308aba396d8c161ffb3b1caab31",
    "src/resdag/init/input_feedback/ring_window.py": "ffe21ab2f0de06e9b48d0712cc3d76636a55f612bc5735807c38229939caff37",
    "src/resdag/init/input_feedback/uniform.py": "376d7ce7941ad8e8c111cec4d6880c677a3cbff1ed6d8f89d13db9a8c6816dca",
    "src/resdag/init/input_feedback/weighted.py": "877cae56ea1b204a15bf0729166ba855abd5c6c7794f713ce56412867084acab",
    "src/resdag/init/input_feedback/zero.py": "dffbcd650a4752edf116d0568b3eb290018352c5b54cd3a9d1272d9b5c4434f5",
    "src/resdag/init/matrices/__init__.py": "a8a66d7f933145e0f6b2c4ffe89ffa55bddbecc9d43bab2e4e0de56be09770f4",
    "src/resdag/init/matrices/_common.py": "0fbd8956b1fc19dfd14ccd4ca1da34d5e916a6c3a32e8b5b9e9e6d9e926839f4",
    "src/resdag/init/matrices/antisymmetric.py": "96c5b9b3384df3a8e5185bcf8a9ec3b08feefb834d310451cccc672d01646189",
    "src/resdag/init/matrices/fsi.py": "bf6e30a856ae1b3b2f2f2f16cd7685f44707371e298b3c8ff30a70ac654e550d",
    "src/resdag/init/matrices/minimal.py": "79e9169055a4a529847528c14f3b6842f8ffcdde12cec24dbef3c55c5c75b56c",
    "src/resdag/init/matrices/orthogonal.py": "d44540819fa15e05bff1d3d143187b7233048b670f2f59b8297d542d9615b65d",
    "src/resdag/init/matrices/orthogonal_structures.py": "4e2fa149229cb6a6b391643379743b5fc4d742942fce87650e89e689d0245e91",
    "src/resdag/init/matrices/spectral.py": "b16dd21047efb5582707fc0d8fe25a174689cd763d27daec49a2cbcef029136a",
    "src/resdag/init/matrices/structured.py": "78f992c40ee2a00c46e2d85337c900a5c5e4524caec2355347f5b540b54f8ac1",
    "src/resdag/init/recurrent.py": "e381a8453de4304b761a46ea591ae1ddb3f5e3a3b1a730d2f799826c82a82d30",
    "src/resdag/init/topology/__init__.py": "d68bdd19da61d53fb43731f94122ddd5d896f935a66cd6a6f111df70f4a97857",
    "src/resdag/init/topology/_structured.py": "4a9f26fc9bade9645d5320f6e0ba27e5370c581a9cc2a7a80ebdc4aa5fb759f3",
    "src/resdag/init/topology/base.py": "b2a15a5bd6bc5ffea1af1fd6dea1ca508731a99ba150e174f73b31c69b942ca0",
    "src/resdag/init/topology/registry.py": "65695d210e266f659a51f893551a51b0067adcaa9182253f2a7355aa6a198e43",
    "src/resdag/init/utils/__init__.py": "05f52bd7820e0a15713c238fbe48b0b06c9460060dfe1859150296bee67b5c80",
    "src/resdag/init/utils/graph_tools.py": "b87c219785992c6f7b71b3233c5ad0a4243a64efae23dc22575a2704ac87467c",
    "src/resdag/init/utils/resolve.py": "671a3cae60d4a1af6126fe404b7103dffce68cfeae09c11c779cb7939aa09db8",
    "src/resdag/layers/__init__.py": "524ee601becb13cc7b465942f8788c7b5bbb4149470d1c3e016aafd21db5b82f",
    "src/resdag/layers/cells/__init__.py": "d56811b2c03792d7062b561a09f676802fe0435da89e796b5316db9bf5f7a1c5",
    "src/resdag/layers/cells/_compact_recurrent.py": "2b4c79395dfbda78daeec5482dd4996671c89fea560a4c8b78c1f3bb3feee6a3",
    "src/resdag/layers/cells/_initialization.py": "e45ad0187b2719f788934376fe9103cbd0e8832ee0afdfed36e612905ff89f2b",
    "src/resdag/layers/cells/_projected.py": "0b63466840fa57e5f1157fe5d9e6a40d11930749338d3a4778026d19e6989c13",
    "src/resdag/layers/cells/_skip_cell.py": "f142d16bf56ed12c67145fa767da9f45131d8ed2c0296553a52af7d3532c826d",
    "src/resdag/layers/cells/_structured_recurrent.py": "b0f493ef7da9b9bb579afbe586c169472d28162ff66da155162a6e2d6548a167",
    "src/resdag/layers/cells/base_cell.py": "02abd9249c173abe926b8d0895e5ddaa93f5ef50ad10d57b2b1c046422c3b613",
    "src/resdag/layers/cells/continuous_cell.py": "2ac6131537f0d436554d81e7bf0242a35267c8e3658f266053a51047b3e8be82",
    "src/resdag/layers/cells/cornn_cell.py": "c415eff19222258e4bbd8b3e8a226101da41af699b8a531fcf763aca4867539f",
    "src/resdag/layers/cells/es2n_cell.py": "c3045f48c70995321685cf50e920d7c5f1e6b4a4d63e556a056994106eb1b83d",
    "src/resdag/layers/cells/esn_cell.py": "8780f70ad5789571db30d543cdbd5f9862e556da2d260fd6463384b428c9da8a",
    "src/resdag/layers/cells/eusn_cell.py": "3227feae8d5de136e937142d80501d92a318a01bc0f0a5ba35d5f74b245a943e",
    "src/resdag/layers/cells/gated_cell.py": "b87f1ce0c7ee9dc67c3693750c41e67e2bd53b3acf704b54005faf72c31eb3ba",
    "src/resdag/layers/cells/legendre_delay_cell.py": "cc57f69602ed51ebd9ea20355fe143114629802fa2d44748e17d8174ab6756f4",
    "src/resdag/layers/cells/lif_cell.py": "1da640bea3654eb6c1cfde1d430abea8e7a1ffbe39cd3ab2a99b32a2441a2121",
    "src/resdag/layers/cells/ngrc_cell.py": "f51fb1706956c7df9b3974e7b107e67b3c628d3c751bb24310558d22b67bea0d",
    "src/resdag/layers/cells/resesn_cell.py": "2f004b33b36776c42cfef3cc7e86390f3f0aac96f2933b94e88a169e9d83b7e8",
    "src/resdag/layers/cells/spiking_cell.py": "ce83293d4d0e5b05ef25dd3431e81ad5347935cd1614f3822276a2aeb56d5540",
    "src/resdag/layers/cells/torch_recurrent_cell.py": "fb82d5f8d7c2309b6230fccd3462bb9cde487730718cb30639e5ce6f50589e24",
    "src/resdag/layers/readouts/__init__.py": "45d072a28ccb4c699822c859105ed562bc70c95ff07c12987c98cd20495bf3f3",
    "src/resdag/layers/readouts/_solve_utils.py": "df157a90dccc3e147981c184a543311f0786d338d99f24f0149954eccad6d3c5",
    "src/resdag/layers/readouts/auto_readout.py": "4fcf8e63085a00d2ec407452c9561e2b4eece9b6a622f84293a66928e5b31d0c",
    "src/resdag/layers/readouts/base.py": "55c0e7c9b8c955412f4c2281312b2c86e72d2203b5676b1e8adb33418075c65f",
    "src/resdag/layers/readouts/cg_readout.py": "b23c00c83a334d3bff69206280ab2754796155e795ffe16f8704ddec94b312a2",
    "src/resdag/layers/readouts/cholesky_readout.py": "c240a45504eccaf6a4168c60a0a89c11808b539db485e097b7a870924ac77127",
    "src/resdag/layers/readouts/fista_readout.py": "e4f0a326f986ce412ef66302fce457e4f38b2f03495ed8991130a1d104c09d4c",
    "src/resdag/layers/readouts/incremental_ridge.py": "8385c0c68ab2b3425288c218af8819f8ed9b90c72a9f237ea91952a917fc5cb7",
    "src/resdag/layers/readouts/lsmr_readout.py": "49e54144fe2add7ba982c1c4a376316d60d87e6736f20b33be2e7245bda5e325",
    "src/resdag/layers/readouts/pinv_readout.py": "6f875bbf8618beea062caddd6f6c98459cb0403b07de7619c5f6dfedde05314b",
    "src/resdag/layers/readouts/ridge_readout.py": "29ac7b0fd61582bd018db8e566a1a75b485407c70a0e17c5f09120164d1db920",
    "src/resdag/layers/readouts/rls_readout.py": "f61aebeb940bef8c4f1e5e739b2f1dd85c091948973a8753842c9918ef9b3ca4",
    "src/resdag/layers/readouts/svd_readout.py": "e4a79b9195d263a81e7fa23aaf31c54ada38fcf6f4c7189a65ef88443fc66891",
    "src/resdag/layers/reservoirs/__init__.py": "9d4dcb7c184a1c77ba5246b6c87895cf0e9ca29cdbdd2656e176c6f3a7b312f0",
    "src/resdag/layers/reservoirs/_cell_layer.py": "749dd38f93949c5378eb978361da56cc8e95fae506316aeb85e68644878919b1",
    "src/resdag/layers/reservoirs/base_reservoir.py": "ff87bb4aa80752bbcab84c00c9815f119a15d5d91fc2d0a81714d9a95c17e3f1",
    "src/resdag/layers/reservoirs/cornn.py": "2e8e351c5109002f6a34b00e75c7ed521fa6d07d797b22fb2cde11014adab806",
    "src/resdag/layers/reservoirs/es2n.py": "db72ebcbe9a38b92453e7b5dbef5ae836c1ef87d2cda561b7bf57132c2103160",
    "src/resdag/layers/reservoirs/esn.py": "d5a7493619adc35e1a4a7d0a0f425875fd6fbd8db7815d37555b861576748010",
    "src/resdag/layers/reservoirs/eusn.py": "ce6c5fa1eddb3ddf13047d0ef7a7e4b17810bb282742cb3e41a79426e60da7f7",
    "src/resdag/layers/reservoirs/gated.py": "2debd889c4c1e236383a7fe464617c06dd0715bb9ae1b23142892bf287af203e",
    "src/resdag/layers/reservoirs/legendre_delay.py": "01bfcbe32694cd9a02bc73d0f3d1b259eb331f7e3d0b1d3d8cfa2fc83f11448e",
    "src/resdag/layers/reservoirs/lif.py": "6dc7b08c9eaa70cb53bed7a50a1607e891e4edcfe1b14ced2e5f020f98cf166f",
    "src/resdag/layers/reservoirs/ngrc.py": "a5ea928c7777ae40488bd8d055ee3e722e1b32597c0b3c26b1ee1be7318253ef",
    "src/resdag/layers/reservoirs/resesn.py": "faaa770527f685ec0d2a96b3dc1899e518f107af88c38369015075c1acda025b",
    "src/resdag/layers/reservoirs/torch_recurrent.py": "9996074fa8f218e3915c281d1a9fd709ebcae9f14c104d72ff6ded93248fa09d",
    "src/resdag/layers/transforms/__init__.py": "032cf9486e3c56d958c9c29184f5ee9424362889db6aa51a20ce0109297428d0",
    "src/resdag/layers/transforms/concatenate.py": "e998757a367f5dc6390f54f54ed4395429a306c6b956d9f7daccfda37492dec7",
    "src/resdag/layers/transforms/extended_square.py": "7fd5920d8ecaca96655abb150c999f3dc7e214916e903a84f41cc7797cc16059",
    "src/resdag/layers/transforms/feature_partitioner.py": "b1410e8df2da9e0a42c8ed6ab1545ea474a71b0abd46ce22bcca6c5d55fa3db7",
    "src/resdag/layers/transforms/nlat.py": "d37f8286dd5e1ce89ba4de10526238af76590acd5ef93d6af9111d5f2c4cd430",
    "src/resdag/layers/transforms/pad.py": "509e886189b16410c2b643f26023325cafe13d70dc10c8ad84640795ff2de576",
    "src/resdag/layers/transforms/partial_square.py": "120505f3f0c0a77249fe9c293a280a09de07ca53e1342532bfa8d3622043aaea",
    "src/resdag/layers/transforms/power.py": "0dcea9e03099ccbc07eef89c378b74d8449c10f4d82bb687a5d636a61366cb7e",
    "src/resdag/layers/transforms/selective_dropout.py": "4ea2e1eecd98fa204f2cbde9b941017799b2a98f8e8a1a47f85c2a498b5358a9",
    "src/resdag/layers/transforms/selective_exponentiation.py": "1664bbe1dc439f522a6d99f64b06ae4ec9186dbd9151d1f930accbce6e89a24e",
    "src/resdag/layers/transforms/standardize.py": "20dccc68de043fba93a79f4b9d0a96e8d03e0af50b9bd297eb098b530d2e3a4c",
    "src/resdag/metrics/__init__.py": "8a694f09c02f71c9205a8b6737d456a90701814572c2b8c11745580e15d6d815",
    "src/resdag/metrics/forecast.py": "3da46b9fe0599807610ac1abf9101b9bb27af8811e8906244ada0d47d330f318",
    "src/resdag/metrics/lyapunov.py": "5d2f2614c862ef9918916b0aa17c0b8147217f715abb1bea4a8ef4923f2233b9",
    "src/resdag/metrics/observables.py": "ae9fa70006690694ea08fe337586661ff3677c6389e65ba16e87b72ec76efacd",
    "src/resdag/models/__init__.py": "e32f31384288e3e856f3a1ba5cfc986a8854cc57e6b071f4930f626c7f8a0287",
    "src/resdag/models/_builder.py": "1d78274f9cbe06802542570a7ff90a6dbd876b3bfeaf9ed3d661f883fbd56f58",
    "src/resdag/models/_recipes.py": "f1ba39f82bd44db29e5a147f43749bd7e36f5823975a78e68e8d5b32d348cdc5",
    "src/resdag/models/classic_esn.py": "185a71710ca4806d366b782a9f02618cef0f777e641ac9917e0e439fa13c4adf",
    "src/resdag/models/coupled_ensemble_esn.py": "24554e834f33148863ad5eba1a500cdbc8487e95f739f0b4e503b41d27e9054c",
    "src/resdag/models/deep_esn.py": "57f4ceeb6b35c215b779d88d526e9c6c054a87303f4e6066a8b014e7f681e77b",
    "src/resdag/models/es2n.py": "14d491cdcf194cff73219e13dcdac020be513a32c05e401f7f79ac1233b93467",
    "src/resdag/models/eusn.py": "003eab7f5ae64ff736573d06164ac317d2adeee451670b4e7b33b15a869ee565",
    "src/resdag/models/gated_esn.py": "a5570d23440ba3c83513f55a7f5895eb6bff710d0591ccc0cc0498c2f21644a1",
    "src/resdag/models/headless_esn.py": "3ad9bfb33b311db6a87238d14774491a708cc0e47a4a7ad902c6bb35ce3d6a53",
    "src/resdag/models/hybrid_esn.py": "7ed1df57aa97cbcfb4b16e07e0f51b110f73bda41df1a589bb2e54f2b7bfc298",
    "src/resdag/models/linear_esn.py": "b835fa75fbe1262d77081d978ec434982318c4fa5d77f43aeac75fb3d1fd06e1",
    "src/resdag/models/lsm.py": "abaa3676edc6246833b26af7c4cb9eb7f681c8d01cba3038bc551a680da21ac1",
    "src/resdag/models/ott_esn.py": "bdfc19e8d7d76001e676c59068b9f9c882c22b2528183639812cc66da6329cef",
    "src/resdag/models/parallel_esn.py": "7ea0aa8215418350d742da9aa76c08dcd31774fd5c3a7b09b60847f02a989537",
    "src/resdag/models/power_augmented.py": "1f107700197133e32cb24952468fd36218bf693bb8ebf13f7cb5c3cbd76e0b49",
    "src/resdag/models/resesn.py": "24d24fcc48a85cc8b8c6d3774a3512cd3c1b30152885fc4b0bcb33162d0fda2b",
    "src/resdag/training/__init__.py": "ca3b8c06db95758ce233e5296167d7f69aedf861889019df9440addea71c32af",
    "src/resdag/training/calibration.py": "665bd6512ff0a3a7fb5e9e6aa2b9912c2c35402c9a66c5433f081c6487575d8d",
    "src/resdag/training/trainer.py": "c5dce421955a4ba8d0224741d889610a9f74c9b9506251d9fea77395b9b5c62f",
    "src/resdag/utils/__init__.py": "1d0737a4df8dcb238441c1fa7e2263402dc3d312a1c945d0e347df693053c1e7",
    "src/resdag/utils/data/__init__.py": "20fc94d40e01c7d592f1263c2ac4cd5892c7e20764a5dfc00d15ab530e9390a0",
    "src/resdag/utils/data/datasets.py": "8da92747435ea09b92f95ac8c27af7a699fd02fad232895eaa2874cddaad3a3c",
    "src/resdag/utils/data/io.py": "3f9b188416b8067e9a3dfce54bbfd938c0a3419f023329aba6516512c0641ead",
    "src/resdag/utils/data/prepare.py": "75fab72a5c2cc2a04811a9110abc6de3f1e4fc0f0b82a441de1629246166e5e4",
    "src/resdag/utils/general.py": "7aac12d70a3217b7426f8a7fe710d9184bd6e7cc11abf48eb9882cedbc0f4287",
    "src/resdag/utils/seeds.py": "d124e5c2cb37cc0775c2dce9217e75ffd0be36a0baef20ae58e7899781c29808",
    "src/resdag/utils/states/__init__.py": "ec355915994798b9a3cb160b6af30fcc65546896600ffb2ce078d83742be3daa",
    "src/resdag/utils/states/esp_index.py": "f1b9fa028206702a7007a1a49c6e305626e3f360f9982aabc910f41b39781ae6"
  },
  "change": "Only the admitted built-in parallel CPU forecast loop avoids full one-frame reservoir sequence dispatch and one-element stack. Warmup, arithmetic, recurrence, projection, readout and fallback behavior are unchanged.",
  "date": "2026-10-23",
  "environment": {
    "python": "3.14.8 (main, Oct  3 2026, 00:54:40) [Clang 22.1.3 ]",
    "versions": {
      "numpy": "2.4.6",
      "pytorch-symbolic": "1.2.1",
      "scipy": "1.17.0",
      "threadpoolctl": "3.6.0",
      "torch": "2.10.0"
    }
  },
  "exactness": {
    "b1-p64": {
      "hashes": {
        "fit_state": {
          "sha256": "44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a",
          "tensors": {}
        },
        "fitted": {
          "sha256": "4b53df2bf4206f9b1e8c94ca89c919aecc0aa9247b7e059aac64f54a35dd289b",
          "tensors": {
            "_fitted": {
              "dtype": "torch.bool",
              "sha256": "4bf5122f344554c53bde2ebb8cd2b7e3d1600ad631c385a5d7cce23c7785459a",
              "shape": []
            },
            "_history_0": {
              "dtype": "torch.float64",
              "sha256": "f77c74126f819e08df831bf29becdb9e3ff913ef6ff5c620fc976772401bb7aa",
              "shape": [
                1,
                101,
                256
              ]
            },
            "graph.readout._is_fitted": {
              "dtype": "torch.bool",
              "sha256": "4bf5122f344554c53bde2ebb8cd2b7e3d1600ad631c385a5d7cce23c7785459a",
              "shape": []
            },
            "graph.readout.bias": {
              "dtype": "torch.float64",
              "sha256": "89b43f70b8e62f32ca658d64f5ce0718516d38213206daf0b071d8392b6e82bc",
              "shape": [
                4
              ]
            },
            "graph.readout.weight": {
              "dtype": "torch.float64",
              "sha256": "9e07bf1fcec3e7d7d3f4b4371eff07cf2c155e461104ca73001d782d8037f813",
              "shape": [
                4,
                150
              ]
            },
            "graph.reservoir.cell.bias_h": {
              "dtype": "torch.float64",
              "sha256": "4f88680d3ddd79cc7b0377634e7218d23a4c9ef9d25ac5a7207960603b2b52b8",
              "shape": [
                150
              ]
            },
            "graph.reservoir.cell.weight_feedback": {
              "dtype": "torch.float64",
              "sha256": "f8ae67cb7a331fbc700b399d57f29b02d011c040e7be94d20714d6736873f336",
              "shape": [
                150,
                16
              ]
            },
            "graph.reservoir.cell.weight_hh": {
              "dtype": "torch.float64",
              "sha256": "4444c7286a7b220100c0738daaee34864f739067cbc24a1bac44151001bfc98a",
              "shape": [
                150,
                150
              ]
            },
            "input_scalers.0._method_code": {
              "dtype": "torch.int64",
              "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
              "shape": []
            },
            "input_scalers.0._stat0": {
              "dtype": "torch.float64",
              "sha256": "2adfbb2ed6b99e392691d1d4d2e465691e7b460b2248b4c333a64158b04105ce",
              "shape": [
                1,
                1,
                256
              ]
            },
            "input_scalers.0._stat1": {
              "dtype": "torch.float64",
              "sha256": "2bf255d25db89b9dc96f7a4ef65b1504b62760c78904ebc46881dd6eb1b8af55",
              "shape": [
                1,
                1,
                256
              ]
            },
            "output_scalers.0._method_code": {
              "dtype": "torch.int64",
              "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
              "shape": []
            },
            "output_scalers.0._stat0": {
              "dtype": "torch.float64",
              "sha256": "2adfbb2ed6b99e392691d1d4d2e465691e7b460b2248b4c333a64158b04105ce",
              "shape": [
                1,
                1,
                256
              ]
            },
            "output_scalers.0._stat1": {
              "dtype": "torch.float64",
              "sha256": "2bf255d25db89b9dc96f7a4ef65b1504b62760c78904ebc46881dd6eb1b8af55",
              "shape": [
                1,
                1,
                256
              ]
            }
          }
        },
        "forecast_state": {
          "sha256": "500e1fbab3fd3939fb5605f8e306b873bd9431f943f6a3e35d52ca4504dd2a57",
          "tensors": {
            "reservoir": {
              "dtype": "torch.float64",
              "sha256": "ae91e3a37aeed8e6513d9e85357480b8844cc60ed18b41ae9cc95e095e3ed74c",
              "shape": [
                64,
                150
              ]
            }
          }
        },
        "prediction": {
          "dtype": "torch.float64",
          "sha256": "772cdccadfcaf645cec03f22a6187e365d6d837b737b8a2ded5fe7b173bdf415",
          "shape": [
            1,
            129,
            256
          ]
        }
      },
      "sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1"
    },
    "b1-p8": {
      "hashes": {
        "fit_state": {
          "sha256": "44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a",
          "tensors": {}
        },
        "fitted": {
          "sha256": "2d848f87fabc1d4ed0dddf11be5f1d091b216c7dafd2a547f941187e08483874",
          "tensors": {
            "_fitted": {
              "dtype": "torch.bool",
              "sha256": "4bf5122f344554c53bde2ebb8cd2b7e3d1600ad631c385a5d7cce23c7785459a",
              "shape": []
            },
            "_history_0": {
              "dtype": "torch.float64",
              "sha256": "150278201c733a40b13a00c3c4c98fc4115b6416cbea085a4ee627c957d337e5",
              "shape": [
                1,
                101,
                32
              ]
            },
            "graph.readout._is_fitted": {
              "dtype": "torch.bool",
              "sha256": "4bf5122f344554c53bde2ebb8cd2b7e3d1600ad631c385a5d7cce23c7785459a",
              "shape": []
            },
            "graph.readout.bias": {
              "dtype": "torch.float64",
              "sha256": "764ab66c423a702ce2287506a0b10b9a9fc15347a4e5b54c350cd26dab549918",
              "shape": [
                4
              ]
            },
            "graph.readout.weight": {
              "dtype": "torch.float64",
              "sha256": "3c0739e94d1ee6c674d3982b4c024220700e878d80f88001a488c00691f4297a",
              "shape": [
                4,
                150
              ]
            },
            "graph.reservoir.cell.bias_h": {
              "dtype": "torch.float64",
              "sha256": "4f88680d3ddd79cc7b0377634e7218d23a4c9ef9d25ac5a7207960603b2b52b8",
              "shape": [
                150
              ]
            },
            "graph.reservoir.cell.weight_feedback": {
              "dtype": "torch.float64",
              "sha256": "f8ae67cb7a331fbc700b399d57f29b02d011c040e7be94d20714d6736873f336",
              "shape": [
                150,
                16
              ]
            },
            "graph.reservoir.cell.weight_hh": {
              "dtype": "torch.float64",
              "sha256": "4444c7286a7b220100c0738daaee34864f739067cbc24a1bac44151001bfc98a",
              "shape": [
                150,
                150
              ]
            },
            "input_scalers.0._method_code": {
              "dtype": "torch.int64",
              "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
              "shape": []
            },
            "input_scalers.0._stat0": {
              "dtype": "torch.float64",
              "sha256": "f75548f0f5f8a19fd327606e72a8cb361fa9ccd6a2457d492c7e9c1de37e0cb6",
              "shape": [
                1,
                1,
                32
              ]
            },
            "input_scalers.0._stat1": {
              "dtype": "torch.float64",
              "sha256": "3d2a4ed2d551517c36d57183b00c93e578d7ce1615e5609e7d3941c8a06948ac",
              "shape": [
                1,
                1,
                32
              ]
            },
            "output_scalers.0._method_code": {
              "dtype": "torch.int64",
              "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
              "shape": []
            },
            "output_scalers.0._stat0": {
              "dtype": "torch.float64",
              "sha256": "f75548f0f5f8a19fd327606e72a8cb361fa9ccd6a2457d492c7e9c1de37e0cb6",
              "shape": [
                1,
                1,
                32
              ]
            },
            "output_scalers.0._stat1": {
              "dtype": "torch.float64",
              "sha256": "3d2a4ed2d551517c36d57183b00c93e578d7ce1615e5609e7d3941c8a06948ac",
              "shape": [
                1,
                1,
                32
              ]
            }
          }
        },
        "forecast_state": {
          "sha256": "1d1b2882b19731a848c96da205239d6ffafc29667a6a148e91faed2cfaf0bb96",
          "tensors": {
            "reservoir": {
              "dtype": "torch.float64",
              "sha256": "e7ae0e5d289abeff5df29c1fbf90d5cab7c734d105f0898f6b48200cec79669d",
              "shape": [
                8,
                150
              ]
            }
          }
        },
        "prediction": {
          "dtype": "torch.float64",
          "sha256": "71b810e6c759bb22ac6e66f814d30a6346d1717edd8f4c94e70198052ee7b59c",
          "shape": [
            1,
            129,
            32
          ]
        }
      },
      "sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7"
    },
    "b4-p64": {
      "hashes": {
        "fit_state": {
          "sha256": "44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a",
          "tensors": {}
        },
        "fitted": {
          "sha256": "fc54e41c510956b049fbd3d3ed6daf4eecabdbf5be62af9ae4cc16b9d9583885",
          "tensors": {
            "_fitted": {
              "dtype": "torch.bool",
              "sha256": "4bf5122f344554c53bde2ebb8cd2b7e3d1600ad631c385a5d7cce23c7785459a",
              "shape": []
            },
            "_history_0": {
              "dtype": "torch.float64",
              "sha256": "8b0ba452b342bcc755956eb66e34dc717f751e50c649d93f57f556eab2db9203",
              "shape": [
                4,
                101,
                256
              ]
            },
            "graph.readout._is_fitted": {
              "dtype": "torch.bool",
              "sha256": "4bf5122f344554c53bde2ebb8cd2b7e3d1600ad631c385a5d7cce23c7785459a",
              "shape": []
            },
            "graph.readout.bias": {
              "dtype": "torch.float64",
              "sha256": "109cf40830a65b2e4a1a28abbfd0d8e1866f8e68ade5bfcff1ee9541ce6c10ff",
              "shape": [
                4
              ]
            },
            "graph.readout.weight": {
              "dtype": "torch.float64",
              "sha256": "ac18f04cc9a83d3c628e90aedbda43c980c7ed78da6d635eded22e017f59380a",
              "shape": [
                4,
                150
              ]
            },
            "graph.reservoir.cell.bias_h": {
              "dtype": "torch.float64",
              "sha256": "4f88680d3ddd79cc7b0377634e7218d23a4c9ef9d25ac5a7207960603b2b52b8",
              "shape": [
                150
              ]
            },
            "graph.reservoir.cell.weight_feedback": {
              "dtype": "torch.float64",
              "sha256": "f8ae67cb7a331fbc700b399d57f29b02d011c040e7be94d20714d6736873f336",
              "shape": [
                150,
                16
              ]
            },
            "graph.reservoir.cell.weight_hh": {
              "dtype": "torch.float64",
              "sha256": "4444c7286a7b220100c0738daaee34864f739067cbc24a1bac44151001bfc98a",
              "shape": [
                150,
                150
              ]
            },
            "input_scalers.0._method_code": {
              "dtype": "torch.int64",
              "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
              "shape": []
            },
            "input_scalers.0._stat0": {
              "dtype": "torch.float64",
              "sha256": "61d218d3631746535dcfb0644a076ef4eedb5622de0b50fe1c481d78ba846232",
              "shape": [
                1,
                1,
                256
              ]
            },
            "input_scalers.0._stat1": {
              "dtype": "torch.float64",
              "sha256": "c02488403d74166b88cb9e0681a008fe2424b49f1e1e142464f20037237a23ff",
              "shape": [
                1,
                1,
                256
              ]
            },
            "output_scalers.0._method_code": {
              "dtype": "torch.int64",
              "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
              "shape": []
            },
            "output_scalers.0._stat0": {
              "dtype": "torch.float64",
              "sha256": "61d218d3631746535dcfb0644a076ef4eedb5622de0b50fe1c481d78ba846232",
              "shape": [
                1,
                1,
                256
              ]
            },
            "output_scalers.0._stat1": {
              "dtype": "torch.float64",
              "sha256": "c02488403d74166b88cb9e0681a008fe2424b49f1e1e142464f20037237a23ff",
              "shape": [
                1,
                1,
                256
              ]
            }
          }
        },
        "forecast_state": {
          "sha256": "762b7bb1a68bd2381557b160b28efb5dbff03a5c673605d4b6caec787cf8dbaf",
          "tensors": {
            "reservoir": {
              "dtype": "torch.float64",
              "sha256": "6603fbb9150d88770606e099ff693608c0ce46c634f331320574b3e0dfaff535",
              "shape": [
                256,
                150
              ]
            }
          }
        },
        "prediction": {
          "dtype": "torch.float64",
          "sha256": "ef0bbd42b27b6a0953c9c453e848c691719ff65b6211733abfcbd55e22d6cc29",
          "shape": [
            4,
            129,
            256
          ]
        }
      },
      "sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db"
    },
    "b4-p8": {
      "hashes": {
        "fit_state": {
          "sha256": "44136fa355b3678a1146ad16f7e8649e94fb4fc21fe77e8310c060f61caaff8a",
          "tensors": {}
        },
        "fitted": {
          "sha256": "1e538e56d777c34a51d64bad60e05f74336d3549653f687a07ede6e91b98513c",
          "tensors": {
            "_fitted": {
              "dtype": "torch.bool",
              "sha256": "4bf5122f344554c53bde2ebb8cd2b7e3d1600ad631c385a5d7cce23c7785459a",
              "shape": []
            },
            "_history_0": {
              "dtype": "torch.float64",
              "sha256": "01bdb98fa0850031340b04ca6e06376b666d0c5d3ef2096288cdb90e713d3540",
              "shape": [
                4,
                101,
                32
              ]
            },
            "graph.readout._is_fitted": {
              "dtype": "torch.bool",
              "sha256": "4bf5122f344554c53bde2ebb8cd2b7e3d1600ad631c385a5d7cce23c7785459a",
              "shape": []
            },
            "graph.readout.bias": {
              "dtype": "torch.float64",
              "sha256": "8a081439734202e7872efd62792dc62fbcae8ea45e289b4d5bd2570cfc1d9088",
              "shape": [
                4
              ]
            },
            "graph.readout.weight": {
              "dtype": "torch.float64",
              "sha256": "5df8fe9d03b023926c8b7e1cb7c502a54b19e142c42ed146039ccc090353561f",
              "shape": [
                4,
                150
              ]
            },
            "graph.reservoir.cell.bias_h": {
              "dtype": "torch.float64",
              "sha256": "4f88680d3ddd79cc7b0377634e7218d23a4c9ef9d25ac5a7207960603b2b52b8",
              "shape": [
                150
              ]
            },
            "graph.reservoir.cell.weight_feedback": {
              "dtype": "torch.float64",
              "sha256": "f8ae67cb7a331fbc700b399d57f29b02d011c040e7be94d20714d6736873f336",
              "shape": [
                150,
                16
              ]
            },
            "graph.reservoir.cell.weight_hh": {
              "dtype": "torch.float64",
              "sha256": "4444c7286a7b220100c0738daaee34864f739067cbc24a1bac44151001bfc98a",
              "shape": [
                150,
                150
              ]
            },
            "input_scalers.0._method_code": {
              "dtype": "torch.int64",
              "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
              "shape": []
            },
            "input_scalers.0._stat0": {
              "dtype": "torch.float64",
              "sha256": "5bf03cd0250cf3f9b13d21667830bedd904b7be14353305d90330f09455c09c3",
              "shape": [
                1,
                1,
                32
              ]
            },
            "input_scalers.0._stat1": {
              "dtype": "torch.float64",
              "sha256": "74e36d59f992d4e7df54c71011454f6dc34c74be6f5e628fddc0a281f98522c1",
              "shape": [
                1,
                1,
                32
              ]
            },
            "output_scalers.0._method_code": {
              "dtype": "torch.int64",
              "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
              "shape": []
            },
            "output_scalers.0._stat0": {
              "dtype": "torch.float64",
              "sha256": "5bf03cd0250cf3f9b13d21667830bedd904b7be14353305d90330f09455c09c3",
              "shape": [
                1,
                1,
                32
              ]
            },
            "output_scalers.0._stat1": {
              "dtype": "torch.float64",
              "sha256": "74e36d59f992d4e7df54c71011454f6dc34c74be6f5e628fddc0a281f98522c1",
              "shape": [
                1,
                1,
                32
              ]
            }
          }
        },
        "forecast_state": {
          "sha256": "9f7d89654a61dd28c43dd19ad1a1d2cc5ae0a980cfd99cfe894d908cf5c76a4e",
          "tensors": {
            "reservoir": {
              "dtype": "torch.float64",
              "sha256": "f7e56d5592f0f7668057b0245d7d0d99a734d2a2249a0472580ff88c889f1525",
              "shape": [
                32,
                150
              ]
            }
          }
        },
        "prediction": {
          "dtype": "torch.float64",
          "sha256": "72c8eab30f79ca59c0c96b37574b1d8d1eb67f1a9aa17670c3e6045475cf9065",
          "shape": [
            4,
            129,
            32
          ]
        }
      },
      "sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2"
    }
  },
  "fixture_fingerprints": {
    "b1-p64": {
      "data": {
        "dtype": "torch.float64",
        "sha256": "55f53b16a89c3716cf170060c0457239a4b4b7516f8c5e68ab21c57a88560475",
        "shape": [
          1,
          501,
          256
        ]
      },
      "initial": {
        "sha256": "0badbf65c2d567b7a086b1eb10148f1cc525a0745540d94fa9409f87126b10f2",
        "tensors": {
          "_fitted": {
            "dtype": "torch.bool",
            "sha256": "6e340b9cffb37a989ca544e6bb780a2c78901d3fb33738768511a30617afa01d",
            "shape": []
          },
          "_history_0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              0,
              256
            ]
          },
          "graph.readout._is_fitted": {
            "dtype": "torch.bool",
            "sha256": "6e340b9cffb37a989ca544e6bb780a2c78901d3fb33738768511a30617afa01d",
            "shape": []
          },
          "graph.readout.bias": {
            "dtype": "torch.float64",
            "sha256": "7dd35801c873586281ce14ea17277d9949005119c9f3f6ee828e928c4f41f11e",
            "shape": [
              4
            ]
          },
          "graph.readout.weight": {
            "dtype": "torch.float64",
            "sha256": "32a43eb0bc9ff3363f68893c381ebab784320ade2c61c89fabaa6a19068d497b",
            "shape": [
              4,
              150
            ]
          },
          "graph.reservoir.cell.bias_h": {
            "dtype": "torch.float64",
            "sha256": "4f88680d3ddd79cc7b0377634e7218d23a4c9ef9d25ac5a7207960603b2b52b8",
            "shape": [
              150
            ]
          },
          "graph.reservoir.cell.weight_feedback": {
            "dtype": "torch.float64",
            "sha256": "f8ae67cb7a331fbc700b399d57f29b02d011c040e7be94d20714d6736873f336",
            "shape": [
              150,
              16
            ]
          },
          "graph.reservoir.cell.weight_hh": {
            "dtype": "torch.float64",
            "sha256": "4444c7286a7b220100c0738daaee34864f739067cbc24a1bac44151001bfc98a",
            "shape": [
              150,
              150
            ]
          },
          "input_scalers.0._method_code": {
            "dtype": "torch.int64",
            "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
            "shape": []
          },
          "input_scalers.0._stat0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "input_scalers.0._stat1": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "output_scalers.0._method_code": {
            "dtype": "torch.int64",
            "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
            "shape": []
          },
          "output_scalers.0._stat0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "output_scalers.0._stat1": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          }
        }
      }
    },
    "b1-p8": {
      "data": {
        "dtype": "torch.float64",
        "sha256": "7eced4688036366b1777271a9c2b87332c64d07733ee9c182742a79cdf2c6e0a",
        "shape": [
          1,
          501,
          32
        ]
      },
      "initial": {
        "sha256": "0a44e6b4897f5c218eb16b9492f64072b954f859655ef7c3ed412582c7c094b5",
        "tensors": {
          "_fitted": {
            "dtype": "torch.bool",
            "sha256": "6e340b9cffb37a989ca544e6bb780a2c78901d3fb33738768511a30617afa01d",
            "shape": []
          },
          "_history_0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              0,
              32
            ]
          },
          "graph.readout._is_fitted": {
            "dtype": "torch.bool",
            "sha256": "6e340b9cffb37a989ca544e6bb780a2c78901d3fb33738768511a30617afa01d",
            "shape": []
          },
          "graph.readout.bias": {
            "dtype": "torch.float64",
            "sha256": "17762b788b34c0b42e6dc388b133bc9b9c4c3dd52d78a6c7159b9ea0e4ab20ea",
            "shape": [
              4
            ]
          },
          "graph.readout.weight": {
            "dtype": "torch.float64",
            "sha256": "c7b7732048e9ef2c9bc67cf469ed074ce247b8964cfcd288124cfddee02a3810",
            "shape": [
              4,
              150
            ]
          },
          "graph.reservoir.cell.bias_h": {
            "dtype": "torch.float64",
            "sha256": "4f88680d3ddd79cc7b0377634e7218d23a4c9ef9d25ac5a7207960603b2b52b8",
            "shape": [
              150
            ]
          },
          "graph.reservoir.cell.weight_feedback": {
            "dtype": "torch.float64",
            "sha256": "f8ae67cb7a331fbc700b399d57f29b02d011c040e7be94d20714d6736873f336",
            "shape": [
              150,
              16
            ]
          },
          "graph.reservoir.cell.weight_hh": {
            "dtype": "torch.float64",
            "sha256": "4444c7286a7b220100c0738daaee34864f739067cbc24a1bac44151001bfc98a",
            "shape": [
              150,
              150
            ]
          },
          "input_scalers.0._method_code": {
            "dtype": "torch.int64",
            "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
            "shape": []
          },
          "input_scalers.0._stat0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "input_scalers.0._stat1": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "output_scalers.0._method_code": {
            "dtype": "torch.int64",
            "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
            "shape": []
          },
          "output_scalers.0._stat0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "output_scalers.0._stat1": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          }
        }
      }
    },
    "b4-p64": {
      "data": {
        "dtype": "torch.float64",
        "sha256": "1cd739058740d113b8e8784d556d4b4177ece00df73e462885d14ce2cf36a560",
        "shape": [
          4,
          501,
          256
        ]
      },
      "initial": {
        "sha256": "b24e2222cf0502c22451db2ee97ee37aaef06579c8dcd3879ccbdd20284da26c",
        "tensors": {
          "_fitted": {
            "dtype": "torch.bool",
            "sha256": "6e340b9cffb37a989ca544e6bb780a2c78901d3fb33738768511a30617afa01d",
            "shape": []
          },
          "_history_0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              0,
              256
            ]
          },
          "graph.readout._is_fitted": {
            "dtype": "torch.bool",
            "sha256": "6e340b9cffb37a989ca544e6bb780a2c78901d3fb33738768511a30617afa01d",
            "shape": []
          },
          "graph.readout.bias": {
            "dtype": "torch.float64",
            "sha256": "d0684edd3df144413f96260c9b14fcc4190990cccba416c5f42b7c4b66ece153",
            "shape": [
              4
            ]
          },
          "graph.readout.weight": {
            "dtype": "torch.float64",
            "sha256": "32b19a406b91a7ef06eb5301b582986162a586ada14047f519cb7bbe3d42ec7b",
            "shape": [
              4,
              150
            ]
          },
          "graph.reservoir.cell.bias_h": {
            "dtype": "torch.float64",
            "sha256": "4f88680d3ddd79cc7b0377634e7218d23a4c9ef9d25ac5a7207960603b2b52b8",
            "shape": [
              150
            ]
          },
          "graph.reservoir.cell.weight_feedback": {
            "dtype": "torch.float64",
            "sha256": "f8ae67cb7a331fbc700b399d57f29b02d011c040e7be94d20714d6736873f336",
            "shape": [
              150,
              16
            ]
          },
          "graph.reservoir.cell.weight_hh": {
            "dtype": "torch.float64",
            "sha256": "4444c7286a7b220100c0738daaee34864f739067cbc24a1bac44151001bfc98a",
            "shape": [
              150,
              150
            ]
          },
          "input_scalers.0._method_code": {
            "dtype": "torch.int64",
            "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
            "shape": []
          },
          "input_scalers.0._stat0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "input_scalers.0._stat1": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "output_scalers.0._method_code": {
            "dtype": "torch.int64",
            "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
            "shape": []
          },
          "output_scalers.0._stat0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "output_scalers.0._stat1": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          }
        }
      }
    },
    "b4-p8": {
      "data": {
        "dtype": "torch.float64",
        "sha256": "328be524ef5a26ce2c6a0f3e62ab64a3e1da6d1042b9dc348c46be0e26c618f1",
        "shape": [
          4,
          501,
          32
        ]
      },
      "initial": {
        "sha256": "5cb6912e83e0eb6ad25ad353726a1d16a2d04d9c5f2a0ecc3c36160e4566dab5",
        "tensors": {
          "_fitted": {
            "dtype": "torch.bool",
            "sha256": "6e340b9cffb37a989ca544e6bb780a2c78901d3fb33738768511a30617afa01d",
            "shape": []
          },
          "_history_0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              0,
              32
            ]
          },
          "graph.readout._is_fitted": {
            "dtype": "torch.bool",
            "sha256": "6e340b9cffb37a989ca544e6bb780a2c78901d3fb33738768511a30617afa01d",
            "shape": []
          },
          "graph.readout.bias": {
            "dtype": "torch.float64",
            "sha256": "ad366b205c04e0c13a17d1bb912b76bb4821ce220573ecc51314f2923d81c6e8",
            "shape": [
              4
            ]
          },
          "graph.readout.weight": {
            "dtype": "torch.float64",
            "sha256": "04202e7626a78c67e3ed866f6b83b7cbe83b8dccd720a27350358e94fabe84b4",
            "shape": [
              4,
              150
            ]
          },
          "graph.reservoir.cell.bias_h": {
            "dtype": "torch.float64",
            "sha256": "4f88680d3ddd79cc7b0377634e7218d23a4c9ef9d25ac5a7207960603b2b52b8",
            "shape": [
              150
            ]
          },
          "graph.reservoir.cell.weight_feedback": {
            "dtype": "torch.float64",
            "sha256": "f8ae67cb7a331fbc700b399d57f29b02d011c040e7be94d20714d6736873f336",
            "shape": [
              150,
              16
            ]
          },
          "graph.reservoir.cell.weight_hh": {
            "dtype": "torch.float64",
            "sha256": "4444c7286a7b220100c0738daaee34864f739067cbc24a1bac44151001bfc98a",
            "shape": [
              150,
              150
            ]
          },
          "input_scalers.0._method_code": {
            "dtype": "torch.int64",
            "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
            "shape": []
          },
          "input_scalers.0._stat0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "input_scalers.0._stat1": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "output_scalers.0._method_code": {
            "dtype": "torch.int64",
            "sha256": "7c9fa136d4413fa6173637e883b6998d32e1d675f88cddff9dcbcf331820f4b8",
            "shape": []
          },
          "output_scalers.0._stat0": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          },
          "output_scalers.0._stat1": {
            "dtype": "torch.float64",
            "sha256": "e3b0c44298fc1c149afbf4c8996fb92427ae41e4649b934ca495991b7852b855",
            "shape": [
              1,
              1,
              0
            ]
          }
        }
      }
    }
  },
  "fixture_recipe": {
    "default_dtype_during_prepare": "torch.float64",
    "model": {
      "core_width": 4,
      "dtype": "torch.float64",
      "factory": "rd.parallel_esn",
      "halo": 6,
      "other_options": "Frozen factory defaults; input_dim=case.features; eval mode",
      "readout_alpha": 0.001,
      "reservoir_size": 150,
      "seed": 2026102307,
      "spectral_radius": 0.6
    },
    "observations": "0.35*torch.randn(B,501,D,dtype=float64,generator=freshGenerator.manual_seed(2026102308+B+P)); saved once per case"
  },
  "interpretation": {
    "fit_control": "Fit executes identical code. Measured candidate/baseline elapsed-time ratios range0.9850\u20131.0763. Do not claim universal combined fit+forecast improvement.",
    "forecast": "Measured public history+forecast speedup factors range1.0225\u20131.0983x. Elapsed-time reductions range2.20\u20138.95%. TwoABBArounds are bounded descriptive evidence, not a confidence interval or universal speed guarantee.",
    "thread_boundary": "Verified observed native API limits on the synchronous calling main thread; not OS thread occupancy."
  },
  "kind": "parallel-cpu-forecast-evidence",
  "native_policies": {
    "8e69df7b0718f3876e1e03d7d7048a4e2d16b1cd33e2374fd34ed57ce0066cf2": {
      "accelerate": {
        "BLASGetThreading": 1,
        "library": "/System/Library/Frameworks/Accelerate.framework/Accelerate",
        "mode": "BLAS_THREADING_SINGLE_THREADED",
        "scope": "calling thread"
      },
      "build_configurations": {
        "numpy": {
          "Build Dependencies": {
            "blas": {
              "detection method": "system",
              "found": true,
              "include directory": "unknown",
              "lib directory": "unknown",
              "name": "accelerate",
              "openblas configuration": "unknown",
              "pc file directory": "unknown",
              "version": "unknown"
            },
            "lapack": {
              "detection method": "system",
              "found": true,
              "include directory": "unknown",
              "lib directory": "unknown",
              "name": "accelerate",
              "openblas configuration": "unknown",
              "pc file directory": "unknown",
              "version": "unknown"
            }
          },
          "Compilers": {
            "c": {
              "commands": "cc",
              "linker": "ld64",
              "name": "clang",
              "version": "15.0.0"
            },
            "c++": {
              "commands": "c++",
              "linker": "ld64",
              "name": "clang",
              "version": "15.0.0"
            },
            "cython": {
              "commands": "cython",
              "linker": "cython",
              "name": "cython",
              "version": "3.2.4"
            }
          },
          "Machine Information": {
            "build": {
              "cpu": "aarch64",
              "endian": "little",
              "family": "aarch64",
              "system": "darwin"
            },
            "host": {
              "cpu": "aarch64",
              "endian": "little",
              "family": "aarch64",
              "system": "darwin"
            }
          },
          "Python Information": {
            "path": "/private/var/folders/k4/_09nqs851t35bpkk8lr_p43c0000gn/T/build-env-legy_ptj/bin/python",
            "version": "3.14"
          },
          "SIMD Extensions": {
            "baseline": [
              "NEON",
              "NEON_FP16",
              "NEON_VFPV4",
              "ASIMD"
            ],
            "found": [
              "ASIMDHP",
              "ASIMDDP"
            ],
            "not found": [
              "ASIMDFHM"
            ]
          }
        },
        "scipy": {
          "Build Dependencies": {
            "blas": {
              "detection method": "extraframeworks",
              "found": true,
              "has ilp64": false,
              "include directory": "unknown",
              "lib directory": "unknown",
              "name": "Accelerate",
              "openblas configuration": "unknown",
              "pc file directory": "unknown",
              "version": "unknown"
            },
            "lapack": {
              "detection method": "extraframeworks",
              "found": true,
              "has ilp64": false,
              "include directory": "unknown",
              "lib directory": "unknown",
              "name": "Accelerate",
              "openblas configuration": "unknown",
              "pc file directory": "unknown",
              "version": "unknown"
            },
            "pybind11": {
              "detection method": "config-tool",
              "include directory": "unknown",
              "name": "pybind11",
              "version": "3.0.1"
            }
          },
          "Compilers": {
            "c": {
              "commands": "cc",
              "linker": "ld64",
              "name": "clang",
              "version": "15.0.0"
            },
            "c++": {
              "commands": "c++",
              "linker": "ld64",
              "name": "clang",
              "version": "15.0.0"
            },
            "cython": {
              "commands": "cython",
              "linker": "cython",
              "name": "cython",
              "version": "3.2.4"
            },
            "fortran": {
              "commands": "gfortran",
              "linker": "ld64",
              "name": "gcc",
              "version": "13.4.0"
            },
            "pythran": {
              "include directory": "../../../../../../private/var/folders/pr/_3h4tm913_l56k6hrhpm89z00000gn/T/build-env-j1vdxgxp/lib/python3.14/site-packages/pythran",
              "version": "0.18.1"
            }
          },
          "Machine Information": {
            "build": {
              "cpu": "aarch64",
              "endian": "little",
              "family": "aarch64",
              "system": "darwin"
            },
            "cross-compiled": false,
            "host": {
              "cpu": "aarch64",
              "endian": "little",
              "family": "aarch64",
              "system": "darwin"
            }
          },
          "Python Information": {
            "path": "/private/var/folders/pr/_3h4tm913_l56k6hrhpm89z00000gn/T/build-env-j1vdxgxp/bin/python",
            "version": "3.14"
          }
        }
      },
      "configuration_origins": {
        "numpy": "/Users/daniel/Projects/resdag/.venv/lib/python3.14/site-packages/numpy/__config__.py",
        "scipy": "/Users/daniel/Projects/resdag/.venv/lib/python3.14/site-packages/scipy/__config__.py",
        "torch": "/Users/daniel/Projects/resdag/.venv/lib/python3.14/site-packages/torch/__config__.py"
      },
      "dtype": "float64",
      "fresh_cli_bootstrap": true,
      "module_origins": {
        "numpy": "/Users/daniel/Projects/resdag/.venv/lib/python3.14/site-packages/numpy/__init__.py",
        "scipy": "/Users/daniel/Projects/resdag/.venv/lib/python3.14/site-packages/scipy/__init__.py",
        "threadpoolctl": "/Users/daniel/Projects/resdag/.venv/lib/python3.14/site-packages/threadpoolctl.py",
        "torch": "/Users/daniel/Projects/resdag/.venv/lib/python3.14/site-packages/torch/__init__.py"
      },
      "native_pools": [
        {
          "filepath": "/Users/daniel/Projects/resdag/.venv/lib/python3.14/site-packages/torch/lib/libomp.dylib",
          "internal_api": "openmp",
          "num_threads": 1,
          "prefix": "libomp",
          "user_api": "openmp",
          "version": null
        }
      ],
      "requested_environment": {
        "BLIS_NUM_THREADS": "1",
        "JULIA_NUM_THREADS": "1",
        "MKL_NUM_THREADS": "1",
        "OMP_NUM_THREADS": "1",
        "OPENBLAS_NUM_THREADS": "1",
        "VECLIB_MAXIMUM_THREADS": "1"
      },
      "torch_build_configuration": "PyTorch built with:\n  - GCC 4.2\n  - C++ Version: 201703\n  - clang 15.0.0\n  - OpenMP 201811\n  - LAPACK is enabled (usually provided by MKL)\n  - NNPACK is enabled\n  - CPU capability usage: DEFAULT\n  - Build settings: BLAS_INFO=accelerate, BUILD_TYPE=Release, COMMIT_SHA=449b1768410104d3ed79d3bcfe4ba1d65c7f22c0, CXX_COMPILER=/usr/bin/c++, CXX_FLAGS= -fvisibility-inlines-hidden -DUSE_PTHREADPOOL -DNDEBUG -DUSE_KINETO -DLIBKINETO_NOCUPTI -DLIBKINETO_NOROCTRACER -DLIBKINETO_NOXPUPTI=ON -DUSE_PYTORCH_QNNPACK -DAT_BUILD_ARM_VEC256_WITH_SLEEF -DUSE_XNNPACK -DUSE_PYTORCH_METAL_EXPORT -DSYMBOLICATE_MOBILE_DEBUG_HANDLE -DUSE_COREML_DELEGATE -O2 -fPIC -DC10_NODEPRECATED -Wall -Wextra -Werror=return-type -Werror=non-virtual-dtor -Werror=braced-scalar-init -Werror=range-loop-construct -Werror=bool-operation -Wnarrowing -Wno-missing-field-initializers -Wno-unknown-pragmas -Wno-unused-parameter -Wno-strict-overflow -Wno-strict-aliasing -Wvla-extension -Wsuggest-override -Wnewline-eof -Winconsistent-missing-override -Winconsistent-missing-destructor-override -Wno-pass-failed -Wno-error=old-style-cast -Wconstant-conversion -Qunused-arguments -faligned-new -fno-math-errno -fno-trapping-math -Werror=format -DUSE_MPS -Wno-missing-braces, LAPACK_INFO=accelerate, TORCH_VERSION=2.10.0, USE_CUDA=OFF, USE_CUDNN=OFF, USE_CUSPARSELT=OFF, USE_EIGEN_FOR_BLAS=ON, USE_GFLAGS=OFF, USE_GLOG=OFF, USE_GLOO=ON, USE_MKL=OFF, USE_MKLDNN=OFF, USE_MPI=OFF, USE_NCCL=OFF, USE_NNPACK=ON, USE_OPENMP=ON, USE_ROCM=OFF, USE_ROCM_KERNEL_ASSERT=OFF, USE_XCCL=OFF, USE_XPU=OFF, \n",
      "torch_interop_threads": 1,
      "torch_intraop_threads": 1,
      "torch_parallel_configuration": "ATen/Parallel:\n\tat::get_num_threads() : 1\n\tat::get_num_interop_threads() : 1\nOpenMP 201811\n\tomp_get_max_threads() : 1\nMKLDNN not found\nstd::thread::hardware_concurrency() : 10\nEnvironment variables:\n\tOMP_NUM_THREADS : 1\nATen parallel backend: OpenMP\n",
      "verification_boundary": "Observed native API settings on the synchronous calling thread; not an OS/kernel thread-occupancy measurement.",
      "workers": 1
    }
  },
  "not_adopted": [
    "index_select window rewrite",
    "core-target copy rewrite",
    "SciPy execution backend",
    "CPU teacher-forced compilation"
  ],
  "processes": [
    {
      "id": "r0-s0",
      "native_policy_id": "8e69df7b0718f3876e1e03d7d7048a4e2d16b1cd33e2374fd34ed57ce0066cf2",
      "original_receipt_sha256": "95633564a37b60a67ab459d699823cf48e1d5b5f14d8c7f8a8f0da4d8229785b",
      "round": 0,
      "slot": 0,
      "source_manifest_sha256": "d524ec88bcfd6a97f78b1aea7c95a28c46f3a5bf7be1a8f9d732489696799902",
      "variant": "baseline"
    },
    {
      "id": "r0-s1",
      "native_policy_id": "8e69df7b0718f3876e1e03d7d7048a4e2d16b1cd33e2374fd34ed57ce0066cf2",
      "original_receipt_sha256": "ed2e956e3cd58972e1a0d30c6443f577ceee896b0b1c155484e69f6466d0091d",
      "round": 0,
      "slot": 1,
      "source_manifest_sha256": "29d52ecc512388e04269d82967a7c4f2336e4c28a8ae05c98b767bf55ca5e2ee",
      "variant": "candidate"
    },
    {
      "id": "r0-s2",
      "native_policy_id": "8e69df7b0718f3876e1e03d7d7048a4e2d16b1cd33e2374fd34ed57ce0066cf2",
      "original_receipt_sha256": "99e25973a354827056155ce8ad3eaf174cfc1b7d344f1be2551cfe1815f9c427",
      "round": 0,
      "slot": 2,
      "source_manifest_sha256": "29d52ecc512388e04269d82967a7c4f2336e4c28a8ae05c98b767bf55ca5e2ee",
      "variant": "candidate"
    },
    {
      "id": "r0-s3",
      "native_policy_id": "8e69df7b0718f3876e1e03d7d7048a4e2d16b1cd33e2374fd34ed57ce0066cf2",
      "original_receipt_sha256": "b4438bba23a9b2ac0ea3bb6ebb54557b62c1de259bf2c6f1ff5111a4e09f4687",
      "round": 0,
      "slot": 3,
      "source_manifest_sha256": "d524ec88bcfd6a97f78b1aea7c95a28c46f3a5bf7be1a8f9d732489696799902",
      "variant": "baseline"
    },
    {
      "id": "r1-s0",
      "native_policy_id": "8e69df7b0718f3876e1e03d7d7048a4e2d16b1cd33e2374fd34ed57ce0066cf2",
      "original_receipt_sha256": "4c506a463e3739eb8e7e8fcd65a9e38985c818ea57da848c4e097decd85f8369",
      "round": 1,
      "slot": 0,
      "source_manifest_sha256": "d524ec88bcfd6a97f78b1aea7c95a28c46f3a5bf7be1a8f9d732489696799902",
      "variant": "baseline"
    },
    {
      "id": "r1-s1",
      "native_policy_id": "8e69df7b0718f3876e1e03d7d7048a4e2d16b1cd33e2374fd34ed57ce0066cf2",
      "original_receipt_sha256": "b958fd8458bcc6d5f048d03b724c57bdc5c5844e7632118b43a1990e538870ff",
      "round": 1,
      "slot": 1,
      "source_manifest_sha256": "29d52ecc512388e04269d82967a7c4f2336e4c28a8ae05c98b767bf55ca5e2ee",
      "variant": "candidate"
    },
    {
      "id": "r1-s2",
      "native_policy_id": "8e69df7b0718f3876e1e03d7d7048a4e2d16b1cd33e2374fd34ed57ce0066cf2",
      "original_receipt_sha256": "6ea397f4235e4412ad00906cdc96d076e755d4e62688669e7d01c6eb91e1c450",
      "round": 1,
      "slot": 2,
      "source_manifest_sha256": "29d52ecc512388e04269d82967a7c4f2336e4c28a8ae05c98b767bf55ca5e2ee",
      "variant": "candidate"
    },
    {
      "id": "r1-s3",
      "native_policy_id": "8e69df7b0718f3876e1e03d7d7048a4e2d16b1cd33e2374fd34ed57ce0066cf2",
      "original_receipt_sha256": "d49f89f4d262fb62e2d70bdc48578d4d593d207df31cafd67db73f80a3b7ca1e",
      "round": 1,
      "slot": 3,
      "source_manifest_sha256": "d524ec88bcfd6a97f78b1aea7c95a28c46f3a5bf7be1a8f9d732489696799902",
      "variant": "baseline"
    }
  ],
  "protocol": {
    "acceptance": "All fitted tensor, fit-state, full prediction and final-state hashes must match across all warmup/timed repeats and both variants; retain all raw samples.",
    "artifacts_sha256": "071cc2a360db915a1f748f1e107b7d443789a2aeb44275ef3210478c75f76e80",
    "cases": [
      {
        "batch": 1,
        "features": 32,
        "history": 100,
        "horizon": 129,
        "id": "b1-p8",
        "patches": 8,
        "steps": 501,
        "units": 150,
        "washout": 100
      },
      {
        "batch": 1,
        "features": 256,
        "history": 100,
        "horizon": 129,
        "id": "b1-p64",
        "patches": 64,
        "steps": 501,
        "units": 150,
        "washout": 100
      },
      {
        "batch": 4,
        "features": 32,
        "history": 100,
        "horizon": 129,
        "id": "b4-p8",
        "patches": 8,
        "steps": 501,
        "units": 150,
        "washout": 100
      },
      {
        "batch": 4,
        "features": 256,
        "history": 100,
        "horizon": 129,
        "id": "b4-p64",
        "patches": 64,
        "steps": 501,
        "units": 150,
        "washout": 100
      }
    ],
    "constructor_boundary": "Untimed shared saved model artifacts; this comparison measures the forecast-only production change and does not measure constructor normalization.",
    "driver_sha256": "1a4fd99511477569770a49a9609a4cba1640f8c6bb89e332e29ea0dbe93086d3",
    "frozen_probe_sha256": "ed5565a8de46d8d1c0240b3e260152a4ce0ffbb35df4fb6d360e02f8427cb140",
    "git_head": "34938890a5d650b6964b70ba2122dc462a4ad600",
    "git_status": " M docs/project/phase-five-results.md\n M docs/project/roadmap.md\n M src/resdag/core/workflow.py\n?? .herdr-synapse/\n",
    "process_order": [
      "baseline",
      "candidate",
      "candidate",
      "baseline"
    ],
    "public_boundary": "rd.Model.fit(observations), including transaction/scalers, and forecast(history,horizon=129,compile=False); external deepcopy/loading/fingerprints excluded.",
    "rounds": 2,
    "schema": 1,
    "scope": "Fixed synthetic four-case CPU matrix; no accuracy, cross-library or universal speed claim.",
    "source_differences": [
      "src/resdag/models/parallel_esn.py"
    ],
    "source_files": {
      "baseline": {
        "benchmarks/accuracy_regression.py": "4489397c669e9e273e0a4524844bc487223d03a412907f964721cff6a0e3d00a",
        "benchmarks/cpu_workflows.py": "0f3b40646db7f2e0ab3db9536a55f72b8031d2eccc2b462cf87b76228a5d1b0d",
        "benchmarks/rc_bench/__init__.py": "7da756e59fdcaa2b6efbd663ecd5eea2dd3299724fbd2f0b665b99a870ddd62c",
        "benchmarks/rc_bench/_threads.py": "5c6c8db3c8f47937af4ffdada12ec4b8d0d769097b4c4f0a8b8b5aa6819e2e30",
        "benchmarks/rc_bench/adapters/__init__.py": "b2cef27e2dc9398df0974ed409f854bd44de22a0d69596eefaf36c936d8633e2",
        "benchmarks/rc_bench/adapters/base.py": "e3c722badddd77005444b6b1c80dca48643e0f910d05f817baa1094747f7f964",
        "benchmarks/rc_bench/adapters/julia_adapter.py": "43cde719a0a9387fd97fed33aa5d3997dd374bda6a3854c9d264fb864fec85b3",
        "benchmarks/rc_bench/adapters/resdag_adapter.py": "9beb8f098759bf989354ecbf6fe07451b6fd0f13edbb6cbc97dd673971b399c1",
        "benchmarks/rc_bench/adapters/reservoirpy_adapter.py": "eebb3c8311e2d335fd930fed50b7ec26cbdc25c728b0c0be9b18e9f11bd95071",
        "benchmarks/rc_bench/budget.py": "ff1c415f8669e09eb86496960cae848a3c4491ad1ebdb656304e25f2934f44c9",
        "benchmarks/rc_bench/budget_adapters.py": "d5d37eec28e88376f0505d0cf15447a7cd381044aaa10219c1b2ee4ece8dc2e1",
        "benchmarks/rc_bench/config.py": "b1dafd96f4bd34805ccaac98b1910c09fac0aac2bb0c69b9c0639a90ded2ec0d",
        "benchmarks/rc_bench/data.py": "c692c733e1b070aabf049bbb0fb024705f3b30cfbf023343be5e7cbb89f3341a",
        "benchmarks/rc_bench/env.py": "a7f67b4d6d09616fc72ec36ee37aa2bd207f76125d2be9fa96d206d2807def56",
        "benchmarks/rc_bench/internal_cells.py": "b2055cbc51fd24c59dd4971b17f7536c515405b7ec899dc29050b479f25c74ec",
        "benchmarks/rc_bench/metrics.py": "80046a0934d83ac1b7e75dff22038fedc71f46b7246b541ceef39e4cc5b3f174",
        "benchmarks/rc_bench/report.py": "65dd443c41c4d48ddb88e6dd819994eac2c865ac26af37b8b314bec065031ea0",
        "benchmarks/rc_bench/run.py": "34105c4f4251722180b649c7b0d49ad4b3df767f81d173d4843ee48a75b9ddd4",
        "benchmarks/rc_bench/timing.py": "39498f8b6c64ab217813db551dfdca1f0f8cf1e24bf645e9d707c332de908008",
        "benchmarks/single_pass_training.py": "d39c665f72e78b6f3924e613e49d1c38c956378e15f0975cf747e5f14b48d349",
        "benchmarks/tuned_accuracy.py": "559c58878ef14a6ee620f57b8e86d85e6ea1bf618edabf2bd02919ba3f0ab91e",
        "src/resdag/__init__.py": "c42dac72173d616837fc4592c6f1621879394bfcadfb6d4d06c2d964a197177d",
        "src/resdag/_contracts.py": "88da074cc7adc865cba28ac6c07cbb0c674fd7d19776eb34f5ddcddfa98c7a10",
        "src/resdag/artifacts/__init__.py": "1f5cc28e3e414a7e66262bc405663ada64ccc4f7c13919757020fc6c8618b699",
        "src/resdag/artifacts/_api.py": "e23908e4c9a644578ca64542e0fe0c6904d04db64ad9d6f46fa55238849a9689",
        "src/resdag/artifacts/_codecs.py": "b52d6e87d37043a10a0b521d3300fa2b0e0f2dde83eb6c6025b9f9b195a046b5",
        "src/resdag/artifacts/_models.py": "6205af9db6b2734a3316cdd18e2a7ba554a200ef14e2a47ace0b3859b10bc001",
        "src/resdag/artifacts/_registry.py": "308c1ed43047f158d555acfc4e2a5e19eebdf2fa45f5a9eb9e78646d03d2d564",
        "src/resdag/core/__init__.py": "16d46d25e14ac133f4a3712037e487c0ac732ee1050926584e829b72ed7d1da5",
        "src/resdag/core/_diagram.py": "cd37ac3af23ac9113b4e8905ffcabab2aff01db528d80bccffc6a308919e2f1f",
        "src/resdag/core/_execution.py": "8f0bf7815bb3f28a83643498d4b8409d74f8e2c6fc5bff7d0eb300b378035483",
        "src/resdag/core/_feedback.py": "2f3f9f37200eea0bc91b423da79becfeebafd3b0f0c7e241e37854390927e069",
        "src/resdag/core/_flat_inference.py": "4dc5db94a4d3253b3262cb8550b6bd662bbb48ca8be21883884ecff5882dd1f1",
        "src/resdag/core/_forecast.py": "8c53e5cb9630b9a4f282995c55c9c3662cc79879fde924d40100242501572716",
        "src/resdag/core/_forecast_capabilities.py": "04516a200598ad78bcf30dad6b660c8195be40e7805f466d66a73760c6dded8b",
        "src/resdag/core/_forecast_stream.py": "daebbc8ba808d9819c7df585e72078b816443ed199af2cc445e85fd636c0ac98",
        "src/resdag/core/_hooks.py": "0dd3cb837ea4e209dd4d5b38761931e8ec40ec81bb57b35c1855984fdd90d58a",
        "src/resdag/core/_modes.py": "65860239bec09ab9d4a05fa568ce59148b6b6816a54035bab689052babeb1869",
        "src/resdag/core/_persistence.py": "b40b0bd744834065f2a49dfc6962a2ef0755bf3d42603bf6a767325828ae554d",
        "src/resdag/core/_preprocessing.py": "9df196372ae4aae55a7287d481c0a7d0ac3557b1a23694376ed8307554689780",
        "src/resdag/core/_workflow_backends.py": "11b7d458577d52c3dba86137db5e0d315031baa4d9e45edff81cb15a972b3662",
        "src/resdag/core/_workflow_transforms.py": "7ee5a2adaddc1e6f076c129c0bda6eb92fae48f9e82bfbe3758f55cb74270a37",
        "src/resdag/core/feature_extractor.py": "8bbb7c694aca535402f5e9cf03c0d066e418677eaac8eb829accd82ea6ae33ce",
        "src/resdag/core/model.py": "98e9fcbdb11e8f596c637e50e6d10af6198d7220600243d0c72e32932d1ec113",
        "src/resdag/core/workflow.py": "0abe2d4def3d4582f79b5d5d4f0f846f0e9ac6803a0cd834e338b8d379781ff5",
        "src/resdag/data/__init__.py": "07dd030ed3f94267802181d4870a26b3b02980ca6257120873747c900fe91c0e",
        "src/resdag/data/_trajectory.py": "0a74ff17d4a22f50ad355e38f43e1af6bb1bef54503060d4ab7d787231024fe4",
        "src/resdag/data/_trajectory_ports.py": "cdf72c65358bc16c8a5334c8be7d05b64a84f148fd5317dd546697e79492c9b4",
        "src/resdag/data/dataset.py": "72906ccf027725433de70a4a1cd9de6937a073227509d6465373593edea8667a",
        "src/resdag/data/io.py": "445eea54340bd46fd7d8d103b1f662a1cd65d2ae1984e604ac42ab4c8bf53573",
        "src/resdag/data/prepare.py": "9987cb73f009a0a4fb703082aa3812caf0b5971b8895b28eb38bbef7554f94a3",
        "src/resdag/datasets/__init__.py": "402a12335b950051a07920686453a954ecf89fdfc32a91673448b1350ee71bef",
        "src/resdag/ensemble/__init__.py": "9663bdc37ea7d35a2707e3877c9d534171d4d5856cf51832ce16ddbb0f22a5bd",
        "src/resdag/ensemble/aggregators/__init__.py": "4bb5444d0f53a5c07e26e903b14bcf2fd430f7eaaab758592c17ffed8ea388f9",
        "src/resdag/ensemble/aggregators/outliers_filtered_mean.py": "6768a76a989c85c5e289a62e040c2b7fea11111c35e38d01a88d8576307e876d",
        "src/resdag/ensemble/coupled.py": "91030d82e38ecba87c39e837a0d7b0f5526e70f373d7f6e56a30045e5d3f8446",
        "src/resdag/facade.py": "e9096a624dc021d61b59b7ae1351904ec121449da82bdb23daa6bc3826ff6a4f",
        "src/resdag/hpo/__init__.py": "443562e7bcc84e566872eb96e2058aaf9c0d6c92067666c71d2462fe6780dbd4",
        "src/resdag/hpo/_parallel.py": "de30a6a89a28793e862edc13f9fd9da1ba8d64da0fa4471562280497411b7dcc",
        "src/resdag/hpo/_provenance.py": "e582372ccf6e60735e4037a7888897b655570234006ff2ca2b4f42e0ae26a2c6",
        "src/resdag/hpo/_torch_losses.py": "49daaaf381d9a12e8f29089f3f24ec3f0d04403aa374eba9c952996fb861f7b8",
        "src/resdag/hpo/_trial_progress.py": "4a82ad385573ced752e133e34dfcfe6246d616e4ad5fe5ebacc2dbe49d7e51f3",
        "src/resdag/hpo/_tuning_data.py": "b7806297c49fee6e6c272520d0a2d2c615a67635af2cfef6a819533312c11c89",
        "src/resdag/hpo/_tuning_scores.py": "d95657d58e3b2fda468db36290e29f233154f947432aea67a4c8b9be94cca50a",
        "src/resdag/hpo/dispatch.py": "5ed2a5993545cbd05ed0153874be3dfd1a452dc7d35100d84d8271f6d9f3067f",
        "src/resdag/hpo/losses.py": "ce7fcc5818835af36d694470d5434e9c1aae06a51f7cf3ebafac81217f36c68c",
        "src/resdag/hpo/objective.py": "9029d3a0f6ff42356fa0db0b0bb18bc30bf0d05944a6945f4ed1bb5d406717e9",
        "src/resdag/hpo/pruners.py": "c69bec20658a03c9b640121d93ff743d842dc1e919118aef4ee660ec0715c8c2",
        "src/resdag/hpo/resources.py": "d8ceb668a06caa4340700b5bd2927deba6c8d2d000d079cefa55e7484bc70d51",
        "src/resdag/hpo/run.py": "1932bb4fe3f51c220f3e6af7746411eb08ad3d6a36ccc086fd567cd44ae7b812",
        "src/resdag/hpo/storage.py": "925a685184d4648bd2f8b0e7dd63b4f72682e183e2ac063448b1aa40b539fe6a",
        "src/resdag/hpo/transfer.py": "ead7c2efb06c2a9d70132c7b7d124ef2b1922084d7b0f8604e1ac5aee79f00b6",
        "src/resdag/hpo/trial_runner.py": "5cd5f0c53ac6d6868b476c073b019a9bad996d05f5883ab892ef1e5e51541782",
        "src/resdag/hpo/tuning.py": "bd6521926362efc4b9d4bbdf60e59f55cc2c2bbf5803a6ee7732ef1a390e6eac",
        "src/resdag/hpo/utils.py": "34e98a5584a9bbb496cf5954b1be625f635159db6ccd06fcec74a34e61eff5ec",
        "src/resdag/init/__init__.py": "693dea2d9076b80f240f01453fa1c1f7cdf19b76126e3c3e456009265a406fa4",
        "src/resdag/init/graphs/__init__.py": "72a620e96a6f611ebc8fc15bee581fa8cefbe453e5752ac586b8a4ed8c001f2a",
        "src/resdag/init/graphs/_dense.py": "63230c37085569f929155e4b58bf749036dbeec9333992ee56433933393217a4",
        "src/resdag/init/graphs/_sparse.py": "1f32032dc1a3a62aed94c63c9c00b051f12e92ae1ee339707fc3841efe75c073",
        "src/resdag/init/graphs/barabasi_albert.py": "16d1c4612e7a66666287829539d1518a4b52cc56c65b36e11bfa39e46a502825",
        "src/resdag/init/graphs/chord_dendrocycle.py": "767db6261bea6ade8d74e782577dfe7e6ee3261dae8291c49ef309fab6af298c",
        "src/resdag/init/graphs/complete.py": "57396b4b16c83c4a253834843ad18cbe32179fdc6b41e35e6d91f4a1213ea387",
        "src/resdag/init/graphs/connected_erdos_renyi.py": "11cac53111282a40e22e1a93f221e0d8aa5bf83ef6f41072163f59bd8f169fc1",
        "src/resdag/init/graphs/connected_watts_strogatz.py": "d5026a579ed242089facdba63a56f9ead2ad3bbcc5fbe6dae46b0a78a27ccaeb",
        "src/resdag/init/graphs/dendrocycle.py": "cd2d612a02fa79770bf82b819da1019d9d8bff842aa2fd7a848ee1bc3f2aae0f",
        "src/resdag/init/graphs/erdos_renyi.py": "f7d7cc1bafd9bad5dfcb0c5c8ed2f9c43b427b5a6f447eead3e550d8d98c1d88",
        "src/resdag/init/graphs/kleinberg_small_world.py": "c8282657ed3e0d5950c3b18510e9d639eb607818bc54dcddceecd5e3d39c27df",
        "src/resdag/init/graphs/multi_cycle.py": "d4e71f43d5f4850d05c14dc7a5ca53c6225ecf2c436b5b357ca26cf53d65e854",
        "src/resdag/init/graphs/newman_watts_strogatz.py": "22448a8775182eb632f7289618e7e8d62fa97c676e38039b8b5555a0804d165d",
        "src/resdag/init/graphs/random.py": "a5fd59473257a9e626408a04d3e5188611512c77e74652f14616258af9c6c904",
        "src/resdag/init/graphs/regular.py": "42b65129f4b9a491ca7afebee788ad21985f25b86fa57997cb36c0ec71e11b98",
        "src/resdag/init/graphs/ring_chord.py": "d2b241df32c18460ee5794514c42f683548f1a222b9cbee8212e474c5d6dc922",
        "src/resdag/init/graphs/simple_cycle_jumps.py": "d88e0c35a225dd84e78a179a630ae13e8d80b2154eb7635234302760577837cc",
        "src/resdag/init/graphs/spectral_cascade.py": "30ae1e8dda3593159b35f283d9cbe4372c5c72e85a10d83fbc7ffd1ea770516f",
        "src/resdag/init/graphs/watts_strogatz.py": "9e134327c097d0f2518594ecfdc85fee19b2888a5d4f386d1ff4a4da8cb7dddc",
        "src/resdag/init/graphs/zero.py": "f20b4c62c720afd3f05c2707b8a607d91eadf487bad988befa4f2895d9dd14ef",
        "src/resdag/init/input_feedback/__init__.py": "708ba4b80ac8983a1e944e85e65cc88e8f92d7b2a94ae1032a49770c11b2e82d",
        "src/resdag/init/input_feedback/_sign_sampling.py": "c27e79fc538a8b5f3305f8de5feda2de5f7dd68aa56fa7e4d7491a3fdf896a9d",
        "src/resdag/init/input_feedback/base.py": "a0093c432c69da7805378af14ca03bfb957cedfad5aa5485d52db6d9101b70f5",
        "src/resdag/init/input_feedback/bernoulli.py": "43d87f6cc8ef466e80854d9f480e29bad265cb22b15d69e3e65d0def992c75a2",
        "src/resdag/init/input_feedback/binary_balanced.py": "53675a1e9c70163ad97925e5c55dbc028f7682d248970f614b276be5f58781e8",
        "src/resdag/init/input_feedback/chain_of_neurons_input.py": "a725ff24c15c1825503a48eaeaf5261de7834e6c7e758ddbbb66c7a7111ed3e2",
        "src/resdag/init/input_feedback/chebyshev.py": "f168fd899c7e3c35d708c016128be7880cdf593b734f9e512eca98899fbf31d4",
        "src/resdag/init/input_feedback/chessboard.py": "8fb0626923cf42078ed17c61ca451e813f3a3f55bab914beaa99b89ffe8cf69f",
        "src/resdag/init/input_feedback/dendrocycle_input.py": "8a6288cc0d33d0a6855c93bfb08cc403ff97308dcade31eed782afd4f7a59614",
        "src/resdag/init/input_feedback/function.py": "8e72c5e3fd854d95bd610af04b23e2fe3a5c42b375e96b5d84f421c78d938c38",
        "src/resdag/init/input_feedback/informed.py": "be7f7db1c3eadbb2f538bcf8d3b2e919cd4274728380b50e4c2a71a274553813",
        "src/resdag/init/input_feedback/logistic_mapping.py": "d34741496fa9515b0f95073f6f0b90a5da767f2109ac3c7bc5170c2bb5f585d5",
        "src/resdag/init/input_feedback/minimal.py": "79655eedb8cb6daf86c6a4371cea76a2a5fb799d37ccfff8263ed117ca455460",
        "src/resdag/init/input_feedback/normal.py": "aca3c5a4cbe993722201072ab0299756c0d7c39e1b81c26345ada65a90d832e9",
        "src/resdag/init/input_feedback/opposite_anchors.py": "9a8c2a3894491758823263d666dfadd7a53433e495739de2334c01d3b1267471",
        "src/resdag/init/input_feedback/pseudo_diagonal.py": "aa64cc288836aa1cb35e7b4738508eb6ac13f0a8628a2ec9b9de682de40dc51f",
        "src/resdag/init/input_feedback/random.py": "b32018dcd7e11b1bfdf476ec3de9c5f8894faa3e83b111e399ccf683855fb100",
        "src/resdag/init/input_feedback/random_binary.py": "d0633ded78a4cb679ae57c74beb14316a86d2a83948e5a130df453878d0615cb",
        "src/resdag/init/input_feedback/registry.py": "aa407e5d92b296dfe518e83887e259a6e4c48308aba396d8c161ffb3b1caab31",
        "src/resdag/init/input_feedback/ring_window.py": "ffe21ab2f0de06e9b48d0712cc3d76636a55f612bc5735807c38229939caff37",
        "src/resdag/init/input_feedback/uniform.py": "376d7ce7941ad8e8c111cec4d6880c677a3cbff1ed6d8f89d13db9a8c6816dca",
        "src/resdag/init/input_feedback/weighted.py": "877cae56ea1b204a15bf0729166ba855abd5c6c7794f713ce56412867084acab",
        "src/resdag/init/input_feedback/zero.py": "dffbcd650a4752edf116d0568b3eb290018352c5b54cd3a9d1272d9b5c4434f5",
        "src/resdag/init/matrices/__init__.py": "a8a66d7f933145e0f6b2c4ffe89ffa55bddbecc9d43bab2e4e0de56be09770f4",
        "src/resdag/init/matrices/_common.py": "0fbd8956b1fc19dfd14ccd4ca1da34d5e916a6c3a32e8b5b9e9e6d9e926839f4",
        "src/resdag/init/matrices/antisymmetric.py": "96c5b9b3384df3a8e5185bcf8a9ec3b08feefb834d310451cccc672d01646189",
        "src/resdag/init/matrices/fsi.py": "bf6e30a856ae1b3b2f2f2f16cd7685f44707371e298b3c8ff30a70ac654e550d",
        "src/resdag/init/matrices/minimal.py": "79e9169055a4a529847528c14f3b6842f8ffcdde12cec24dbef3c55c5c75b56c",
        "src/resdag/init/matrices/orthogonal.py": "d44540819fa15e05bff1d3d143187b7233048b670f2f59b8297d542d9615b65d",
        "src/resdag/init/matrices/orthogonal_structures.py": "4e2fa149229cb6a6b391643379743b5fc4d742942fce87650e89e689d0245e91",
        "src/resdag/init/matrices/spectral.py": "b16dd21047efb5582707fc0d8fe25a174689cd763d27daec49a2cbcef029136a",
        "src/resdag/init/matrices/structured.py": "78f992c40ee2a00c46e2d85337c900a5c5e4524caec2355347f5b540b54f8ac1",
        "src/resdag/init/recurrent.py": "e381a8453de4304b761a46ea591ae1ddb3f5e3a3b1a730d2f799826c82a82d30",
        "src/resdag/init/topology/__init__.py": "d68bdd19da61d53fb43731f94122ddd5d896f935a66cd6a6f111df70f4a97857",
        "src/resdag/init/topology/_structured.py": "4a9f26fc9bade9645d5320f6e0ba27e5370c581a9cc2a7a80ebdc4aa5fb759f3",
        "src/resdag/init/topology/base.py": "b2a15a5bd6bc5ffea1af1fd6dea1ca508731a99ba150e174f73b31c69b942ca0",
        "src/resdag/init/topology/registry.py": "65695d210e266f659a51f893551a51b0067adcaa9182253f2a7355aa6a198e43",
        "src/resdag/init/utils/__init__.py": "05f52bd7820e0a15713c238fbe48b0b06c9460060dfe1859150296bee67b5c80",
        "src/resdag/init/utils/graph_tools.py": "b87c219785992c6f7b71b3233c5ad0a4243a64efae23dc22575a2704ac87467c",
        "src/resdag/init/utils/resolve.py": "671a3cae60d4a1af6126fe404b7103dffce68cfeae09c11c779cb7939aa09db8",
        "src/resdag/layers/__init__.py": "524ee601becb13cc7b465942f8788c7b5bbb4149470d1c3e016aafd21db5b82f",
        "src/resdag/layers/cells/__init__.py": "d56811b2c03792d7062b561a09f676802fe0435da89e796b5316db9bf5f7a1c5",
        "src/resdag/layers/cells/_compact_recurrent.py": "2b4c79395dfbda78daeec5482dd4996671c89fea560a4c8b78c1f3bb3feee6a3",
        "src/resdag/layers/cells/_initialization.py": "e45ad0187b2719f788934376fe9103cbd0e8832ee0afdfed36e612905ff89f2b",
        "src/resdag/layers/cells/_projected.py": "0b63466840fa57e5f1157fe5d9e6a40d11930749338d3a4778026d19e6989c13",
        "src/resdag/layers/cells/_skip_cell.py": "f142d16bf56ed12c67145fa767da9f45131d8ed2c0296553a52af7d3532c826d",
        "src/resdag/layers/cells/_structured_recurrent.py": "b0f493ef7da9b9bb579afbe586c169472d28162ff66da155162a6e2d6548a167",
        "src/resdag/layers/cells/base_cell.py": "02abd9249c173abe926b8d0895e5ddaa93f5ef50ad10d57b2b1c046422c3b613",
        "src/resdag/layers/cells/continuous_cell.py": "2ac6131537f0d436554d81e7bf0242a35267c8e3658f266053a51047b3e8be82",
        "src/resdag/layers/cells/cornn_cell.py": "c415eff19222258e4bbd8b3e8a226101da41af699b8a531fcf763aca4867539f",
        "src/resdag/layers/cells/es2n_cell.py": "c3045f48c70995321685cf50e920d7c5f1e6b4a4d63e556a056994106eb1b83d",
        "src/resdag/layers/cells/esn_cell.py": "8780f70ad5789571db30d543cdbd5f9862e556da2d260fd6463384b428c9da8a",
        "src/resdag/layers/cells/eusn_cell.py": "3227feae8d5de136e937142d80501d92a318a01bc0f0a5ba35d5f74b245a943e",
        "src/resdag/layers/cells/gated_cell.py": "b87f1ce0c7ee9dc67c3693750c41e67e2bd53b3acf704b54005faf72c31eb3ba",
        "src/resdag/layers/cells/legendre_delay_cell.py": "cc57f69602ed51ebd9ea20355fe143114629802fa2d44748e17d8174ab6756f4",
        "src/resdag/layers/cells/lif_cell.py": "1da640bea3654eb6c1cfde1d430abea8e7a1ffbe39cd3ab2a99b32a2441a2121",
        "src/resdag/layers/cells/ngrc_cell.py": "f51fb1706956c7df9b3974e7b107e67b3c628d3c751bb24310558d22b67bea0d",
        "src/resdag/layers/cells/resesn_cell.py": "2f004b33b36776c42cfef3cc7e86390f3f0aac96f2933b94e88a169e9d83b7e8",
        "src/resdag/layers/cells/spiking_cell.py": "ce83293d4d0e5b05ef25dd3431e81ad5347935cd1614f3822276a2aeb56d5540",
        "src/resdag/layers/cells/torch_recurrent_cell.py": "fb82d5f8d7c2309b6230fccd3462bb9cde487730718cb30639e5ce6f50589e24",
        "src/resdag/layers/readouts/__init__.py": "45d072a28ccb4c699822c859105ed562bc70c95ff07c12987c98cd20495bf3f3",
        "src/resdag/layers/readouts/_solve_utils.py": "df157a90dccc3e147981c184a543311f0786d338d99f24f0149954eccad6d3c5",
        "src/resdag/layers/readouts/auto_readout.py": "4fcf8e63085a00d2ec407452c9561e2b4eece9b6a622f84293a66928e5b31d0c",
        "src/resdag/layers/readouts/base.py": "55c0e7c9b8c955412f4c2281312b2c86e72d2203b5676b1e8adb33418075c65f",
        "src/resdag/layers/readouts/cg_readout.py": "b23c00c83a334d3bff69206280ab2754796155e795ffe16f8704ddec94b312a2",
        "src/resdag/layers/readouts/cholesky_readout.py": "c240a45504eccaf6a4168c60a0a89c11808b539db485e097b7a870924ac77127",
        "src/resdag/layers/readouts/fista_readout.py": "e4f0a326f986ce412ef66302fce457e4f38b2f03495ed8991130a1d104c09d4c",
        "src/resdag/layers/readouts/incremental_ridge.py": "8385c0c68ab2b3425288c218af8819f8ed9b90c72a9f237ea91952a917fc5cb7",
        "src/resdag/layers/readouts/lsmr_readout.py": "49e54144fe2add7ba982c1c4a376316d60d87e6736f20b33be2e7245bda5e325",
        "src/resdag/layers/readouts/pinv_readout.py": "6f875bbf8618beea062caddd6f6c98459cb0403b07de7619c5f6dfedde05314b",
        "src/resdag/layers/readouts/ridge_readout.py": "29ac7b0fd61582bd018db8e566a1a75b485407c70a0e17c5f09120164d1db920",
        "src/resdag/layers/readouts/rls_readout.py": "f61aebeb940bef8c4f1e5e739b2f1dd85c091948973a8753842c9918ef9b3ca4",
        "src/resdag/layers/readouts/svd_readout.py": "e4a79b9195d263a81e7fa23aaf31c54ada38fcf6f4c7189a65ef88443fc66891",
        "src/resdag/layers/reservoirs/__init__.py": "9d4dcb7c184a1c77ba5246b6c87895cf0e9ca29cdbdd2656e176c6f3a7b312f0",
        "src/resdag/layers/reservoirs/_cell_layer.py": "749dd38f93949c5378eb978361da56cc8e95fae506316aeb85e68644878919b1",
        "src/resdag/layers/reservoirs/base_reservoir.py": "ff87bb4aa80752bbcab84c00c9815f119a15d5d91fc2d0a81714d9a95c17e3f1",
        "src/resdag/layers/reservoirs/cornn.py": "2e8e351c5109002f6a34b00e75c7ed521fa6d07d797b22fb2cde11014adab806",
        "src/resdag/layers/reservoirs/es2n.py": "db72ebcbe9a38b92453e7b5dbef5ae836c1ef87d2cda561b7bf57132c2103160",
        "src/resdag/layers/reservoirs/esn.py": "d5a7493619adc35e1a4a7d0a0f425875fd6fbd8db7815d37555b861576748010",
        "src/resdag/layers/reservoirs/eusn.py": "ce6c5fa1eddb3ddf13047d0ef7a7e4b17810bb282742cb3e41a79426e60da7f7",
        "src/resdag/layers/reservoirs/gated.py": "2debd889c4c1e236383a7fe464617c06dd0715bb9ae1b23142892bf287af203e",
        "src/resdag/layers/reservoirs/legendre_delay.py": "01bfcbe32694cd9a02bc73d0f3d1b259eb331f7e3d0b1d3d8cfa2fc83f11448e",
        "src/resdag/layers/reservoirs/lif.py": "6dc7b08c9eaa70cb53bed7a50a1607e891e4edcfe1b14ced2e5f020f98cf166f",
        "src/resdag/layers/reservoirs/ngrc.py": "a5ea928c7777ae40488bd8d055ee3e722e1b32597c0b3c26b1ee1be7318253ef",
        "src/resdag/layers/reservoirs/resesn.py": "faaa770527f685ec0d2a96b3dc1899e518f107af88c38369015075c1acda025b",
        "src/resdag/layers/reservoirs/torch_recurrent.py": "9996074fa8f218e3915c281d1a9fd709ebcae9f14c104d72ff6ded93248fa09d",
        "src/resdag/layers/transforms/__init__.py": "032cf9486e3c56d958c9c29184f5ee9424362889db6aa51a20ce0109297428d0",
        "src/resdag/layers/transforms/concatenate.py": "e998757a367f5dc6390f54f54ed4395429a306c6b956d9f7daccfda37492dec7",
        "src/resdag/layers/transforms/extended_square.py": "7fd5920d8ecaca96655abb150c999f3dc7e214916e903a84f41cc7797cc16059",
        "src/resdag/layers/transforms/feature_partitioner.py": "b1410e8df2da9e0a42c8ed6ab1545ea474a71b0abd46ce22bcca6c5d55fa3db7",
        "src/resdag/layers/transforms/nlat.py": "d37f8286dd5e1ce89ba4de10526238af76590acd5ef93d6af9111d5f2c4cd430",
        "src/resdag/layers/transforms/pad.py": "509e886189b16410c2b643f26023325cafe13d70dc10c8ad84640795ff2de576",
        "src/resdag/layers/transforms/partial_square.py": "120505f3f0c0a77249fe9c293a280a09de07ca53e1342532bfa8d3622043aaea",
        "src/resdag/layers/transforms/power.py": "0dcea9e03099ccbc07eef89c378b74d8449c10f4d82bb687a5d636a61366cb7e",
        "src/resdag/layers/transforms/selective_dropout.py": "4ea2e1eecd98fa204f2cbde9b941017799b2a98f8e8a1a47f85c2a498b5358a9",
        "src/resdag/layers/transforms/selective_exponentiation.py": "1664bbe1dc439f522a6d99f64b06ae4ec9186dbd9151d1f930accbce6e89a24e",
        "src/resdag/layers/transforms/standardize.py": "20dccc68de043fba93a79f4b9d0a96e8d03e0af50b9bd297eb098b530d2e3a4c",
        "src/resdag/metrics/__init__.py": "8a694f09c02f71c9205a8b6737d456a90701814572c2b8c11745580e15d6d815",
        "src/resdag/metrics/forecast.py": "3da46b9fe0599807610ac1abf9101b9bb27af8811e8906244ada0d47d330f318",
        "src/resdag/metrics/lyapunov.py": "5d2f2614c862ef9918916b0aa17c0b8147217f715abb1bea4a8ef4923f2233b9",
        "src/resdag/metrics/observables.py": "ae9fa70006690694ea08fe337586661ff3677c6389e65ba16e87b72ec76efacd",
        "src/resdag/models/__init__.py": "e32f31384288e3e856f3a1ba5cfc986a8854cc57e6b071f4930f626c7f8a0287",
        "src/resdag/models/_builder.py": "1d78274f9cbe06802542570a7ff90a6dbd876b3bfeaf9ed3d661f883fbd56f58",
        "src/resdag/models/_recipes.py": "f1ba39f82bd44db29e5a147f43749bd7e36f5823975a78e68e8d5b32d348cdc5",
        "src/resdag/models/classic_esn.py": "185a71710ca4806d366b782a9f02618cef0f777e641ac9917e0e439fa13c4adf",
        "src/resdag/models/coupled_ensemble_esn.py": "24554e834f33148863ad5eba1a500cdbc8487e95f739f0b4e503b41d27e9054c",
        "src/resdag/models/deep_esn.py": "57f4ceeb6b35c215b779d88d526e9c6c054a87303f4e6066a8b014e7f681e77b",
        "src/resdag/models/es2n.py": "14d491cdcf194cff73219e13dcdac020be513a32c05e401f7f79ac1233b93467",
        "src/resdag/models/eusn.py": "003eab7f5ae64ff736573d06164ac317d2adeee451670b4e7b33b15a869ee565",
        "src/resdag/models/gated_esn.py": "a5570d23440ba3c83513f55a7f5895eb6bff710d0591ccc0cc0498c2f21644a1",
        "src/resdag/models/headless_esn.py": "3ad9bfb33b311db6a87238d14774491a708cc0e47a4a7ad902c6bb35ce3d6a53",
        "src/resdag/models/hybrid_esn.py": "7ed1df57aa97cbcfb4b16e07e0f51b110f73bda41df1a589bb2e54f2b7bfc298",
        "src/resdag/models/linear_esn.py": "b835fa75fbe1262d77081d978ec434982318c4fa5d77f43aeac75fb3d1fd06e1",
        "src/resdag/models/lsm.py": "abaa3676edc6246833b26af7c4cb9eb7f681c8d01cba3038bc551a680da21ac1",
        "src/resdag/models/ott_esn.py": "bdfc19e8d7d76001e676c59068b9f9c882c22b2528183639812cc66da6329cef",
        "src/resdag/models/parallel_esn.py": "6d7f22e288499fd6367fbb555eeb910b3d04c06e91e4d9e8e7297c1d93db59a6",
        "src/resdag/models/power_augmented.py": "1f107700197133e32cb24952468fd36218bf693bb8ebf13f7cb5c3cbd76e0b49",
        "src/resdag/models/resesn.py": "24d24fcc48a85cc8b8c6d3774a3512cd3c1b30152885fc4b0bcb33162d0fda2b",
        "src/resdag/training/__init__.py": "ca3b8c06db95758ce233e5296167d7f69aedf861889019df9440addea71c32af",
        "src/resdag/training/calibration.py": "665bd6512ff0a3a7fb5e9e6aa2b9912c2c35402c9a66c5433f081c6487575d8d",
        "src/resdag/training/trainer.py": "c5dce421955a4ba8d0224741d889610a9f74c9b9506251d9fea77395b9b5c62f",
        "src/resdag/utils/__init__.py": "1d0737a4df8dcb238441c1fa7e2263402dc3d312a1c945d0e347df693053c1e7",
        "src/resdag/utils/data/__init__.py": "20fc94d40e01c7d592f1263c2ac4cd5892c7e20764a5dfc00d15ab530e9390a0",
        "src/resdag/utils/data/datasets.py": "8da92747435ea09b92f95ac8c27af7a699fd02fad232895eaa2874cddaad3a3c",
        "src/resdag/utils/data/io.py": "3f9b188416b8067e9a3dfce54bbfd938c0a3419f023329aba6516512c0641ead",
        "src/resdag/utils/data/prepare.py": "75fab72a5c2cc2a04811a9110abc6de3f1e4fc0f0b82a441de1629246166e5e4",
        "src/resdag/utils/general.py": "7aac12d70a3217b7426f8a7fe710d9184bd6e7cc11abf48eb9882cedbc0f4287",
        "src/resdag/utils/seeds.py": "d124e5c2cb37cc0775c2dce9217e75ffd0be36a0baef20ae58e7899781c29808",
        "src/resdag/utils/states/__init__.py": "ec355915994798b9a3cb160b6af30fcc65546896600ffb2ce078d83742be3daa",
        "src/resdag/utils/states/esp_index.py": "f1b9fa028206702a7007a1a49c6e305626e3f360f9982aabc910f41b39781ae6"
      },
      "candidate": {
        "benchmarks/accuracy_regression.py": "4489397c669e9e273e0a4524844bc487223d03a412907f964721cff6a0e3d00a",
        "benchmarks/cpu_workflows.py": "0f3b40646db7f2e0ab3db9536a55f72b8031d2eccc2b462cf87b76228a5d1b0d",
        "benchmarks/rc_bench/__init__.py": "7da756e59fdcaa2b6efbd663ecd5eea2dd3299724fbd2f0b665b99a870ddd62c",
        "benchmarks/rc_bench/_threads.py": "5c6c8db3c8f47937af4ffdada12ec4b8d0d769097b4c4f0a8b8b5aa6819e2e30",
        "benchmarks/rc_bench/adapters/__init__.py": "b2cef27e2dc9398df0974ed409f854bd44de22a0d69596eefaf36c936d8633e2",
        "benchmarks/rc_bench/adapters/base.py": "e3c722badddd77005444b6b1c80dca48643e0f910d05f817baa1094747f7f964",
        "benchmarks/rc_bench/adapters/julia_adapter.py": "43cde719a0a9387fd97fed33aa5d3997dd374bda6a3854c9d264fb864fec85b3",
        "benchmarks/rc_bench/adapters/resdag_adapter.py": "9beb8f098759bf989354ecbf6fe07451b6fd0f13edbb6cbc97dd673971b399c1",
        "benchmarks/rc_bench/adapters/reservoirpy_adapter.py": "eebb3c8311e2d335fd930fed50b7ec26cbdc25c728b0c0be9b18e9f11bd95071",
        "benchmarks/rc_bench/budget.py": "ff1c415f8669e09eb86496960cae848a3c4491ad1ebdb656304e25f2934f44c9",
        "benchmarks/rc_bench/budget_adapters.py": "d5d37eec28e88376f0505d0cf15447a7cd381044aaa10219c1b2ee4ece8dc2e1",
        "benchmarks/rc_bench/config.py": "b1dafd96f4bd34805ccaac98b1910c09fac0aac2bb0c69b9c0639a90ded2ec0d",
        "benchmarks/rc_bench/data.py": "c692c733e1b070aabf049bbb0fb024705f3b30cfbf023343be5e7cbb89f3341a",
        "benchmarks/rc_bench/env.py": "a7f67b4d6d09616fc72ec36ee37aa2bd207f76125d2be9fa96d206d2807def56",
        "benchmarks/rc_bench/internal_cells.py": "b2055cbc51fd24c59dd4971b17f7536c515405b7ec899dc29050b479f25c74ec",
        "benchmarks/rc_bench/metrics.py": "80046a0934d83ac1b7e75dff22038fedc71f46b7246b541ceef39e4cc5b3f174",
        "benchmarks/rc_bench/report.py": "65dd443c41c4d48ddb88e6dd819994eac2c865ac26af37b8b314bec065031ea0",
        "benchmarks/rc_bench/run.py": "34105c4f4251722180b649c7b0d49ad4b3df767f81d173d4843ee48a75b9ddd4",
        "benchmarks/rc_bench/timing.py": "39498f8b6c64ab217813db551dfdca1f0f8cf1e24bf645e9d707c332de908008",
        "benchmarks/single_pass_training.py": "d39c665f72e78b6f3924e613e49d1c38c956378e15f0975cf747e5f14b48d349",
        "benchmarks/tuned_accuracy.py": "559c58878ef14a6ee620f57b8e86d85e6ea1bf618edabf2bd02919ba3f0ab91e",
        "src/resdag/__init__.py": "c42dac72173d616837fc4592c6f1621879394bfcadfb6d4d06c2d964a197177d",
        "src/resdag/_contracts.py": "88da074cc7adc865cba28ac6c07cbb0c674fd7d19776eb34f5ddcddfa98c7a10",
        "src/resdag/artifacts/__init__.py": "1f5cc28e3e414a7e66262bc405663ada64ccc4f7c13919757020fc6c8618b699",
        "src/resdag/artifacts/_api.py": "e23908e4c9a644578ca64542e0fe0c6904d04db64ad9d6f46fa55238849a9689",
        "src/resdag/artifacts/_codecs.py": "b52d6e87d37043a10a0b521d3300fa2b0e0f2dde83eb6c6025b9f9b195a046b5",
        "src/resdag/artifacts/_models.py": "6205af9db6b2734a3316cdd18e2a7ba554a200ef14e2a47ace0b3859b10bc001",
        "src/resdag/artifacts/_registry.py": "308c1ed43047f158d555acfc4e2a5e19eebdf2fa45f5a9eb9e78646d03d2d564",
        "src/resdag/core/__init__.py": "16d46d25e14ac133f4a3712037e487c0ac732ee1050926584e829b72ed7d1da5",
        "src/resdag/core/_diagram.py": "cd37ac3af23ac9113b4e8905ffcabab2aff01db528d80bccffc6a308919e2f1f",
        "src/resdag/core/_execution.py": "8f0bf7815bb3f28a83643498d4b8409d74f8e2c6fc5bff7d0eb300b378035483",
        "src/resdag/core/_feedback.py": "2f3f9f37200eea0bc91b423da79becfeebafd3b0f0c7e241e37854390927e069",
        "src/resdag/core/_flat_inference.py": "4dc5db94a4d3253b3262cb8550b6bd662bbb48ca8be21883884ecff5882dd1f1",
        "src/resdag/core/_forecast.py": "8c53e5cb9630b9a4f282995c55c9c3662cc79879fde924d40100242501572716",
        "src/resdag/core/_forecast_capabilities.py": "04516a200598ad78bcf30dad6b660c8195be40e7805f466d66a73760c6dded8b",
        "src/resdag/core/_forecast_stream.py": "daebbc8ba808d9819c7df585e72078b816443ed199af2cc445e85fd636c0ac98",
        "src/resdag/core/_hooks.py": "0dd3cb837ea4e209dd4d5b38761931e8ec40ec81bb57b35c1855984fdd90d58a",
        "src/resdag/core/_modes.py": "65860239bec09ab9d4a05fa568ce59148b6b6816a54035bab689052babeb1869",
        "src/resdag/core/_persistence.py": "b40b0bd744834065f2a49dfc6962a2ef0755bf3d42603bf6a767325828ae554d",
        "src/resdag/core/_preprocessing.py": "9df196372ae4aae55a7287d481c0a7d0ac3557b1a23694376ed8307554689780",
        "src/resdag/core/_workflow_backends.py": "11b7d458577d52c3dba86137db5e0d315031baa4d9e45edff81cb15a972b3662",
        "src/resdag/core/_workflow_transforms.py": "7ee5a2adaddc1e6f076c129c0bda6eb92fae48f9e82bfbe3758f55cb74270a37",
        "src/resdag/core/feature_extractor.py": "8bbb7c694aca535402f5e9cf03c0d066e418677eaac8eb829accd82ea6ae33ce",
        "src/resdag/core/model.py": "98e9fcbdb11e8f596c637e50e6d10af6198d7220600243d0c72e32932d1ec113",
        "src/resdag/core/workflow.py": "0abe2d4def3d4582f79b5d5d4f0f846f0e9ac6803a0cd834e338b8d379781ff5",
        "src/resdag/data/__init__.py": "07dd030ed3f94267802181d4870a26b3b02980ca6257120873747c900fe91c0e",
        "src/resdag/data/_trajectory.py": "0a74ff17d4a22f50ad355e38f43e1af6bb1bef54503060d4ab7d787231024fe4",
        "src/resdag/data/_trajectory_ports.py": "cdf72c65358bc16c8a5334c8be7d05b64a84f148fd5317dd546697e79492c9b4",
        "src/resdag/data/dataset.py": "72906ccf027725433de70a4a1cd9de6937a073227509d6465373593edea8667a",
        "src/resdag/data/io.py": "445eea54340bd46fd7d8d103b1f662a1cd65d2ae1984e604ac42ab4c8bf53573",
        "src/resdag/data/prepare.py": "9987cb73f009a0a4fb703082aa3812caf0b5971b8895b28eb38bbef7554f94a3",
        "src/resdag/datasets/__init__.py": "402a12335b950051a07920686453a954ecf89fdfc32a91673448b1350ee71bef",
        "src/resdag/ensemble/__init__.py": "9663bdc37ea7d35a2707e3877c9d534171d4d5856cf51832ce16ddbb0f22a5bd",
        "src/resdag/ensemble/aggregators/__init__.py": "4bb5444d0f53a5c07e26e903b14bcf2fd430f7eaaab758592c17ffed8ea388f9",
        "src/resdag/ensemble/aggregators/outliers_filtered_mean.py": "6768a76a989c85c5e289a62e040c2b7fea11111c35e38d01a88d8576307e876d",
        "src/resdag/ensemble/coupled.py": "91030d82e38ecba87c39e837a0d7b0f5526e70f373d7f6e56a30045e5d3f8446",
        "src/resdag/facade.py": "e9096a624dc021d61b59b7ae1351904ec121449da82bdb23daa6bc3826ff6a4f",
        "src/resdag/hpo/__init__.py": "443562e7bcc84e566872eb96e2058aaf9c0d6c92067666c71d2462fe6780dbd4",
        "src/resdag/hpo/_parallel.py": "de30a6a89a28793e862edc13f9fd9da1ba8d64da0fa4471562280497411b7dcc",
        "src/resdag/hpo/_provenance.py": "e582372ccf6e60735e4037a7888897b655570234006ff2ca2b4f42e0ae26a2c6",
        "src/resdag/hpo/_torch_losses.py": "49daaaf381d9a12e8f29089f3f24ec3f0d04403aa374eba9c952996fb861f7b8",
        "src/resdag/hpo/_trial_progress.py": "4a82ad385573ced752e133e34dfcfe6246d616e4ad5fe5ebacc2dbe49d7e51f3",
        "src/resdag/hpo/_tuning_data.py": "b7806297c49fee6e6c272520d0a2d2c615a67635af2cfef6a819533312c11c89",
        "src/resdag/hpo/_tuning_scores.py": "d95657d58e3b2fda468db36290e29f233154f947432aea67a4c8b9be94cca50a",
        "src/resdag/hpo/dispatch.py": "5ed2a5993545cbd05ed0153874be3dfd1a452dc7d35100d84d8271f6d9f3067f",
        "src/resdag/hpo/losses.py": "ce7fcc5818835af36d694470d5434e9c1aae06a51f7cf3ebafac81217f36c68c",
        "src/resdag/hpo/objective.py": "9029d3a0f6ff42356fa0db0b0bb18bc30bf0d05944a6945f4ed1bb5d406717e9",
        "src/resdag/hpo/pruners.py": "c69bec20658a03c9b640121d93ff743d842dc1e919118aef4ee660ec0715c8c2",
        "src/resdag/hpo/resources.py": "d8ceb668a06caa4340700b5bd2927deba6c8d2d000d079cefa55e7484bc70d51",
        "src/resdag/hpo/run.py": "1932bb4fe3f51c220f3e6af7746411eb08ad3d6a36ccc086fd567cd44ae7b812",
        "src/resdag/hpo/storage.py": "925a685184d4648bd2f8b0e7dd63b4f72682e183e2ac063448b1aa40b539fe6a",
        "src/resdag/hpo/transfer.py": "ead7c2efb06c2a9d70132c7b7d124ef2b1922084d7b0f8604e1ac5aee79f00b6",
        "src/resdag/hpo/trial_runner.py": "5cd5f0c53ac6d6868b476c073b019a9bad996d05f5883ab892ef1e5e51541782",
        "src/resdag/hpo/tuning.py": "bd6521926362efc4b9d4bbdf60e59f55cc2c2bbf5803a6ee7732ef1a390e6eac",
        "src/resdag/hpo/utils.py": "34e98a5584a9bbb496cf5954b1be625f635159db6ccd06fcec74a34e61eff5ec",
        "src/resdag/init/__init__.py": "693dea2d9076b80f240f01453fa1c1f7cdf19b76126e3c3e456009265a406fa4",
        "src/resdag/init/graphs/__init__.py": "72a620e96a6f611ebc8fc15bee581fa8cefbe453e5752ac586b8a4ed8c001f2a",
        "src/resdag/init/graphs/_dense.py": "63230c37085569f929155e4b58bf749036dbeec9333992ee56433933393217a4",
        "src/resdag/init/graphs/_sparse.py": "1f32032dc1a3a62aed94c63c9c00b051f12e92ae1ee339707fc3841efe75c073",
        "src/resdag/init/graphs/barabasi_albert.py": "16d1c4612e7a66666287829539d1518a4b52cc56c65b36e11bfa39e46a502825",
        "src/resdag/init/graphs/chord_dendrocycle.py": "767db6261bea6ade8d74e782577dfe7e6ee3261dae8291c49ef309fab6af298c",
        "src/resdag/init/graphs/complete.py": "57396b4b16c83c4a253834843ad18cbe32179fdc6b41e35e6d91f4a1213ea387",
        "src/resdag/init/graphs/connected_erdos_renyi.py": "11cac53111282a40e22e1a93f221e0d8aa5bf83ef6f41072163f59bd8f169fc1",
        "src/resdag/init/graphs/connected_watts_strogatz.py": "d5026a579ed242089facdba63a56f9ead2ad3bbcc5fbe6dae46b0a78a27ccaeb",
        "src/resdag/init/graphs/dendrocycle.py": "cd2d612a02fa79770bf82b819da1019d9d8bff842aa2fd7a848ee1bc3f2aae0f",
        "src/resdag/init/graphs/erdos_renyi.py": "f7d7cc1bafd9bad5dfcb0c5c8ed2f9c43b427b5a6f447eead3e550d8d98c1d88",
        "src/resdag/init/graphs/kleinberg_small_world.py": "c8282657ed3e0d5950c3b18510e9d639eb607818bc54dcddceecd5e3d39c27df",
        "src/resdag/init/graphs/multi_cycle.py": "d4e71f43d5f4850d05c14dc7a5ca53c6225ecf2c436b5b357ca26cf53d65e854",
        "src/resdag/init/graphs/newman_watts_strogatz.py": "22448a8775182eb632f7289618e7e8d62fa97c676e38039b8b5555a0804d165d",
        "src/resdag/init/graphs/random.py": "a5fd59473257a9e626408a04d3e5188611512c77e74652f14616258af9c6c904",
        "src/resdag/init/graphs/regular.py": "42b65129f4b9a491ca7afebee788ad21985f25b86fa57997cb36c0ec71e11b98",
        "src/resdag/init/graphs/ring_chord.py": "d2b241df32c18460ee5794514c42f683548f1a222b9cbee8212e474c5d6dc922",
        "src/resdag/init/graphs/simple_cycle_jumps.py": "d88e0c35a225dd84e78a179a630ae13e8d80b2154eb7635234302760577837cc",
        "src/resdag/init/graphs/spectral_cascade.py": "30ae1e8dda3593159b35f283d9cbe4372c5c72e85a10d83fbc7ffd1ea770516f",
        "src/resdag/init/graphs/watts_strogatz.py": "9e134327c097d0f2518594ecfdc85fee19b2888a5d4f386d1ff4a4da8cb7dddc",
        "src/resdag/init/graphs/zero.py": "f20b4c62c720afd3f05c2707b8a607d91eadf487bad988befa4f2895d9dd14ef",
        "src/resdag/init/input_feedback/__init__.py": "708ba4b80ac8983a1e944e85e65cc88e8f92d7b2a94ae1032a49770c11b2e82d",
        "src/resdag/init/input_feedback/_sign_sampling.py": "c27e79fc538a8b5f3305f8de5feda2de5f7dd68aa56fa7e4d7491a3fdf896a9d",
        "src/resdag/init/input_feedback/base.py": "a0093c432c69da7805378af14ca03bfb957cedfad5aa5485d52db6d9101b70f5",
        "src/resdag/init/input_feedback/bernoulli.py": "43d87f6cc8ef466e80854d9f480e29bad265cb22b15d69e3e65d0def992c75a2",
        "src/resdag/init/input_feedback/binary_balanced.py": "53675a1e9c70163ad97925e5c55dbc028f7682d248970f614b276be5f58781e8",
        "src/resdag/init/input_feedback/chain_of_neurons_input.py": "a725ff24c15c1825503a48eaeaf5261de7834e6c7e758ddbbb66c7a7111ed3e2",
        "src/resdag/init/input_feedback/chebyshev.py": "f168fd899c7e3c35d708c016128be7880cdf593b734f9e512eca98899fbf31d4",
        "src/resdag/init/input_feedback/chessboard.py": "8fb0626923cf42078ed17c61ca451e813f3a3f55bab914beaa99b89ffe8cf69f",
        "src/resdag/init/input_feedback/dendrocycle_input.py": "8a6288cc0d33d0a6855c93bfb08cc403ff97308dcade31eed782afd4f7a59614",
        "src/resdag/init/input_feedback/function.py": "8e72c5e3fd854d95bd610af04b23e2fe3a5c42b375e96b5d84f421c78d938c38",
        "src/resdag/init/input_feedback/informed.py": "be7f7db1c3eadbb2f538bcf8d3b2e919cd4274728380b50e4c2a71a274553813",
        "src/resdag/init/input_feedback/logistic_mapping.py": "d34741496fa9515b0f95073f6f0b90a5da767f2109ac3c7bc5170c2bb5f585d5",
        "src/resdag/init/input_feedback/minimal.py": "79655eedb8cb6daf86c6a4371cea76a2a5fb799d37ccfff8263ed117ca455460",
        "src/resdag/init/input_feedback/normal.py": "aca3c5a4cbe993722201072ab0299756c0d7c39e1b81c26345ada65a90d832e9",
        "src/resdag/init/input_feedback/opposite_anchors.py": "9a8c2a3894491758823263d666dfadd7a53433e495739de2334c01d3b1267471",
        "src/resdag/init/input_feedback/pseudo_diagonal.py": "aa64cc288836aa1cb35e7b4738508eb6ac13f0a8628a2ec9b9de682de40dc51f",
        "src/resdag/init/input_feedback/random.py": "b32018dcd7e11b1bfdf476ec3de9c5f8894faa3e83b111e399ccf683855fb100",
        "src/resdag/init/input_feedback/random_binary.py": "d0633ded78a4cb679ae57c74beb14316a86d2a83948e5a130df453878d0615cb",
        "src/resdag/init/input_feedback/registry.py": "aa407e5d92b296dfe518e83887e259a6e4c48308aba396d8c161ffb3b1caab31",
        "src/resdag/init/input_feedback/ring_window.py": "ffe21ab2f0de06e9b48d0712cc3d76636a55f612bc5735807c38229939caff37",
        "src/resdag/init/input_feedback/uniform.py": "376d7ce7941ad8e8c111cec4d6880c677a3cbff1ed6d8f89d13db9a8c6816dca",
        "src/resdag/init/input_feedback/weighted.py": "877cae56ea1b204a15bf0729166ba855abd5c6c7794f713ce56412867084acab",
        "src/resdag/init/input_feedback/zero.py": "dffbcd650a4752edf116d0568b3eb290018352c5b54cd3a9d1272d9b5c4434f5",
        "src/resdag/init/matrices/__init__.py": "a8a66d7f933145e0f6b2c4ffe89ffa55bddbecc9d43bab2e4e0de56be09770f4",
        "src/resdag/init/matrices/_common.py": "0fbd8956b1fc19dfd14ccd4ca1da34d5e916a6c3a32e8b5b9e9e6d9e926839f4",
        "src/resdag/init/matrices/antisymmetric.py": "96c5b9b3384df3a8e5185bcf8a9ec3b08feefb834d310451cccc672d01646189",
        "src/resdag/init/matrices/fsi.py": "bf6e30a856ae1b3b2f2f2f16cd7685f44707371e298b3c8ff30a70ac654e550d",
        "src/resdag/init/matrices/minimal.py": "79e9169055a4a529847528c14f3b6842f8ffcdde12cec24dbef3c55c5c75b56c",
        "src/resdag/init/matrices/orthogonal.py": "d44540819fa15e05bff1d3d143187b7233048b670f2f59b8297d542d9615b65d",
        "src/resdag/init/matrices/orthogonal_structures.py": "4e2fa149229cb6a6b391643379743b5fc4d742942fce87650e89e689d0245e91",
        "src/resdag/init/matrices/spectral.py": "b16dd21047efb5582707fc0d8fe25a174689cd763d27daec49a2cbcef029136a",
        "src/resdag/init/matrices/structured.py": "78f992c40ee2a00c46e2d85337c900a5c5e4524caec2355347f5b540b54f8ac1",
        "src/resdag/init/recurrent.py": "e381a8453de4304b761a46ea591ae1ddb3f5e3a3b1a730d2f799826c82a82d30",
        "src/resdag/init/topology/__init__.py": "d68bdd19da61d53fb43731f94122ddd5d896f935a66cd6a6f111df70f4a97857",
        "src/resdag/init/topology/_structured.py": "4a9f26fc9bade9645d5320f6e0ba27e5370c581a9cc2a7a80ebdc4aa5fb759f3",
        "src/resdag/init/topology/base.py": "b2a15a5bd6bc5ffea1af1fd6dea1ca508731a99ba150e174f73b31c69b942ca0",
        "src/resdag/init/topology/registry.py": "65695d210e266f659a51f893551a51b0067adcaa9182253f2a7355aa6a198e43",
        "src/resdag/init/utils/__init__.py": "05f52bd7820e0a15713c238fbe48b0b06c9460060dfe1859150296bee67b5c80",
        "src/resdag/init/utils/graph_tools.py": "b87c219785992c6f7b71b3233c5ad0a4243a64efae23dc22575a2704ac87467c",
        "src/resdag/init/utils/resolve.py": "671a3cae60d4a1af6126fe404b7103dffce68cfeae09c11c779cb7939aa09db8",
        "src/resdag/layers/__init__.py": "524ee601becb13cc7b465942f8788c7b5bbb4149470d1c3e016aafd21db5b82f",
        "src/resdag/layers/cells/__init__.py": "d56811b2c03792d7062b561a09f676802fe0435da89e796b5316db9bf5f7a1c5",
        "src/resdag/layers/cells/_compact_recurrent.py": "2b4c79395dfbda78daeec5482dd4996671c89fea560a4c8b78c1f3bb3feee6a3",
        "src/resdag/layers/cells/_initialization.py": "e45ad0187b2719f788934376fe9103cbd0e8832ee0afdfed36e612905ff89f2b",
        "src/resdag/layers/cells/_projected.py": "0b63466840fa57e5f1157fe5d9e6a40d11930749338d3a4778026d19e6989c13",
        "src/resdag/layers/cells/_skip_cell.py": "f142d16bf56ed12c67145fa767da9f45131d8ed2c0296553a52af7d3532c826d",
        "src/resdag/layers/cells/_structured_recurrent.py": "b0f493ef7da9b9bb579afbe586c169472d28162ff66da155162a6e2d6548a167",
        "src/resdag/layers/cells/base_cell.py": "02abd9249c173abe926b8d0895e5ddaa93f5ef50ad10d57b2b1c046422c3b613",
        "src/resdag/layers/cells/continuous_cell.py": "2ac6131537f0d436554d81e7bf0242a35267c8e3658f266053a51047b3e8be82",
        "src/resdag/layers/cells/cornn_cell.py": "c415eff19222258e4bbd8b3e8a226101da41af699b8a531fcf763aca4867539f",
        "src/resdag/layers/cells/es2n_cell.py": "c3045f48c70995321685cf50e920d7c5f1e6b4a4d63e556a056994106eb1b83d",
        "src/resdag/layers/cells/esn_cell.py": "8780f70ad5789571db30d543cdbd5f9862e556da2d260fd6463384b428c9da8a",
        "src/resdag/layers/cells/eusn_cell.py": "3227feae8d5de136e937142d80501d92a318a01bc0f0a5ba35d5f74b245a943e",
        "src/resdag/layers/cells/gated_cell.py": "b87f1ce0c7ee9dc67c3693750c41e67e2bd53b3acf704b54005faf72c31eb3ba",
        "src/resdag/layers/cells/legendre_delay_cell.py": "cc57f69602ed51ebd9ea20355fe143114629802fa2d44748e17d8174ab6756f4",
        "src/resdag/layers/cells/lif_cell.py": "1da640bea3654eb6c1cfde1d430abea8e7a1ffbe39cd3ab2a99b32a2441a2121",
        "src/resdag/layers/cells/ngrc_cell.py": "f51fb1706956c7df9b3974e7b107e67b3c628d3c751bb24310558d22b67bea0d",
        "src/resdag/layers/cells/resesn_cell.py": "2f004b33b36776c42cfef3cc7e86390f3f0aac96f2933b94e88a169e9d83b7e8",
        "src/resdag/layers/cells/spiking_cell.py": "ce83293d4d0e5b05ef25dd3431e81ad5347935cd1614f3822276a2aeb56d5540",
        "src/resdag/layers/cells/torch_recurrent_cell.py": "fb82d5f8d7c2309b6230fccd3462bb9cde487730718cb30639e5ce6f50589e24",
        "src/resdag/layers/readouts/__init__.py": "45d072a28ccb4c699822c859105ed562bc70c95ff07c12987c98cd20495bf3f3",
        "src/resdag/layers/readouts/_solve_utils.py": "df157a90dccc3e147981c184a543311f0786d338d99f24f0149954eccad6d3c5",
        "src/resdag/layers/readouts/auto_readout.py": "4fcf8e63085a00d2ec407452c9561e2b4eece9b6a622f84293a66928e5b31d0c",
        "src/resdag/layers/readouts/base.py": "55c0e7c9b8c955412f4c2281312b2c86e72d2203b5676b1e8adb33418075c65f",
        "src/resdag/layers/readouts/cg_readout.py": "b23c00c83a334d3bff69206280ab2754796155e795ffe16f8704ddec94b312a2",
        "src/resdag/layers/readouts/cholesky_readout.py": "c240a45504eccaf6a4168c60a0a89c11808b539db485e097b7a870924ac77127",
        "src/resdag/layers/readouts/fista_readout.py": "e4f0a326f986ce412ef66302fce457e4f38b2f03495ed8991130a1d104c09d4c",
        "src/resdag/layers/readouts/incremental_ridge.py": "8385c0c68ab2b3425288c218af8819f8ed9b90c72a9f237ea91952a917fc5cb7",
        "src/resdag/layers/readouts/lsmr_readout.py": "49e54144fe2add7ba982c1c4a376316d60d87e6736f20b33be2e7245bda5e325",
        "src/resdag/layers/readouts/pinv_readout.py": "6f875bbf8618beea062caddd6f6c98459cb0403b07de7619c5f6dfedde05314b",
        "src/resdag/layers/readouts/ridge_readout.py": "29ac7b0fd61582bd018db8e566a1a75b485407c70a0e17c5f09120164d1db920",
        "src/resdag/layers/readouts/rls_readout.py": "f61aebeb940bef8c4f1e5e739b2f1dd85c091948973a8753842c9918ef9b3ca4",
        "src/resdag/layers/readouts/svd_readout.py": "e4a79b9195d263a81e7fa23aaf31c54ada38fcf6f4c7189a65ef88443fc66891",
        "src/resdag/layers/reservoirs/__init__.py": "9d4dcb7c184a1c77ba5246b6c87895cf0e9ca29cdbdd2656e176c6f3a7b312f0",
        "src/resdag/layers/reservoirs/_cell_layer.py": "749dd38f93949c5378eb978361da56cc8e95fae506316aeb85e68644878919b1",
        "src/resdag/layers/reservoirs/base_reservoir.py": "ff87bb4aa80752bbcab84c00c9815f119a15d5d91fc2d0a81714d9a95c17e3f1",
        "src/resdag/layers/reservoirs/cornn.py": "2e8e351c5109002f6a34b00e75c7ed521fa6d07d797b22fb2cde11014adab806",
        "src/resdag/layers/reservoirs/es2n.py": "db72ebcbe9a38b92453e7b5dbef5ae836c1ef87d2cda561b7bf57132c2103160",
        "src/resdag/layers/reservoirs/esn.py": "d5a7493619adc35e1a4a7d0a0f425875fd6fbd8db7815d37555b861576748010",
        "src/resdag/layers/reservoirs/eusn.py": "ce6c5fa1eddb3ddf13047d0ef7a7e4b17810bb282742cb3e41a79426e60da7f7",
        "src/resdag/layers/reservoirs/gated.py": "2debd889c4c1e236383a7fe464617c06dd0715bb9ae1b23142892bf287af203e",
        "src/resdag/layers/reservoirs/legendre_delay.py": "01bfcbe32694cd9a02bc73d0f3d1b259eb331f7e3d0b1d3d8cfa2fc83f11448e",
        "src/resdag/layers/reservoirs/lif.py": "6dc7b08c9eaa70cb53bed7a50a1607e891e4edcfe1b14ced2e5f020f98cf166f",
        "src/resdag/layers/reservoirs/ngrc.py": "a5ea928c7777ae40488bd8d055ee3e722e1b32597c0b3c26b1ee1be7318253ef",
        "src/resdag/layers/reservoirs/resesn.py": "faaa770527f685ec0d2a96b3dc1899e518f107af88c38369015075c1acda025b",
        "src/resdag/layers/reservoirs/torch_recurrent.py": "9996074fa8f218e3915c281d1a9fd709ebcae9f14c104d72ff6ded93248fa09d",
        "src/resdag/layers/transforms/__init__.py": "032cf9486e3c56d958c9c29184f5ee9424362889db6aa51a20ce0109297428d0",
        "src/resdag/layers/transforms/concatenate.py": "e998757a367f5dc6390f54f54ed4395429a306c6b956d9f7daccfda37492dec7",
        "src/resdag/layers/transforms/extended_square.py": "7fd5920d8ecaca96655abb150c999f3dc7e214916e903a84f41cc7797cc16059",
        "src/resdag/layers/transforms/feature_partitioner.py": "b1410e8df2da9e0a42c8ed6ab1545ea474a71b0abd46ce22bcca6c5d55fa3db7",
        "src/resdag/layers/transforms/nlat.py": "d37f8286dd5e1ce89ba4de10526238af76590acd5ef93d6af9111d5f2c4cd430",
        "src/resdag/layers/transforms/pad.py": "509e886189b16410c2b643f26023325cafe13d70dc10c8ad84640795ff2de576",
        "src/resdag/layers/transforms/partial_square.py": "120505f3f0c0a77249fe9c293a280a09de07ca53e1342532bfa8d3622043aaea",
        "src/resdag/layers/transforms/power.py": "0dcea9e03099ccbc07eef89c378b74d8449c10f4d82bb687a5d636a61366cb7e",
        "src/resdag/layers/transforms/selective_dropout.py": "4ea2e1eecd98fa204f2cbde9b941017799b2a98f8e8a1a47f85c2a498b5358a9",
        "src/resdag/layers/transforms/selective_exponentiation.py": "1664bbe1dc439f522a6d99f64b06ae4ec9186dbd9151d1f930accbce6e89a24e",
        "src/resdag/layers/transforms/standardize.py": "20dccc68de043fba93a79f4b9d0a96e8d03e0af50b9bd297eb098b530d2e3a4c",
        "src/resdag/metrics/__init__.py": "8a694f09c02f71c9205a8b6737d456a90701814572c2b8c11745580e15d6d815",
        "src/resdag/metrics/forecast.py": "3da46b9fe0599807610ac1abf9101b9bb27af8811e8906244ada0d47d330f318",
        "src/resdag/metrics/lyapunov.py": "5d2f2614c862ef9918916b0aa17c0b8147217f715abb1bea4a8ef4923f2233b9",
        "src/resdag/metrics/observables.py": "ae9fa70006690694ea08fe337586661ff3677c6389e65ba16e87b72ec76efacd",
        "src/resdag/models/__init__.py": "e32f31384288e3e856f3a1ba5cfc986a8854cc57e6b071f4930f626c7f8a0287",
        "src/resdag/models/_builder.py": "1d78274f9cbe06802542570a7ff90a6dbd876b3bfeaf9ed3d661f883fbd56f58",
        "src/resdag/models/_recipes.py": "f1ba39f82bd44db29e5a147f43749bd7e36f5823975a78e68e8d5b32d348cdc5",
        "src/resdag/models/classic_esn.py": "185a71710ca4806d366b782a9f02618cef0f777e641ac9917e0e439fa13c4adf",
        "src/resdag/models/coupled_ensemble_esn.py": "24554e834f33148863ad5eba1a500cdbc8487e95f739f0b4e503b41d27e9054c",
        "src/resdag/models/deep_esn.py": "57f4ceeb6b35c215b779d88d526e9c6c054a87303f4e6066a8b014e7f681e77b",
        "src/resdag/models/es2n.py": "14d491cdcf194cff73219e13dcdac020be513a32c05e401f7f79ac1233b93467",
        "src/resdag/models/eusn.py": "003eab7f5ae64ff736573d06164ac317d2adeee451670b4e7b33b15a869ee565",
        "src/resdag/models/gated_esn.py": "a5570d23440ba3c83513f55a7f5895eb6bff710d0591ccc0cc0498c2f21644a1",
        "src/resdag/models/headless_esn.py": "3ad9bfb33b311db6a87238d14774491a708cc0e47a4a7ad902c6bb35ce3d6a53",
        "src/resdag/models/hybrid_esn.py": "7ed1df57aa97cbcfb4b16e07e0f51b110f73bda41df1a589bb2e54f2b7bfc298",
        "src/resdag/models/linear_esn.py": "b835fa75fbe1262d77081d978ec434982318c4fa5d77f43aeac75fb3d1fd06e1",
        "src/resdag/models/lsm.py": "abaa3676edc6246833b26af7c4cb9eb7f681c8d01cba3038bc551a680da21ac1",
        "src/resdag/models/ott_esn.py": "bdfc19e8d7d76001e676c59068b9f9c882c22b2528183639812cc66da6329cef",
        "src/resdag/models/parallel_esn.py": "7ea0aa8215418350d742da9aa76c08dcd31774fd5c3a7b09b60847f02a989537",
        "src/resdag/models/power_augmented.py": "1f107700197133e32cb24952468fd36218bf693bb8ebf13f7cb5c3cbd76e0b49",
        "src/resdag/models/resesn.py": "24d24fcc48a85cc8b8c6d3774a3512cd3c1b30152885fc4b0bcb33162d0fda2b",
        "src/resdag/training/__init__.py": "ca3b8c06db95758ce233e5296167d7f69aedf861889019df9440addea71c32af",
        "src/resdag/training/calibration.py": "665bd6512ff0a3a7fb5e9e6aa2b9912c2c35402c9a66c5433f081c6487575d8d",
        "src/resdag/training/trainer.py": "c5dce421955a4ba8d0224741d889610a9f74c9b9506251d9fea77395b9b5c62f",
        "src/resdag/utils/__init__.py": "1d0737a4df8dcb238441c1fa7e2263402dc3d312a1c945d0e347df693053c1e7",
        "src/resdag/utils/data/__init__.py": "20fc94d40e01c7d592f1263c2ac4cd5892c7e20764a5dfc00d15ab530e9390a0",
        "src/resdag/utils/data/datasets.py": "8da92747435ea09b92f95ac8c27af7a699fd02fad232895eaa2874cddaad3a3c",
        "src/resdag/utils/data/io.py": "3f9b188416b8067e9a3dfce54bbfd938c0a3419f023329aba6516512c0641ead",
        "src/resdag/utils/data/prepare.py": "75fab72a5c2cc2a04811a9110abc6de3f1e4fc0f0b82a441de1629246166e5e4",
        "src/resdag/utils/general.py": "7aac12d70a3217b7426f8a7fe710d9184bd6e7cc11abf48eb9882cedbc0f4287",
        "src/resdag/utils/seeds.py": "d124e5c2cb37cc0775c2dce9217e75ffd0be36a0baef20ae58e7899781c29808",
        "src/resdag/utils/states/__init__.py": "ec355915994798b9a3cb160b6af30fcc65546896600ffb2ce078d83742be3daa",
        "src/resdag/utils/states/esp_index.py": "f1b9fa028206702a7007a1a49c6e305626e3f360f9982aabc910f41b39781ae6"
      }
    },
    "source_manifest_sha256": {
      "baseline": "d524ec88bcfd6a97f78b1aea7c95a28c46f3a5bf7be1a8f9d732489696799902",
      "candidate": "29d52ecc512388e04269d82967a7c4f2336e4c28a8ae05c98b767bf55ca5e2ee"
    },
    "test_source_sha256": "04426597f3354cd406f616b0683f68e62720c293adc93d33d76f77e5bb0ad9e2",
    "thread_policy": "Verified one Torch intra-op/inter-op and native BLAS/OpenMP thread on the synchronous calling main thread.",
    "timed_repeats_per_case_process": 2,
    "warmups_per_case_process": 1
  },
  "protocol_sha256": "e83786ae59794b1ca7adcad98ceae77be5a7bc3cdf5dbbd0d135760316cad00e",
  "reproduction": {
    "extract_script": "python -c \"import json,pathlib; r=json.load(open('docs/assets/data/phase-five-parallel-cpu-2026-10-23.json')); pathlib.Path('public_replay.py').write_text(r['scripts']['public_replay.py']['source'])\"",
    "portability": "Exact regenerated floating weights/data require the reported stack and numerical behavior; replay fails closed on any fixture mismatch. New timings describe the new host, not a reproduction of elapsed seconds.",
    "procedure": "Extract exact scripts; gitarchive the recorded base; apply embedded source overrides; verify both complete manifests; regenerate fixtures once using the exact script and recorded seeds; require initial model/data tensor fingerprints; run2fresh-processABBArounds; preserve all samples and require all numerical hashes to agree with each other and the published hashes. New artifact serialization and host/native receipts get their own new protocol digest.",
    "ratio_formula": "For each round/case/metric, exclude warmup, pool2timed repeats from each of2processes per variant, take median; speedup=baseline_median/candidate_median.",
    "requirements": "A checkout containing protocol.git_head, the reported Python/Torch/native dependency stack and benchmark requirements. git on PATH. Own the CPU exclusively. No private artifact directory is required.",
    "run": "python public_replay.py docs/assets/data/phase-five-parallel-cpu-2026-10-23.json --repository . --output /absolute/path/to/new-replay-directory",
    "validation": "Replay extraction, source reconstruction, script syntax and receipt arithmetic are checked statically. The relocated end-to-end replayer has not yet been run; completed measurements used the embedded original driver."
  },
  "samples": [
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.03596470800039242,
      "history_forecast_seconds": 0.007851583002775442,
      "iteration": 0,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010503125002287561,
      "history_forecast_seconds": 0.0073253330010629725,
      "iteration": 1,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010827291996974964,
      "history_forecast_seconds": 0.007283333998202579,
      "iteration": 2,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.06887920900044264,
      "history_forecast_seconds": 0.021214500000496628,
      "iteration": 0,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05338649999976042,
      "history_forecast_seconds": 0.021183791999646928,
      "iteration": 1,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.051560291001806036,
      "history_forecast_seconds": 0.022067499998229323,
      "iteration": 2,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028787874998670304,
      "history_forecast_seconds": 0.01304116699975566,
      "iteration": 0,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028261958999792114,
      "history_forecast_seconds": 0.013407250000454951,
      "iteration": 1,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028232124997884966,
      "history_forecast_seconds": 0.014501584002573509,
      "iteration": 2,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.2655207079988031,
      "history_forecast_seconds": 0.06450137499996345,
      "iteration": 0,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.1912231670030451,
      "history_forecast_seconds": 0.06566570900031365,
      "iteration": 1,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.2022238749996177,
      "history_forecast_seconds": 0.06481004099987331,
      "iteration": 2,
      "process": "r0-s0",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.012415832999977283,
      "history_forecast_seconds": 0.010278875000949483,
      "iteration": 0,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.011198874999536201,
      "history_forecast_seconds": 0.006775665999157354,
      "iteration": 1,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010910875000263331,
      "history_forecast_seconds": 0.006742166002368322,
      "iteration": 2,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.060038957999495324,
      "history_forecast_seconds": 0.021142374996998115,
      "iteration": 0,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05314666599952034,
      "history_forecast_seconds": 0.02034941699821502,
      "iteration": 1,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05365887500011013,
      "history_forecast_seconds": 0.019316292000439717,
      "iteration": 2,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.029499915999622317,
      "history_forecast_seconds": 0.011907666001206962,
      "iteration": 0,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.029616125000757165,
      "history_forecast_seconds": 0.012430333001248073,
      "iteration": 1,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.02988366699719336,
      "history_forecast_seconds": 0.012267334001080599,
      "iteration": 2,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.22330895800041617,
      "history_forecast_seconds": 0.06470991600144771,
      "iteration": 0,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.19634654200126533,
      "history_forecast_seconds": 0.06913262500165729,
      "iteration": 1,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.21906120799758355,
      "history_forecast_seconds": 0.06416783299937379,
      "iteration": 2,
      "process": "r0-s1",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.013472209000610746,
      "history_forecast_seconds": 0.006814000000304077,
      "iteration": 0,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010824541001056787,
      "history_forecast_seconds": 0.007810708997567417,
      "iteration": 1,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010719958998379298,
      "history_forecast_seconds": 0.0066151659993920475,
      "iteration": 2,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.06293287500011502,
      "history_forecast_seconds": 0.020243167000444373,
      "iteration": 0,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.058304417001636466,
      "history_forecast_seconds": 0.022322709002764896,
      "iteration": 1,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05356120800206554,
      "history_forecast_seconds": 0.020504125001025386,
      "iteration": 2,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.0293366670011892,
      "history_forecast_seconds": 0.012388207996991696,
      "iteration": 0,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.029450082998664584,
      "history_forecast_seconds": 0.012415249999321532,
      "iteration": 1,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028545958000904648,
      "history_forecast_seconds": 0.012431582999852253,
      "iteration": 2,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.23081208299845457,
      "history_forecast_seconds": 0.06396587500057649,
      "iteration": 0,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.280069625001488,
      "history_forecast_seconds": 0.06343395799922291,
      "iteration": 1,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.19504404200051795,
      "history_forecast_seconds": 0.06215291599801276,
      "iteration": 2,
      "process": "r0-s2",
      "round": 0,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.012136332999943988,
      "history_forecast_seconds": 0.007429167002555914,
      "iteration": 0,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.01083370799824479,
      "history_forecast_seconds": 0.00830679200225859,
      "iteration": 1,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010483250000106636,
      "history_forecast_seconds": 0.007521290997829055,
      "iteration": 2,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.058829125002375804,
      "history_forecast_seconds": 0.021926290999545017,
      "iteration": 0,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05265345900261309,
      "history_forecast_seconds": 0.021017584000219358,
      "iteration": 1,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05162962499889545,
      "history_forecast_seconds": 0.0213605839999218,
      "iteration": 2,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.029499833002773812,
      "history_forecast_seconds": 0.01340041699950234,
      "iteration": 0,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028114583001297433,
      "history_forecast_seconds": 0.013734250002016779,
      "iteration": 1,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028631625002162764,
      "history_forecast_seconds": 0.013497916999767767,
      "iteration": 2,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.21890012500080047,
      "history_forecast_seconds": 0.06749970899909385,
      "iteration": 0,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.19474287499906495,
      "history_forecast_seconds": 0.06660954200197011,
      "iteration": 1,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.190796083999885,
      "history_forecast_seconds": 0.06428487499943003,
      "iteration": 2,
      "process": "r0-s3",
      "round": 0,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.012679499999649124,
      "history_forecast_seconds": 0.009325749997515231,
      "iteration": 0,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.011987709000095492,
      "history_forecast_seconds": 0.00796545800039894,
      "iteration": 1,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010864666997804306,
      "history_forecast_seconds": 0.007329250001930632,
      "iteration": 2,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05833441600043443,
      "history_forecast_seconds": 0.020536416999675566,
      "iteration": 0,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05262387499897159,
      "history_forecast_seconds": 0.021175541001866804,
      "iteration": 1,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05252820900204824,
      "history_forecast_seconds": 0.02185641699907137,
      "iteration": 2,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028805125002691057,
      "history_forecast_seconds": 0.014030124999408145,
      "iteration": 0,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.02851770799679798,
      "history_forecast_seconds": 0.0140082079997228,
      "iteration": 1,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.02826949999871431,
      "history_forecast_seconds": 0.01394787499884842,
      "iteration": 2,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.21579520799787133,
      "history_forecast_seconds": 0.06403716599743348,
      "iteration": 0,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.1943833330005873,
      "history_forecast_seconds": 0.06815370900221751,
      "iteration": 1,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.1934884999973292,
      "history_forecast_seconds": 0.06332599999950617,
      "iteration": 2,
      "process": "r1-s0",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.012200250002933899,
      "history_forecast_seconds": 0.006546791999426205,
      "iteration": 0,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010708416000852594,
      "history_forecast_seconds": 0.007063750002998859,
      "iteration": 1,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010386750000179745,
      "history_forecast_seconds": 0.008715416999621084,
      "iteration": 2,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05998570800147718,
      "history_forecast_seconds": 0.019587583003158215,
      "iteration": 0,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05096008299733512,
      "history_forecast_seconds": 0.019241833997512003,
      "iteration": 1,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05129970900088665,
      "history_forecast_seconds": 0.019172291998984292,
      "iteration": 2,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028402666001056787,
      "history_forecast_seconds": 0.01237720800054376,
      "iteration": 0,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028896207997604506,
      "history_forecast_seconds": 0.012380541000311496,
      "iteration": 1,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.029030958001385443,
      "history_forecast_seconds": 0.012348042000667192,
      "iteration": 2,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.21675312500155997,
      "history_forecast_seconds": 0.06224441599988495,
      "iteration": 0,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.19232295799884014,
      "history_forecast_seconds": 0.06389095799750066,
      "iteration": 1,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.1920235830002639,
      "history_forecast_seconds": 0.06284237500221934,
      "iteration": 2,
      "process": "r1-s1",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.014284207998571219,
      "history_forecast_seconds": 0.0066087500017602,
      "iteration": 0,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010508082999876933,
      "history_forecast_seconds": 0.00667658299789764,
      "iteration": 1,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010088084000017261,
      "history_forecast_seconds": 0.006754165999154793,
      "iteration": 2,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.057758083999942755,
      "history_forecast_seconds": 0.019108624997898005,
      "iteration": 0,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05227479099994525,
      "history_forecast_seconds": 0.02015637499789591,
      "iteration": 1,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.053403500001877546,
      "history_forecast_seconds": 0.019893042001058348,
      "iteration": 2,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.029799042000377085,
      "history_forecast_seconds": 0.013441416998830391,
      "iteration": 0,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.02900516699810396,
      "history_forecast_seconds": 0.014500874996883795,
      "iteration": 1,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.030582417002733564,
      "history_forecast_seconds": 0.013062666999758221,
      "iteration": 2,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.2569911249993311,
      "history_forecast_seconds": 0.06584412500160397,
      "iteration": 0,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": true
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.1987827080010902,
      "history_forecast_seconds": 0.061942915999679826,
      "iteration": 1,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.19719362500109128,
      "history_forecast_seconds": 0.06504504099939368,
      "iteration": 2,
      "process": "r1-s2",
      "round": 1,
      "variant": "candidate",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.012105582998628961,
      "history_forecast_seconds": 0.007270875001267996,
      "iteration": 0,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.01003537500218954,
      "history_forecast_seconds": 0.007231000003230292,
      "iteration": 1,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p8",
      "exactness_id": "b1-p8",
      "exactness_sha256": "2f99085036e72a4786be3ffce668865302df2ba19dd291a98aff0e187e2d6cf7",
      "fit_seconds": 0.010105624998686835,
      "history_forecast_seconds": 0.00724570799866342,
      "iteration": 2,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05851004200303578,
      "history_forecast_seconds": 0.021809083998959977,
      "iteration": 0,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.05236437500207103,
      "history_forecast_seconds": 0.021021667002059985,
      "iteration": 1,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b1-p64",
      "exactness_id": "b1-p64",
      "exactness_sha256": "ac26f8a434c92700c57028df842194524688f5abdfc65a4dabae347972792ec1",
      "fit_seconds": 0.052737750000233063,
      "history_forecast_seconds": 0.020838125001318986,
      "iteration": 2,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028631666998990113,
      "history_forecast_seconds": 0.013357250001718057,
      "iteration": 0,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.02963304099830566,
      "history_forecast_seconds": 0.013355374998354819,
      "iteration": 1,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p8",
      "exactness_id": "b4-p8",
      "exactness_sha256": "f72ebd6068758ff394948db98fd68a37986592401264521414f9ca8da9934bb2",
      "fit_seconds": 0.028496541002823506,
      "history_forecast_seconds": 0.013937874999101041,
      "iteration": 2,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.23695254199992632,
      "history_forecast_seconds": 0.06980195900177932,
      "iteration": 0,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": true
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.19428429100298672,
      "history_forecast_seconds": 0.0658832090011856,
      "iteration": 1,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    },
    {
      "case": "b4-p64",
      "exactness_id": "b4-p64",
      "exactness_sha256": "3560c3ef1f7559f2c551f8bcfd6c33881c3d94fc03ef181aa1dde66abea681db",
      "fit_seconds": 0.19241770900043775,
      "history_forecast_seconds": 0.06604137500107754,
      "iteration": 2,
      "process": "r1-s3",
      "round": 1,
      "variant": "baseline",
      "warmup": false
    }
  ],
  "schema": 1,
  "scope": "Four fixed synthetic cases, N150, float64 CPU, core4/halo6, B1/B4 \u00d7 P8/P64. Public rd.Model.fit and history+forecast, with identical saved model/data fixtures. No constructor, accuracy, cross-library or universal throughput claim.",
  "scripts": {
    "final_compare.py": {
      "sha256": "1a4fd99511477569770a49a9609a4cba1640f8c6bb89e332e29ea0dbe93086d3",
      "source": "\"\"\"Final public workflow comparison: production candidate versus frozen old loop.\n\nBoth source trees share every other final runtime module. No ephemeral patches.\n\"\"\"\nfrom __future__ import annotations\n\nimport argparse\nimport hashlib\nimport json\nimport os\nfrom pathlib import Path\nimport shutil\nimport statistics\nimport subprocess\nimport sys\n\nimport probe\n\nROOT = probe.ROOT\nFINAL = ROOT / 'final'\n\n\ndef freeze():\n    if FINAL.exists():\n        raise RuntimeError('Final source already frozen')\n    candidate = FINAL / 'candidate-source'\n    baseline = FINAL / 'baseline-source'\n    for name in ('src', 'benchmarks'):\n        shutil.copytree(probe.REPO / name, candidate / name,\n                        ignore=shutil.ignore_patterns('__pycache__', '*.pyc'))\n    shutil.copytree(candidate, baseline)\n    parallel = 'src/resdag/models/parallel_esn.py'\n    shutil.copyfile(ROOT / 'source' / parallel, baseline / parallel)\n    manifests = {variant: {str(path.relative_to(source)): probe.digest(path)\n                          for path in sorted(source.rglob('*.py'))}\n                 for variant, source in (('baseline', baseline), ('candidate', candidate))}\n    differences = [name for name in manifests['baseline']\n                   if manifests['baseline'][name] != manifests['candidate'][name]]\n    if differences != [parallel]:\n        raise RuntimeError(f'Unexpected source differences: {differences}')\n    protocol = {\n        'schema': 1, 'cases': probe.CASES,\n        'source_files': manifests,\n        'source_manifest_sha256': {key: hashlib.sha256(json.dumps(value, sort_keys=True).encode()).hexdigest()\n                                   for key, value in manifests.items()},\n        'source_differences': differences,\n        'git_head': subprocess.check_output(['git', 'rev-parse', 'HEAD'], cwd=probe.REPO, text=True).strip(),\n        'git_status': subprocess.check_output(['git', 'status', '--short'], cwd=probe.REPO, text=True),\n        'test_source_sha256': probe.digest(probe.REPO / 'tests/test_models/test_parallel_forecast_step.py'),\n        'artifacts_sha256': probe.digest(ROOT / 'artifacts.json'),\n        'frozen_probe_sha256': probe.digest(ROOT / 'probe.py'),\n        'driver_sha256': probe.digest(Path(__file__)),\n        'rounds': 2, 'process_order': ['baseline', 'candidate', 'candidate', 'baseline'],\n        'warmups_per_case_process': 1, 'timed_repeats_per_case_process': 2,\n        'public_boundary': 'rd.Model.fit(observations), including transaction/scalers, and forecast(history,horizon=129,compile=False); external deepcopy/loading/fingerprints excluded.',\n        'constructor_boundary': 'Untimed shared saved model artifacts; this comparison measures the forecast-only production change and does not measure constructor normalization.',\n        'thread_policy': 'Verified one Torch intra-op/inter-op and native BLAS/OpenMP thread on the synchronous calling main thread.',\n        'acceptance': 'All fitted tensor, fit-state, full prediction and final-state hashes must match across all warmup/timed repeats and both variants; retain all raw samples.',\n        'scope': 'Fixed synthetic four-case CPU matrix; no accuracy, cross-library or universal speed claim.',\n    }\n    probe.write(FINAL / 'protocol.json', protocol)\n\n\ndef load_runtime(variant):\n    protocol = json.loads((FINAL / 'protocol.json').read_text())\n    for name, expected in (('artifacts.json', protocol['artifacts_sha256']),\n                           ('probe.py', protocol['frozen_probe_sha256'])):\n        if probe.digest(ROOT / name) != expected:\n            raise RuntimeError(f'Changed measurement input: {name}')\n    source = FINAL / f'{variant}-source'\n    for relative, expected in protocol['source_files'][variant].items():\n        if probe.digest(source / relative) != expected:\n            raise RuntimeError(f'Frozen source changed: {relative}')\n    sys.path[:0] = [str(source / 'src'), str(source)]\n    from benchmarks.rc_bench import _threads\n    _threads.bootstrap_cli()\n    import resdag as rd\n    import torch\n    if not Path(rd.__file__).resolve().is_relative_to(source):\n        raise RuntimeError('Unexpected ResDAG import')\n    return rd, torch, _threads\n\n\ndef worker(variant, output):\n    rd, torch, threads = load_runtime(variant)\n    probe.worker('baseline', output, rd, torch, threads)  # no experimental patch\n    result = json.loads((ROOT / f'{output}.json').read_text())\n    result['mode'] = variant\n    result['source_variant'] = variant\n    result['source_manifest_sha256'] = json.loads((FINAL / 'protocol.json').read_text())['source_manifest_sha256'][variant]\n    probe.write(ROOT / f'{output}.json', result)\n\n\ndef summarize():\n    comparisons = []\n    reference = {}\n    for round_index in range(2):\n        processes = [json.loads((ROOT / f'final-r{round_index}-s{slot}.json').read_text()) for slot in range(4)]\n        for case_index, case in enumerate(probe.CASES):\n            for process in processes:\n                for repeat in process['cases'][case_index]['repeats']:\n                    hashes = repeat['hashes']\n                    if case['id'] in reference and reference[case['id']] != hashes:\n                        raise RuntimeError(f'Full workflow exactness mismatch: {case[\"id\"]}')\n                    reference[case['id']] = hashes\n            rows = {\n                variant: [processes[slot]['cases'][case_index]['repeats'][repeat]\n                          for slot in slots for repeat in (1, 2)]\n                for variant, slots in (('baseline', (0, 3)), ('candidate', (1, 2)))\n            }\n            comparisons.append({'round': round_index, 'case': case['id'], 'all_hashes_exact': True,\n                                **{key: {'baseline_seconds': statistics.median(row[key] for row in rows['baseline']),\n                                         'candidate_seconds': statistics.median(row[key] for row in rows['candidate']),\n                                         'speedup': statistics.median(row[key] for row in rows['baseline']) /\n                                                    statistics.median(row[key] for row in rows['candidate'])}\n                                   for key in ('fit_seconds', 'history_forecast_seconds')}})\n    result = {'comparisons': comparisons, 'all_hashes_exact': True,\n              'counts': {'fresh_processes': 8, 'cases': 4, 'timed_fit_forecast_pairs': 64,\n                         'untimed_warmup_fit_forecast_pairs': 32},\n              'script_sha256': probe.digest(Path(__file__)), 'protocol_sha256': probe.digest(FINAL / 'protocol.json')}\n    probe.write(FINAL / 'summary.json', result)\n    print(json.dumps(result, indent=2), flush=True)\n\n\ndef run():\n    environment = os.environ | {name: '1' for name in ('VECLIB_MAXIMUM_THREADS', 'OPENBLAS_NUM_THREADS',\n                                                     'MKL_NUM_THREADS', 'OMP_NUM_THREADS', 'BLIS_NUM_THREADS')}\n    for round_index in range(2):\n        for slot, variant in enumerate(('baseline', 'candidate', 'candidate', 'baseline')):\n            subprocess.run([str(probe.PYTHON), str(Path(__file__).resolve()), '--worker', variant,\n                            '--output', f'final-r{round_index}-s{slot}'], cwd=ROOT,\n                           env=environment, check=True)\n        print(f'Completed final round{round_index}', flush=True)\n    summarize()\n\n\nif __name__ == '__main__':\n    parser = argparse.ArgumentParser()\n    parser.add_argument('--freeze', action='store_true')\n    parser.add_argument('--run', action='store_true')\n    parser.add_argument('--worker', choices=('baseline', 'candidate'))\n    parser.add_argument('--output')\n    args = parser.parse_args()\n    if args.freeze:\n        freeze()\n    elif args.run:\n        run()\n    elif args.worker and args.output:\n        worker(args.worker, args.output)\n    else:\n        parser.error('Choose --freeze, --run, or --worker with --output')\n"
    },
    "probe.py": {
      "sha256": "ed5565a8de46d8d1c0240b3e260152a4ce0ffbb35df4fb6d360e02f8427cb140",
      "source": "\"\"\"Private, source-frozen, all-PyTorch parallel workflow diagnostics.\n\nThis is experimental measurement code, not a proposed runtime implementation.\nOnly --freeze is stdlib-only; all other modes require the numerical gate.\n\"\"\"\nfrom __future__ import annotations\n\nimport argparse\nimport copy\nimport hashlib\nimport inspect\nimport json\nimport os\nfrom pathlib import Path\nimport shutil\nimport statistics\nimport subprocess\nimport sys\nimport textwrap\nimport time\n\nROOT = Path(__file__).resolve().parent\nREPO = Path('/Users/daniel/Projects/resdag')\nPYTHON = REPO / '.venv/bin/python'\nMODES = ('baseline', 'index_select', 'core_targets', 'forecast', 'combined')\nCASES = tuple({'id': f'b{b}-p{p}', 'batch': b, 'patches': p,\n               'features': p * 4, 'steps': 501, 'washout': 100,\n               'history': 100, 'horizon': 129, 'units': 150}\n              for b in (1, 4) for p in (8, 64))\n\n\ndef write(path, value):\n    path.write_text(json.dumps(value, indent=2, sort_keys=True) + '\\n')\n\n\ndef digest(path):\n    return hashlib.sha256(path.read_bytes()).hexdigest()\n\n\ndef freeze():\n    target = ROOT / 'source'\n    if target.exists():\n        raise RuntimeError('Source already frozen; choose a new artifact directory')\n    shutil.copytree(REPO / 'src', target / 'src', ignore=shutil.ignore_patterns('__pycache__', '*.pyc'))\n    shutil.copytree(REPO / 'benchmarks', target / 'benchmarks',\n                    ignore=shutil.ignore_patterns('__pycache__', '*.pyc'))\n    files = {str(p.relative_to(target)): digest(p)\n             for p in sorted(target.rglob('*.py'))}\n    write(ROOT / 'protocol.json', {\n        'schema': 1,\n        'purpose': 'Bounded synthetic CPU copy/dispatch investigation; no accuracy claim',\n        'repository': str(REPO),\n        'git_head': subprocess.check_output(['git', 'rev-parse', 'HEAD'], cwd=REPO, text=True).strip(),\n        'git_status': subprocess.check_output(['git', 'status', '--short'], cwd=REPO, text=True),\n        'source_files': files,\n        'source_manifest_sha256': hashlib.sha256(json.dumps(files, sort_keys=True).encode()).hexdigest(),\n        'cases': CASES, 'modes': MODES, 'process_order': ['baseline', 'candidate', 'candidate', 'baseline'],\n        'rounds': 2, 'warmups_per_case_process': 1, 'timed_repeats_per_case_process': 2,\n        'seeds': {'weights': 2026102307, 'data': 2026102308},\n        'timing_boundary': 'Public rd.Model.fit(observations), including transactional staging; then public history+forecast. Outer deepcopy, artifact loads and fingerprints excluded.',\n        'source_policy': 'Snapshot of live src and benchmark helpers, including uncommitted changes; all workers verify every source digest.',\n        'candidate_policy': 'Ephemeral class-method patches only, preserving original numerical operations for admitted built-in fixtures; never writes repository.',\n        'gradient_policy': 'Independent noncontiguous small trainable workflow comparison; exact fingerprints plus maxabs and tight allclose recorded.',\n        'four_thread_policy': 'Separate diagnostic: four Torch intra-op threads within verified native BLAS single-thread context; not a claim to recreate unrecorded historical BLAS policy.',\n    })\n    print(str(ROOT), flush=True)\n\n\ndef load_runtime():\n    protocol = json.loads((ROOT / 'protocol.json').read_text())\n    for relative, expected in protocol['source_files'].items():\n        if digest(ROOT / 'source' / relative) != expected:\n            raise RuntimeError(f'Source digest changed: {relative}')\n    sys.path[:0] = [str(ROOT / 'source' / 'src'), str(ROOT / 'source')]\n    from benchmarks.rc_bench import _threads\n    _threads.bootstrap_cli()\n    import torch\n    import resdag as rd\n    if not Path(rd.__file__).resolve().is_relative_to(ROOT / 'source'):\n        raise RuntimeError(f'Unexpected resdag import: {rd.__file__}')\n    return protocol, rd, torch, _threads\n\n\ndef tensor_record(tensor):\n    value = tensor.detach().cpu().contiguous()\n    return {'shape': list(value.shape), 'dtype': str(value.dtype),\n            'sha256': hashlib.sha256(value.numpy().tobytes()).hexdigest()}\n\n\ndef tensor_dict_record(values):\n    tensors = {str(k): tensor_record(v) for k, v in sorted(values.items())\n               if hasattr(v, 'detach')}\n    return {'tensors': tensors,\n            'sha256': hashlib.sha256(json.dumps(tensors, sort_keys=True).encode()).hexdigest()}\n\n\ndef install(mode, torch):\n    from resdag.models.parallel_esn import ParallelESNModel\n    from resdag.layers import ESNLayer\n    from resdag.layers.cells import ESNCell\n    from resdag.layers.readouts import ReadoutLayer\n    from resdag.layers.reservoirs.base_reservoir import BaseReservoirLayer\n    from resdag.core._hooks import has_execution_hooks\n    original_window = ParallelESNModel.window\n    original_fit = ParallelESNModel.fit\n    original_forecast = ParallelESNModel.forecast\n    original_forward = ParallelESNModel.forward\n\n    def replace(function, before, after, additions=None):\n        source = textwrap.dedent(inspect.getsource(function))\n        if source.count(before) != 1:\n            raise RuntimeError(f'Unrecognized frozen source for {function.__name__}')\n        namespace = dict(function.__globals__)\n        namespace.update(additions or {})\n        exec(compile(source.replace(before, after), str(ROOT / f'ephemeral-{mode}.py'), 'exec'), namespace)\n        return namespace[function.__name__]\n\n    if mode in ('index_select', 'combined'):\n        ParallelESNModel.window = replace(\n            original_window, 'windowed = series[..., self.patch_index]',\n            'windowed = series.index_select(-1, self.patch_index.reshape(-1)).reshape(*series.shape[:2], *self.patch_index.shape)')\n    admitted_window = ParallelESNModel.window\n\n    if mode in ('core_targets', 'combined'):\n        ParallelESNModel.fit = replace(\n            original_fit,\n            'windowed_targets = self.window(targets)  # (B*P, T, w+2g)\\n    core_targets = windowed_targets[..., self._cores_from_index()]  # (B*P, T, w)',\n            'if getattr(self.window, \"__func__\", None) is _admitted_window:\\n'\n            '        core_index = self.patch_index[:, self._cores_from_index()]\\n'\n            '        gathered = targets[..., core_index]\\n'\n            '        core_targets = gathered.permute(0, 2, 1, 3).reshape(targets.shape[0] * self.n_patches, targets.shape[1], self.core_width)\\n'\n            '    else:\\n'\n            '        windowed_targets = self.window(targets)\\n'\n            '        core_targets = windowed_targets[..., self._cores_from_index()]',\n            {'_admitted_window': admitted_window})\n\n    def eligible(model):\n        reservoir, cell, readout = model.reservoir, model.reservoir.cell, model.readout\n        return (\n            type(model) is ParallelESNModel and type(reservoir) is ESNLayer and type(cell) is ESNCell\n            and getattr(model.forward, '__func__', None) is original_forward\n            and getattr(reservoir.forward, '__func__', None) is BaseReservoirLayer.forward\n            and getattr(reservoir.forward_stateless, '__func__', None) is BaseReservoirLayer.forward_stateless\n            and getattr(cell.project_inputs, '__func__', None) is ESNCell.project_inputs\n            and getattr(cell.step, '__func__', None) is ESNCell.step\n            and getattr(readout.forward, '__func__', None) is ReadoutLayer.forward\n            and cell.activation_fn is cell._get_activation(cell.activation)\n            and next(cell.parameters()).device.type == 'cpu'\n            and not has_execution_hooks(model)\n        )\n\n    def single_step(model, series):\n        patches = model.window(series)\n        reservoir = model.reservoir\n        reservoir._maybe_init_state(patches.shape[0], patches.device, patches.dtype)\n        projected = reservoir.cell.project_inputs([patches])  # retain original 3-D F.linear dispatch\n        features, state = reservoir.cell.step(projected[:, 0, :], reservoir.state)\n        reservoir.state = state\n        reservoir._state_user_set = False\n        cores = model.readout(features.unsqueeze(1))  # admitted readout is non-mutating\n        return cores.reshape(series.shape[0], model.n_patches, 1, model.core_width).permute(0, 2, 1, 3).reshape(series.shape[0], 1, model.input_dim)\n\n    if mode in ('forecast', 'combined'):\n        fast_forecast = replace(original_forecast, 'current = forward(current)',\n                                'current = _single_step(self, current)', {'_single_step': single_step})\n\n        def guarded_forecast(self, *args, **kwargs):\n            return (fast_forecast if eligible(self) else original_forecast)(self, *args, **kwargs)\n\n        ParallelESNModel.forecast = guarded_forecast\n    return {'window': original_window, 'fit': original_fit, 'forecast': original_forecast,\n            'eligible': eligible, 'single_step': single_step}\n\n\ndef prepare(rd, torch, threads):\n    artifacts = {}\n    with threads.single_thread_policy() as policy:\n        torch.set_default_dtype(torch.float64)\n        for case in CASES:\n            graph = rd.parallel_esn(input_dim=case['features'], core_width=4, halo=6,\n                                    reservoir_size=150, spectral_radius=0.6, seed=2026102307,\n                                    readout_alpha=1e-3, dtype=torch.float64).eval()\n            model = rd.Model(graph=graph, washout=case['washout']).eval()\n            generator = torch.Generator().manual_seed(2026102308 + case['batch'] + case['patches'])\n            observations = 0.35 * torch.randn(case['batch'], case['steps'], case['features'],\n                                             generator=generator, dtype=torch.float64)\n            path = ROOT / f\"artifact-{case['id']}.pt\"\n            torch.save({'model': model, 'observations': observations}, path)\n            artifacts[case['id']] = {'path': path.name, 'sha256': digest(path),\n                                     'initial': tensor_dict_record(model.state_dict()),\n                                     'data': tensor_record(observations)}\n        write(ROOT / 'artifacts.json', {'cases': artifacts, 'thread_policy': policy})\n\n\ndef loaded(case, torch):\n    artifacts = json.loads((ROOT / 'artifacts.json').read_text())['cases'][case['id']]\n    path = ROOT / artifacts['path']\n    if digest(path) != artifacts['sha256']:\n        raise RuntimeError('Artifact changed')\n    return torch.load(path, map_location='cpu', weights_only=False)\n\n\ndef one_workflow(model, observations, case, threads):\n    fitted = copy.deepcopy(model)  # deliberately outside fit timer\n    threads.verify_thread_policy()\n    started = time.perf_counter()\n    fitted.fit(observations)\n    fit_seconds = time.perf_counter() - started\n    threads.verify_thread_policy()\n    fit_state = tensor_dict_record(fitted.get_state())\n    coefficients = tensor_dict_record(fitted.state_dict())\n    started = time.perf_counter()\n    prediction = fitted.forecast(history=observations[:, -case['history']:], horizon=case['horizon'], compile=False)\n    forecast_seconds = time.perf_counter() - started\n    threads.verify_thread_policy()\n    if prediction.shape != (case['batch'], case['horizon'], case['features']):\n        raise RuntimeError('Incorrect prediction shape')\n    return fitted, prediction, {'fit_seconds': fit_seconds, 'history_forecast_seconds': forecast_seconds,\n                                'hashes': {'fitted': coefficients, 'fit_state': fit_state,\n                                           'prediction': tensor_record(prediction),\n                                           'forecast_state': tensor_dict_record(fitted.get_state())}}\n\n\ndef worker(mode, output, rd, torch, threads):\n    install(mode, torch)\n    rows, numerical = [], {}\n    with threads.single_thread_policy() as policy:\n        for case in CASES:\n            artifact = loaded(case, torch)\n            reference = None\n            repeats = []\n            for iteration in range(3):\n                fitted, prediction, row = one_workflow(artifact['model'], artifact['observations'], case, threads)\n                if reference is not None and row['hashes'] != reference:\n                    raise RuntimeError(f\"Unstable repeats: {case['id']} / {mode}\")\n                reference = row['hashes']\n                row.update({'iteration': iteration, 'warmup': iteration == 0})\n                repeats.append(row)\n            numerical[case['id']] = {'prediction': prediction, 'fitted': fitted.state_dict(),\n                                      'final_state': fitted.get_state()}\n            rows.append({'case': case, 'repeats': repeats})\n        torch.save(numerical, ROOT / f'{output}.pt')\n        write(ROOT / f'{output}.json', {'mode': mode, 'cases': rows, 'thread_policy': policy,\n                                       'tensor_artifact': {'path': f'{output}.pt', 'sha256': digest(ROOT / f'{output}.pt')}})\n\n\ndef gradients(mode, rd, torch, threads):\n    from resdag.models.parallel_esn import ParallelESNModel\n    originals = {key: getattr(ParallelESNModel, key) for key in ('window', 'fit', 'forecast')}\n    records = []\n    with threads.single_thread_policy():\n        for batch in (1, 4):\n            for timesteps in (1, 5):\n                torch.manual_seed(2026102309)\n                baseline = rd.parallel_esn(input_dim=32, core_width=4, halo=6, reservoir_size=12,\n                                           spectral_radius=0.3, seed=23, trainable=True,\n                                           dtype=torch.float64).eval()\n                candidate = copy.deepcopy(baseline)\n                initial = torch.randn(batch, timesteps, 64, dtype=torch.float64)\n                x = initial[..., ::2].detach().requires_grad_()\n                expected = baseline(x, reset=True)\n                loss = expected.square().sum() + baseline.reservoir.state.square().sum()\n                expected_grad = torch.autograd.grad(loss, (x, *(p for p in baseline.parameters() if p.requires_grad)))\n                install(mode, torch)\n                y = initial[..., ::2].detach().requires_grad_()\n                actual = candidate(y, reset=True)\n                loss = actual.square().sum() + candidate.reservoir.state.square().sum()\n                actual_grad = torch.autograd.grad(loss, (y, *(p for p in candidate.parameters() if p.requires_grad)))\n                differences = [float((a - b).abs().max()) for a, b in zip(expected_grad, actual_grad)]\n                records.append({'batch': batch, 'timesteps': timesteps,\n                                'outputs_exact': torch.equal(expected, actual),\n                                'states_exact': torch.equal(baseline.reservoir.state, candidate.reservoir.state),\n                                'gradient_maxabs': differences,\n                                'gradients_exact': all(torch.equal(a, b) for a, b in zip(expected_grad, actual_grad)),\n                                'gradients_allclose': all(torch.allclose(a, b, atol=1e-12, rtol=1e-12) for a, b in zip(expected_grad, actual_grad))})\n                for key, method in originals.items():\n                    setattr(ParallelESNModel, key, method)\n        write(ROOT / f'gradients-{mode}.json', records)\n\n\ndef attribution(rd, torch, threads):\n    import cProfile\n    import pstats\n    case = CASES[-1]\n    with threads.single_thread_policy() as policy:\n        artifact = loaded(case, torch)\n        profiler = cProfile.Profile()\n        profiler.enable()\n        one_workflow(artifact['model'], artifact['observations'], case, threads)\n        profiler.disable()\n        profiler.dump_stats(str(ROOT / 'attribution.prof'))\n        with (ROOT / 'attribution.txt').open('w') as handle:\n            pstats.Stats(profiler, stream=handle).sort_stats('cumulative').print_stats(65)\n        fitted = copy.deepcopy(artifact['model'])\n        with torch.profiler.profile(activities=[torch.profiler.ProfilerActivity.CPU], record_shapes=True) as profile:\n            fitted.fit(artifact['observations'])\n            fitted.forecast(history=artifact['observations'][:, -100:], horizon=129)\n        (ROOT / 'torch-attribution.txt').write_text(profile.key_averages().table(sort_by='self_cpu_time_total', row_limit=35))\n        raw = []\n        for intraop in (1, 4):\n            torch.set_num_threads(intraop)\n            for patches in (8, 64):\n                c = next(item for item in CASES if item['batch'] == 1 and item['patches'] == patches)\n                model = copy.deepcopy(loaded(c, torch)['model'].graph)\n                cur = torch.zeros(1, 1, patches * 4, dtype=torch.float64)\n                with torch.no_grad():\n                    for _ in range(5):\n                        model.reservoir(model.window(cur))\n                    times = []\n                    for _ in range(7):\n                        started = time.perf_counter()\n                        for _ in range(50):\n                            model.reservoir(model.window(cur))\n                        times.append((time.perf_counter() - started) / 50)\n                raw.append({'patches': patches, 'torch_intraop': intraop, 'per_step_seconds': times})\n        torch.set_num_threads(1)\n        write(ROOT / 'scaling.json', {'cases': raw, 'native_policy': policy,\n                                     'four_thread_scope': 'Torch intra-op changed to4; native BLAS remains explicitly single-threaded. Arithmetic scales8x; no required latency ratio asserted.'})\n\n\ndef summarize():\n    result = {'comparisons': {}}\n    for mode in MODES[1:]:\n        # Every candidate has its own fresh-process ABBA block in each round.\n        pairs = []\n        for round_index in range(2):\n            rows = [json.loads((ROOT / f'{mode}-r{round_index}-s{slot}.json').read_text()) for slot in range(4)]\n            for case_index, case in enumerate(CASES):\n                baseline = [rows[slot]['cases'][case_index]['repeats'][rep]\n                            for slot in (0, 3) for rep in (1, 2)]\n                candidate = [rows[slot]['cases'][case_index]['repeats'][rep]\n                             for slot in (1, 2) for rep in (1, 2)]\n                baseline_hash = baseline[0]['hashes']\n                if any(row['hashes'] != baseline_hash for row in baseline + candidate):\n                    raise RuntimeError(f\"Workflow exactness mismatch: {mode} / {case['id']}\")\n                pairs.append({'round': round_index, 'case': case['id'], 'exact_hashes': True,\n                              **{key: {'baseline_seconds': statistics.median(row[key] for row in baseline),\n                                       'candidate_seconds': statistics.median(row[key] for row in candidate),\n                                       'speedup': statistics.median(row[key] for row in baseline) / statistics.median(row[key] for row in candidate)}\n                                 for key in ('fit_seconds', 'history_forecast_seconds')}})\n        result['comparisons'][mode] = pairs\n    write(ROOT / 'summary.json', result)\n    print(json.dumps(result, indent=2), flush=True)\n\n\ndef orchestrate():\n    environment = os.environ | {key: '1' for key in ('VECLIB_MAXIMUM_THREADS', 'OPENBLAS_NUM_THREADS',\n                                                    'MKL_NUM_THREADS', 'OMP_NUM_THREADS', 'BLIS_NUM_THREADS')}\n    def run(*arguments):\n        subprocess.run([str(PYTHON), str(Path(__file__).resolve()), *arguments], check=True,\n                       env=environment, cwd=ROOT)\n    if not (ROOT / 'artifacts.json').exists():\n        run('--prepare')\n    if not (ROOT / 'scaling.json').exists():\n        run('--attribution')\n    for mode in MODES[1:]:\n        run('--gradients', mode)\n        for round_index in range(2):\n            for slot, candidate in enumerate(('baseline', mode, mode, 'baseline')):\n                run('--worker', candidate, '--output', f'{mode}-r{round_index}-s{slot}')\n            print(f'Completed {mode} round{round_index}', flush=True)\n    summarize()\n\n\ndef main():\n    parser = argparse.ArgumentParser()\n    parser.add_argument('--freeze', action='store_true')\n    parser.add_argument('--run', action='store_true')\n    parser.add_argument('--prepare', action='store_true')\n    parser.add_argument('--attribution', action='store_true')\n    parser.add_argument('--worker', choices=MODES)\n    parser.add_argument('--gradients', choices=MODES)\n    parser.add_argument('--output')\n    parser.add_argument('--summarize', action='store_true')\n    args = parser.parse_args()\n    if args.freeze:\n        return freeze()\n    if args.run:\n        return orchestrate()\n    if args.summarize:\n        return summarize()\n    _, rd, torch, threads = load_runtime()\n    if args.prepare:\n        prepare(rd, torch, threads)\n    elif args.attribution:\n        attribution(rd, torch, threads)\n    elif args.gradients:\n        gradients(args.gradients, rd, torch, threads)\n    elif args.worker and args.output:\n        worker(args.worker, args.output, rd, torch, threads)\n    else:\n        parser.error('Choose a mode')\n\n\nif __name__ == '__main__':\n    main()\n"
    },
    "public_replay.py": {
      "sha256": "1ce92ee11952ff242d98bdf93a9975ad7e9dee6049554c882cc7c1cc1d2016c8",
      "source": "\"\"\"Extract from the public JSON and run against a local checkout, without private files.\n\npython public_replay.py REPORT.json --repository CHECKOUT --output NEW_DIRECTORY\nDependencies must match the report; fixture tensor fingerprints fail closed.\nThe measurement process owns the CPU exclusively while this command runs.\n\"\"\"\nfrom __future__ import annotations\n\nimport argparse\nimport hashlib\nimport importlib.util\nimport io\nimport json\nimport os\nfrom pathlib import Path\nimport shutil\nimport subprocess\nimport sys\nimport tarfile\n\n\ndef sha(value):\n    return hashlib.sha256(value).hexdigest()\n\n\ndef write_json(path, value):\n    path.write_text(json.dumps(value, indent=2, sort_keys=True) + '\\n')\n\n\ndef module_from(path, name):\n    spec = importlib.util.spec_from_file_location(name, path)\n    module = importlib.util.module_from_spec(spec)\n    sys.modules[name] = module\n    spec.loader.exec_module(module)\n    return module\n\n\ndef verify_source(report, output, variant):\n    source = output / 'final' / f'{variant}-source'\n    for name, expected in report['protocol']['source_files'][variant].items():\n        if sha((source / name).read_bytes()) != expected:\n            raise RuntimeError(f'Source mismatch: {variant}/{name}')\n    return source\n\n\ndef extract(report, repository, output):\n    output.mkdir(parents=True, exist_ok=False)\n    for name, entry in report['scripts'].items():\n        content = entry['source'].encode()\n        if sha(content) != entry['sha256']:\n            raise RuntimeError(f'Embedded script changed: {name}')\n        (output / name).write_bytes(content)\n    archive = subprocess.check_output(\n        ['git', 'archive', report['protocol']['git_head'], 'src', 'benchmarks'], cwd=repository\n    )\n    candidate = output / 'final' / 'candidate-source'\n    candidate.mkdir(parents=True)\n    with tarfile.open(fileobj=io.BytesIO(archive)) as handle:\n        members = handle.getmembers()\n        if any(Path(item.name).is_absolute() or '..' in Path(item.name).parts\n               or not (item.isfile() or item.isdir()) for item in members):\n            raise RuntimeError('Git archive contained a non-file/directory path')\n        handle.extractall(candidate, members=members)\n    shutil.copytree(candidate, output / 'final' / 'baseline-source')\n    for variant, overrides in report['source_overrides'].items():\n        for name, entry in overrides.items():\n            content = entry['source'].encode()\n            if sha(content) != entry['sha256']:\n                raise RuntimeError('Embedded source changed')\n            (output / 'final' / f'{variant}-source' / name).write_bytes(content)\n        verify_source(report, output, variant)\n    write_json(output / 'public-report.json', report)\n\n\ndef configure(output, repository):\n    probe = module_from(output / 'probe.py', 'probe')\n    probe.ROOT, probe.REPO, probe.PYTHON = output, repository, Path(sys.executable)\n    final = module_from(output / 'final_compare.py', 'final_compare')\n    final.ROOT, final.FINAL = output, output / 'final'\n    return probe, final\n\n\ndef prepare(report, output, repository):\n    source = verify_source(report, output, 'candidate')\n    sys.path[:0] = [str(source / 'src'), str(source)]\n    from benchmarks.rc_bench import _threads\n    _threads.bootstrap_cli()\n    import resdag as rd\n    import torch\n    if not Path(rd.__file__).resolve().is_relative_to(source):\n        raise RuntimeError('ResDAG imported outside frozen source')\n    probe, _ = configure(output, repository)\n    probe.prepare(rd, torch, _threads)\n    generated = json.loads((output / 'artifacts.json').read_text())['cases']\n    for key, expected in report['fixture_fingerprints'].items():\n        for field in ('initial', 'data'):\n            if generated[key][field] != expected[field]:\n                raise RuntimeError(\n                    f'Fixture {key}/{field} did not reproduce recorded tensors. '\n                    'Use the reported stack; no timing claim is valid for mismatched weights/data.'\n                )\n    protocol = dict(report['protocol'])\n    protocol['artifacts_sha256'] = sha((output / 'artifacts.json').read_bytes())\n    protocol['replay_of_public_protocol_sha256'] = report['protocol_sha256']\n    write_json(output / 'final' / 'protocol.json', protocol)\n\n\ndef main():\n    parser = argparse.ArgumentParser(description=__doc__)\n    parser.add_argument('report', type=Path)\n    parser.add_argument('--repository', type=Path, required=True)\n    parser.add_argument('--output', type=Path, required=True)\n    parser.add_argument('--stage', choices=('run', 'prepare', 'worker'), default='run')\n    parser.add_argument('--variant', choices=('baseline', 'candidate'))\n    parser.add_argument('--label')\n    args = parser.parse_args()\n    report = json.loads(args.report.read_text())\n    output, repository = args.output.resolve(), args.repository.resolve()\n    if args.stage == 'prepare':\n        return prepare(report, output, repository)\n    if args.stage == 'worker':\n        _, final = configure(output, repository)\n        return final.worker(args.variant, args.label)\n    extract(report, repository, output)\n    environment = os.environ | {name: '1' for name in (\n        'VECLIB_MAXIMUM_THREADS', 'OPENBLAS_NUM_THREADS', 'MKL_NUM_THREADS',\n        'OMP_NUM_THREADS', 'BLIS_NUM_THREADS',\n    )}\n    command = [sys.executable, str(Path(__file__).resolve()), str(args.report.resolve()),\n               '--repository', str(repository), '--output', str(output)]\n    subprocess.run(command + ['--stage', 'prepare'], env=environment, check=True)\n    for round_index in range(2):\n        for slot, variant in enumerate(('baseline', 'candidate', 'candidate', 'baseline')):\n            subprocess.run(command + ['--stage', 'worker', '--variant', variant,\n                           '--label', f'final-r{round_index}-s{slot}'], env=environment, check=True)\n    _, final = configure(output, repository)\n    final.summarize()\n    for round_index in range(2):\n        for slot in range(4):\n            receipt = json.loads((output / f'final-r{round_index}-s{slot}.json').read_text())\n            for case in receipt['cases']:\n                expected = report['exactness'][case['case']['id']]['hashes']\n                if any(repeat['hashes'] != expected for repeat in case['repeats']):\n                    raise RuntimeError('Replay numerical hashes differ from the published measurement')\n\n\nif __name__ == '__main__':\n    main()\n"
    }
  },
  "source_overrides": {
    "baseline": {
      "src/resdag/core/workflow.py": {
        "sha256": "0abe2d4def3d4582f79b5d5d4f0f846f0e9ac6803a0cd834e338b8d379781ff5",
        "source": "\"\"\"Named functional models with a fitted, standard PyTorch workflow.\n\nThe existing symbolic, parallel and coupled model families share this workflow.\nAlgebraic symbolic fitting requires one distinct terminal readout per output.\n\"\"\"\n\nfrom __future__ import annotations\n\nimport copy\nimport operator\nfrom collections.abc import Mapping, Sequence\nfrom pathlib import Path\nfrom typing import TYPE_CHECKING, Any, Literal, cast\n\nimport torch\nfrom pytorch_symbolic.symbolic_data import SymbolicData\nfrom torch import nn\n\nfrom resdag._contracts import module_reference, validate_sequence_inputs\nfrom resdag.core._execution import ModelOutput, ReservoirStates\nfrom resdag.core._feedback import (\n    Feedback,\n    FeedbackPlan,\n    FeedbackRoute,\n    feedback_plan,\n    feedback_rollout,\n    feedback_specs,\n    prediction_leads,\n)\nfrom resdag.core._forecast import positive_step_count\nfrom resdag.core._forecast_capabilities import (\n    ForecastSequenceExecutor,\n    validate_forecast_execution,\n)\nfrom resdag.core._modes import evaluating\nfrom resdag.core._preprocessing import FittedNormalization\nfrom resdag.core._workflow_backends import recurrent_graph, workflow_backend\nfrom resdag.core._workflow_transforms import (\n    apply_transform,\n    checkpoint_transform,\n    commit_transform_state,\n    stage_transform,\n    transform_schema,\n    validate_custom_transform,\n    validate_transform_ownership,\n)\nfrom resdag.core.model import ESNModel\nfrom resdag.data._trajectory import (\n    is_trajectory,\n    trajectory_type,\n    validate_resampling_options,\n)\nfrom resdag.data._trajectory_ports import (\n    forecast_trajectory_ports,\n    has_trajectory_port,\n    prepare_trajectory_port_drivers,\n    prepare_trajectory_port_history,\n    prepare_trajectory_ports,\n    trajectory_port_forecast_times,\n    validate_trajectory_ports_context,\n)\nfrom resdag.data.prepare import NormMethod\nfrom resdag.layers.readouts import AutoReadoutLayer, LSMRReadoutLayer\nfrom resdag.layers.reservoirs import BaseReservoirLayer\n\nif TYPE_CHECKING:\n    from tsdynamics.data import Trajectory\n\n\nStreams = torch.Tensor | Mapping[str, torch.Tensor]\nWorkflowOutput = torch.Tensor | dict[str, torch.Tensor]\nPreprocessing = NormMethod | Literal[\"off\"] | None\n\n\ndef _port_names(names: Sequence[str], count: int, label: str) -> tuple[str, ...]:\n    if isinstance(names, str):\n        raise TypeError(f\"{label} must be a sequence of names, not a string\")\n    result = tuple(names)\n    if len(result) != count or any(not isinstance(name, str) or not name for name in result):\n        raise ValueError(f\"{label} must contain {count} non-empty string names\")\n    if len(set(result)) != len(result):\n        raise ValueError(f\"{label} must contain distinct names\")\n    return tuple(str(name) for name in result)\n\n\ndef _washout(value: int) -> int:\n    try:\n        count = operator.index(value)\n    except TypeError:\n        raise ValueError(\"washout must be a non-negative integer\") from None\n    if isinstance(value, bool) or count < 0:\n        raise ValueError(\"washout must be a non-negative integer\")\n    return count\n\n\nclass Model(nn.Module):\n    \"\"\"Wrap a named functional DAG in a common training/prediction workflow.\n\n    Supply ``inputs={name: symbolic_input}`` and ``outputs={name: symbolic_output}``,\n    or ``graph=existing_model`` with optional ordered ``input_names`` and\n    ``output_names``. The graph is registered once as :attr:`graph`; it remains\n    available for raw, already-normalized tensor execution. Existing symbolic,\n    parallel local-state and coupled ensemble backends are supported. Parallel\n    ports describe the full field; coupled members share one aggregate output.\n    Coupled fitting trains member readouts only. A custom feed-forward aggregator\n    is supplied/configured by the user and can be optimized separately with\n    ordinary PyTorch. Reservoirs hidden inside an aggregator require ordinary\n    stateful forward rather than explicit-state execution or forecasting.\n\n    ``fit(series)`` learns future prediction for one input/output of equal\n    width. ``fit(inputs, targets={output_name: tensor})`` instead fits explicit,\n    time-aligned targets; all streams include the same washout prefix. Declared intermediate heads may feed\n    later reservoirs; ``readout_targets`` supervises internal fitted heads\n    without adding them to public outputs.\n\n    ``forward`` accepts floating Torch tensors, preserves 2-D/3-D layout and\n    gradients, applies fitted scaling and returns original units. Calls carry\n    recurrent state by default; call :meth:`reset_state` between unrelated\n    sequences. One head returns a Tensor; several return a named dictionary.\n\n    Preprocessing is ``\"standard\"`` by default, any existing normalization\n    method, or ``\"off\"``/``None``. Statistics use training inputs/targets after\n    washout only. Implicit targets share their input's statistics. Feedback\n    automatically converts each output back to original units before applying\n    its destination input's scaling.\n\n    ``prediction_lead`` declares the physical target distance for each head:\n    input at step ``t`` predicts target at ``t + lead``. The default is one;\n    a mapping overrides named heads. ``feedback`` supplies explicit\n    :class:`Feedback` connections with independent graph-step delays. Without\n    connections, the first output automatically feeds the first input after\n    its prediction lead. An empty sequence leaves all inputs externally driven.\n\n    ``state_dict`` includes scaling, ordered port metadata and the observed tail;\n    reconstruct the same DAG before loading. ``tune`` compares candidates and\n    installs a refitted winner; its report exposes the Optuna study. Complete\n    ``save(\"run.pt\")`` and ``rd.load`` preserve the complete model; diagram\n    suffixes export its declared structure without running it.\n\n    With the optional ``dynamics`` extra, bare or named TSDynamics trajectories\n    use one shared observed clock. Explicit targets are aligned to each head's\n    physical prediction lead. Forecasts return one trajectory or a named\n    dictionary, with target component names and shared future times.\n    ``return_type=\"tensor\"`` keeps predictions on the model device.\n    Ordinary ``forward`` always uses Torch tensors.\n    Uneven timestamps are automatically interpolated with ``resample_method``\n    (linear, PCHIP or cubic); ``resample_dt`` controls the physical step.\n    \"\"\"\n\n    _fitted: torch.Tensor\n    _trajectory_system: tuple[Any, ...] | None\n\n    def __init__(\n        self,\n        *,\n        inputs: Mapping[str, SymbolicData] | None = None,\n        outputs: Mapping[str, SymbolicData] | None = None,\n        graph: nn.Module | None = None,\n        input_names: Sequence[str] | None = None,\n        output_names: Sequence[str] | None = None,\n        washout: int = 100,\n        preprocessing: Preprocessing = \"standard\",\n        input_transforms: Mapping[str, nn.Module] | None = None,\n        output_transforms: Mapping[str, nn.Module] | None = None,\n        prediction_lead: int | Mapping[str, int] = 1,\n        feedback: Sequence[Feedback] | None = None,\n        resample_dt: float | None = None,\n        resample_method: Literal[\"linear\", \"pchip\", \"cubic\"] = \"linear\",\n    ) -> None:\n        super().__init__()\n        self.washout = _washout(washout)\n        self.resample_dt, self.resample_method = validate_resampling_options(\n            resample_dt, resample_method\n        )\n        self._trajectory_context: dict[str, Any] | None = None\n        object.__setattr__(self, \"_trajectory_system\", None)\n        if preprocessing not in (\n            None,\n            \"off\",\n            \"minmax\",\n            \"standard\",\n            \"noncentered\",\n            \"meanpreserving\",\n        ):\n            raise ValueError(\"preprocessing must be a known normalization method, 'off', or None\")\n        self._preprocessing = None if preprocessing in (None, \"off\") else preprocessing\n        if graph is not None:\n            if inputs is not None or outputs is not None:\n                raise ValueError(\"Supply graph= or named symbolic inputs/outputs, not both\")\n            backend = workflow_backend(graph)\n            interface = backend.describe(graph)\n            in_names = (\n                input_names\n                if input_names is not None\n                else tuple(\n                    \"input\" if len(interface.input_widths) == 1 else f\"input_{i}\"\n                    for i in range(len(interface.input_widths))\n                )\n            )\n            out_names = (\n                output_names\n                if output_names is not None\n                else tuple(\n                    \"output\" if len(interface.output_widths) == 1 else f\"output_{i}\"\n                    for i in range(len(interface.output_widths))\n                )\n            )\n        else:\n            if input_names is not None or output_names is not None:\n                raise ValueError(\"input_names/output_names belong to the graph= constructor\")\n            if (\n                not isinstance(inputs, Mapping)\n                or not inputs\n                or not isinstance(outputs, Mapping)\n                or not outputs\n            ):\n                raise ValueError(\"Provide non-empty named symbolic inputs and outputs, or graph=\")\n            if not all(\n                isinstance(node, SymbolicData) for node in (*inputs.values(), *outputs.values())\n            ):\n                raise TypeError(\"inputs and outputs must map names to symbolic graph nodes\")\n            in_names, out_names = tuple(inputs), tuple(outputs)\n            _port_names(in_names, len(inputs), \"inputs\")\n            _port_names(out_names, len(outputs), \"outputs\")\n            graph = ESNModel(tuple(inputs.values()), tuple(outputs.values()))\n            backend = workflow_backend(graph)\n            interface = backend.describe(graph)\n        self.input_names = _port_names(in_names, len(interface.input_widths), \"input_names\")\n        self.output_names = _port_names(out_names, len(interface.output_widths), \"output_names\")\n        self.graph = graph\n        self._backend = backend\n        self._backend_interface_schema = interface.schema\n        self._backend_schema = backend.checkpoint_schema(graph, interface)\n        self._backend_references = interface.references\n        self._input_widths = interface.input_widths\n        self._output_widths = interface.output_widths\n        self._prediction_leads = prediction_leads(prediction_lead, self.output_names)\n        self._feedback = feedback_specs(feedback)\n        self._feedback_plan(validate_widths=self._feedback is not None)\n        method = cast(NormMethod, self._preprocessing or \"standard\")\n        overrides = []\n        for mapping, names in (\n            (input_transforms, self.input_names),\n            (output_transforms, self.output_names),\n        ):\n            if mapping is not None and (\n                not isinstance(mapping, Mapping) or set(mapping) - set(names)\n            ):\n                raise ValueError(\n                    f\"Transform override keys must be declared port names: {list(names)}\"\n                )\n            overrides.append(dict(mapping or {}))\n        self._custom_inputs = tuple(name in overrides[0] for name in self.input_names)\n        self._custom_outputs = tuple(name in overrides[1] for name in self.output_names)\n        originals = tuple(module for mapping in overrides for module in mapping.values())\n        if any(not isinstance(module, nn.Module) for module in originals):\n            raise TypeError(\"Transform overrides must be torch.nn.Module instances\")\n        validate_transform_ownership(graph, originals)\n        for mapping, names, widths in (\n            (overrides[0], self.input_names, self._input_widths),\n            (overrides[1], self.output_names, self._output_widths),\n        ):\n            for name, width in zip(names, widths):\n                if name in mapping:\n                    validate_custom_transform(mapping[name], width)\n        self.input_scalers = nn.ModuleList(\n            overrides[0].get(name, FittedNormalization(method)) for name in self.input_names\n        )\n        self.output_scalers = nn.ModuleList(\n            overrides[1].get(name, FittedNormalization(method)) for name in self.output_names\n        )\n        reference = module_reference(graph)\n        if reference is not None:\n            self.input_scalers.to(device=reference.device, dtype=reference.dtype)\n            self.output_scalers.to(device=reference.device, dtype=reference.dtype)\n        self._transform_schema = self._custom_transform_schema()\n        for group, masks, widths in (\n            (\"input\", self._custom_inputs, self._input_widths),\n            (\"output\", self._custom_outputs, self._output_widths),\n        ):\n            for index, (custom, width) in enumerate(zip(masks, widths)):\n                if custom:\n                    with torch.inference_mode(False):\n                        sample = (\n                            torch.zeros(1, 3, width)\n                            if reference is None\n                            else reference.new_zeros(1, 3, width)\n                        )\n                    self.register_buffer(f\"_{group}_transform_sample_{index}\", sample)\n        for index, width in enumerate(self._input_widths):\n            empty = torch.empty(0, width) if reference is None else reference.new_empty(0, width)\n            self.register_buffer(f\"_history_{index}\", empty)\n        self.register_buffer(\n            \"_fitted\", torch.tensor(False, device=None if reference is None else reference.device)\n        )\n        self._fitted_flag = False\n        self.register_load_state_dict_post_hook(self._synchronize_loaded_buffers)\n\n    def _synchronize_loaded_buffers(self, module: nn.Module, incompatible_keys: Any) -> None:\n        # PyTorch shares this key list across the whole loading tree. Missing\n        # sibling keys under strict=False do not prevent this graph's tensors\n        # from being assigned and must not skip its derived-buffer repair.\n        self._backend.synchronize_loaded_buffers(self.graph)\n\n    @property\n    def preprocessing(self) -> NormMethod | None:\n        \"\"\"The fallback policy; explicit transform overrides apply independently.\"\"\"\n        # Keep typing-only unions out of the captured forward graph.\n        return cast(\"NormMethod | None\", self._preprocessing)\n\n    def _custom_transform_schema(self) -> tuple[Any, ...]:\n        return tuple(\n            tuple(\n                transform_schema(module, width) if custom else None\n                for module, custom, width in zip(modules, masks, widths)\n            )\n            for modules, masks, widths in (\n                (self.input_scalers, self._custom_inputs, self._input_widths),\n                (self.output_scalers, self._custom_outputs, self._output_widths),\n            )\n        )\n\n    def _transform_active(self, *, output: bool, index: int) -> bool:\n        return (\n            self.preprocessing is not None\n            or (self._custom_outputs if output else self._custom_inputs)[index]\n        )\n\n    def _validate_transform_ownership(self) -> None:\n        validate_transform_ownership(\n            self.graph,\n            tuple(\n                module\n                for modules, masks in (\n                    (self.input_scalers, self._custom_inputs),\n                    (self.output_scalers, self._custom_outputs),\n                )\n                for module, custom in zip(modules, masks)\n                if custom\n            ),\n        )\n\n    @property\n    def is_fitted(self) -> bool:\n        \"\"\"Whether this workflow has completed fitting or restored a fitted checkpoint.\"\"\"\n        return self._fitted_flag\n\n    @property\n    def prediction_leads(self) -> dict[str, int]:\n        \"\"\"Physical target distances by public output name.\"\"\"\n        return dict(zip(self.output_names, self._prediction_leads))\n\n    @property\n    def feedback(self) -> tuple[Feedback, ...] | None:\n        \"\"\"Explicit connections, or ``None`` for the automatic first-port route.\"\"\"\n        return self._feedback\n\n    def _feedback_plan(self, *, validate_widths: bool = True) -> FeedbackPlan:\n        return feedback_plan(\n            self._feedback,\n            self._prediction_leads,\n            self.input_names,\n            self.output_names,\n            self._input_widths,\n            self._output_widths,\n            validate_widths=validate_widths,\n        )\n\n    @property\n    def internal_readout_names(self) -> tuple[str, ...]:\n        \"\"\"Target keys for internal fitted heads, without exposing extra predictions.\"\"\"\n        self._validate_ports()\n        self._backend.validate_fit(self.graph)\n        return tuple(name for name, _ in self._backend.internal_readouts(self.graph))\n\n    def _requires_complete_history(self) -> bool:\n        if self._backend.kind == \"parallel\":\n            return False\n        try:\n            validate_forecast_execution(self.graph, \"fast\")\n        except ValueError:\n            return True\n        return False\n\n    def _commit_forecast_states(self, states: ReservoirStates) -> None:\n        \"\"\"Store evolved state without turning it into a user-pinned restore.\"\"\"\n        reservoirs = {\n            name: layer\n            for name, layer in self.graph.named_modules()\n            if isinstance(layer, BaseReservoirLayer)\n        }\n        if set(states) != set(reservoirs):\n            raise RuntimeError(\"Forecast executor returned an inconsistent reservoir state schema\")\n        staged = {}\n        with torch.inference_mode(False), torch.no_grad():\n            for name, layer in reservoirs.items():\n                layer.cell.validate_state(states[name])\n                staged[name] = states[name].detach().clone()\n        for name, layer in reservoirs.items():\n            layer.reset_state()\n            layer.state = staged[name]\n\n    def _streams(\n        self,\n        data: Streams,\n        names: tuple[str, ...],\n        widths: tuple[int, ...],\n        label: str,\n        *,\n        finite: bool = False,\n        allow_empty: bool = False,\n    ) -> tuple[tuple[torch.Tensor, ...], bool]:\n        values: tuple[torch.Tensor, ...]\n        if isinstance(data, torch.Tensor):\n            if len(names) != 1:\n                raise ValueError(f\"{label} requires a mapping with keys {list(names)}\")\n            values = (data,)\n        elif isinstance(data, Mapping):\n            if set(data) != set(names):\n                raise ValueError(f\"{label} keys must be {list(names)}; got {list(data)}\")\n            values = tuple(data[name] for name in names)\n        else:\n            raise TypeError(f\"{label} must be a torch.Tensor or a named tensor mapping\")\n        if not all(isinstance(value, torch.Tensor) for value in values):\n            raise TypeError(f\"{label} values must be torch.Tensor instances\")\n        two_dimensional = values[0].ndim == 2\n        if any(value.ndim != values[0].ndim for value in values):\n            raise ValueError(f\"{label} streams must use the same 2-D or 3-D layout\")\n        canonical = tuple(value.unsqueeze(0) if two_dimensional else value for value in values)\n        validate_sequence_inputs(\n            canonical,\n            feature_sizes=widths,\n            reference=module_reference(self.graph),\n            label=label,\n            allow_empty=allow_empty,\n        )\n        if finite and any(not bool(torch.isfinite(value).all()) for value in canonical):\n            raise ValueError(f\"{label} must contain only finite values\")\n        return canonical, two_dimensional\n\n    def _require_scaling(self) -> None:\n        self._validate_ports()\n        if (\n            self.preprocessing is not None or any((*self._custom_inputs, *self._custom_outputs))\n        ) and not self.is_fitted:\n            raise RuntimeError(\"Model preprocessing is not fitted; call fit(training) first\")\n\n    def _validate_ports(self) -> None:\n        if self._custom_transform_schema() != self._transform_schema:\n            raise ValueError(\n                \"Custom transform registered structure changed; construct a matching Model\"\n            )\n        try:\n            interface = self._backend.describe(self.graph)\n            valid = (\n                interface.input_widths == self._input_widths\n                and interface.output_widths == self._output_widths\n                and interface.schema == self._backend_interface_schema\n                and len(interface.references) == len(self._backend_references)\n                and all(a is b for a, b in zip(interface.references, self._backend_references))\n            )\n        except (ValueError, TypeError, AttributeError):\n            valid = False\n        if not valid:\n            raise ValueError(\n                \"The raw graph's input/output ports changed; construct a new Model \"\n                \"with the updated named ports and backend structure before executing it\"\n            )\n\n    def _scaled_inputs(self, inputs: tuple[torch.Tensor, ...]) -> tuple[torch.Tensor, ...]:\n        return tuple(\n            (\n                apply_transform(scaler, value)\n                if self._transform_active(output=False, index=index)\n                else value\n            )\n            for index, (scaler, value) in enumerate(zip(self.input_scalers, inputs))\n        )\n\n    def _outputs(self, output: ModelOutput, two_dimensional: bool) -> WorkflowOutput:\n        values = output if isinstance(output, tuple) else (output,)\n        if len(values) != len(self.output_names):\n            raise RuntimeError(\"Graph output count no longer matches the declared named outputs\")\n        restored: list[torch.Tensor] = []\n        for scaler, value in zip(self.output_scalers, values):\n            value = (\n                apply_transform(scaler, value, inverse=True)\n                if self._transform_active(output=True, index=len(restored))\n                else value\n            )\n            restored.append(value.squeeze(0) if two_dimensional else value)\n        return restored[0] if len(restored) == 1 else dict(zip(self.output_names, restored))\n\n    def forward(self, inputs: Streams) -> WorkflowOutput:\n        \"\"\"Predict in original units, retaining gradients and carried recurrent state.\"\"\"\n        self._require_scaling()\n        values, was_2d = self._streams(inputs, self.input_names, self._input_widths, \"inputs\")\n        return self._outputs(self.graph(*self._scaled_inputs(values)), was_2d)\n\n    def forward_stateless(\n        self,\n        inputs: Streams,\n        *,\n        states: Mapping[str, torch.Tensor] | None = None,\n        compile: bool = False,\n    ) -> tuple[WorkflowOutput, ReservoirStates]:\n        \"\"\"Predict original units with caller-managed recurrent states and gradients.\"\"\"\n        self._require_scaling()\n        self._backend.validate_stateless(self.graph)\n        from resdag.core._hooks import call_with_states, has_execution_hooks, state_paths\n\n        if has_execution_hooks(self):\n            return cast(\n                tuple[WorkflowOutput, ReservoirStates],\n                call_with_states(\n                    self, (inputs,), states, state_paths(self, \"graph.\"), compile=compile\n                ),\n            )\n        values, was_2d = self._streams(inputs, self.input_names, self._input_widths, \"inputs\")\n        output, final = recurrent_graph(self.graph).forward_stateless(\n            *self._scaled_inputs(values), states=states, compile=compile\n        )\n        return self._outputs(output, was_2d), final\n\n    def reset_state(self) -> None:\n        \"\"\"Start the next ordinary forward from the reservoirs' configured reset states.\"\"\"\n        recurrent_graph(self.graph).reset_reservoirs()\n\n    def get_state(self) -> ReservoirStates:\n        \"\"\"Copy reservoir states, excluding a forecast's ephemeral feedback queues.\n\n        Forecast calls replay history and construct fresh delay queues. These\n        tensors alone do not resume a delayed forecast at its previous clock.\n        \"\"\"\n        return recurrent_graph(self.graph).get_state()\n\n    def set_state(self, states: Mapping[str, torch.Tensor], strict: bool = True) -> None:\n        \"\"\"Restore ordinary-forward reservoir states, not delayed-rollout queues.\"\"\"\n        recurrent_graph(self.graph).set_state(states, strict=strict)\n\n    def plot_model(\n        self,\n        *,\n        save_path: str | Path | None = None,\n        format: str | None = None,\n        show_shapes: bool = True,\n        show_trainable: bool = False,\n        rankdir: str = \"LR\",\n    ) -> Any:\n        \"\"\"Display a DAG in notebooks or export SVG/PNG/PDF/DOT without running it.\"\"\"\n        from resdag.core._diagram import plot_model\n\n        self._validate_ports()\n        return plot_model(\n            self,\n            save_path=save_path,\n            format=format,\n            show_shapes=show_shapes,\n            show_trainable=show_trainable,\n            rankdir=rankdir,\n        )\n\n    @property\n    def save_formats(self) -> tuple[str, ...]:\n        \"\"\"Supported complete-model checkpoint and diagram suffixes.\"\"\"\n        return (\"pt\", \"pth\", \"svg\", \"png\", \"pdf\", \"dot\")\n\n    def save(\n        self,\n        path: str | Path,\n        *,\n        format: str | None = None,\n        include_state: bool = True,\n        trusted: bool = False,\n        metadata: Mapping[str, Any] | None = None,\n        **diagram_options: Any,\n    ) -> Any:\n        \"\"\"Save a complete loadable model (.pt/.pth) or a diagram by suffix.\n\n        ``rd.load(path)`` reconstructs checkpoints without a prebuilt DAG.\n        Current ordinary-forward memory is included by default. Set\n        ``trusted=True`` only to bundle notebook-defined Python code; loading\n        such a bundle also requires explicit trust. Diagram formats are\n        SVG/PNG/PDF/DOT and accept :meth:`plot_model` options.\n        \"\"\"\n        destination = Path(path)\n        suffix = destination.suffix.lower().lstrip(\".\")\n        if format is not None and not isinstance(format, str):\n            raise TypeError(\"format must be a string or None\")\n        selected = format.lower() if isinstance(format, str) else suffix or \"pt\"\n        if selected not in self.save_formats or (suffix and suffix != selected):\n            raise ValueError(f\"Save format/suffix must agree and be one of {self.save_formats}\")\n        if not suffix:\n            destination = destination.with_suffix(f\".{selected}\")\n        if selected not in (\"pt\", \"pth\"):\n            if trusted or metadata is not None or not include_state:\n                raise ValueError(\n                    \"trusted, metadata and include_state options apply to model checkpoints\"\n                )\n            return self.plot_model(save_path=destination, format=selected, **diagram_options)\n        if diagram_options:\n            raise TypeError(\n                f\"Diagram options cannot be used with a model checkpoint: {list(diagram_options)}\"\n            )\n        from resdag.artifacts import save_model\n\n        self._validate_ports()\n        return save_model(\n            self, destination, include_state=include_state, trusted=trusted, metadata=metadata\n        )\n\n    def tune(\n        self,\n        training: Streams | Trajectory | Mapping[str, Trajectory],\n        targets: Streams | Trajectory | Mapping[str, Trajectory] | None = None,\n        *,\n        preset: Literal[\"quick\", \"balanced\", \"thorough\"] = \"balanced\",\n        n_trials: int | None = None,\n        horizon: int | None = None,\n        n_jobs: int = 1,\n        **options: Any,\n    ) -> Model:\n        \"\"\"Tune autonomous forecasts, refit the winner and return this model.\n\n        Requires ``resdag[hpo]``. The final 20% is held out while comparing\n        candidates, then the winner is refitted on all supplied data. Keep a\n        separate final test set. Built-in classic/OTT graphs have an automatic\n        rebuilding recipe. ``factory(params, seed)`` rebuilds custom DAGs;\n        without one, custom sizes and weights stay fixed and alpha/washout can vary.\n        ``search_space(trial)`` uses ordinary Optuna suggestions. Advanced\n        options and :attr:`tuning_report` are documented in the tuning guide.\n        A failure leaves this model unchanged. Tune before creating optimizers.\n        \"\"\"\n        from resdag.hpo import _require_optuna\n\n        _require_optuna()\n        from resdag.hpo.tuning import tune_model\n\n        tune_model(\n            self,\n            training,\n            targets,\n            preset=preset,\n            n_trials=n_trials,\n            horizon=horizon,\n            n_jobs=n_jobs,\n            **options,\n        )\n        return self\n\n    def fit(\n        self,\n        training: Streams | Trajectory | Mapping[str, Trajectory],\n        targets: Streams | Trajectory | Mapping[str, Trajectory] | None = None,\n        *,\n        readout_targets: Mapping[str, torch.Tensor] | None = None,\n    ) -> Model:\n        \"\"\"Fit public and internal heads transactionally and retain the original observed tail.\n\n        Implicit supervision pairs input ``t`` with observation\n        ``t + prediction_lead`` and retains the complete observed tail.\n        Explicit targets are already caller-aligned to input indices; declared\n        leads describe their physical timestamps without shifting those arrays.\n        Successful fitting resets streaming state. Failed fitting leaves the\n        existing graph, fitted preprocessing and cached history unchanged.\n        Bare or named TSDynamics trajectories share one physical input grid.\n        Explicit trajectory targets are sampled at origin + prediction_lead*dt;\n        tensors remain caller-aligned. Regression uses jointly supported origins\n        after absolute washout. Target source observations after the common input\n        endpoint are held out before interpolation. The cached tail includes the\n        final observed inputs, even after the last supervised origin. Tensor\n        refitting clears trajectory defaults on success.\n\n        ``readout_targets={\"stage1\": tensor}`` supervises internal readouts\n        without exposing them as outputs. Keys use the readout's ``name`` or\n        graph path; coupled members use ``models.<index>.<name>``. Tensors share\n        the complete input time axis, including washout, and express the desired\n        internal output units without automatic output scaling. For trajectory\n        inputs, align these tensors to the prepared shared input grid.\n        \"\"\"\n        self._validate_ports()\n        implicit = targets is None\n        if is_trajectory(training) or has_trajectory_port(training):\n            prepared = prepare_trajectory_ports(\n                training,\n                input_names=self.input_names,\n                input_widths=self._input_widths,\n                output_names=self.output_names,\n                output_widths=self._output_widths,\n                prediction_leads=self._prediction_leads,\n                targets=targets,\n                dt=self.resample_dt,\n                method=self.resample_method,\n            )\n            reference = module_reference(self.graph)\n            dtype = None if reference is None else reference.dtype\n            device = None if reference is None else reference.device\n            inputs = {\n                name: torch.tensor(data, dtype=dtype, device=device)\n                for name, data in zip(self.input_names, prepared.inputs)\n            }\n            labels = {\n                name: torch.tensor(data, dtype=dtype, device=device)\n                for name, data in zip(self.output_names, prepared.targets)\n            }\n            return self._fit_prepared(\n                inputs,\n                labels,\n                supervised_start=prepared.supervised_start,\n                supervised_stop=prepared.supervised_stop,\n                implicit=implicit,\n                trajectory_context=prepared.context,\n                trajectory_system=prepared.output_systems,\n                readout_targets=readout_targets,\n            )\n        if is_trajectory(targets) or has_trajectory_port(targets):\n            raise TypeError(\n                \"Trajectory targets require clocked Trajectory training inputs; \"\n                \"Tensor targets remain caller-aligned\"\n            )\n        values, was_2d = self._streams(\n            cast(Streams, training), self.input_names, self._input_widths, \"training\", finite=True\n        )\n        stop = values[0].shape[1]\n        if implicit:\n            if (\n                len(values) != 1\n                or len(self.output_names) != 1\n                or self._input_widths != self._output_widths\n            ):\n                raise ValueError(\n                    \"Implicit fitting requires one input/output of equal width; \"\n                    \"provide explicit named targets for custom graphs\"\n                )\n            lead = self._prediction_leads[0]\n            stop -= lead\n            labels = {\n                self.output_names[0]: (\n                    values[0][:, lead:].squeeze(0) if was_2d else values[0][:, lead:]\n                )\n            }\n        else:\n            target_values, targets_2d = self._streams(\n                cast(Streams, targets),\n                self.output_names,\n                self._output_widths,\n                \"targets\",\n                finite=True,\n            )\n            if targets_2d != was_2d or any(\n                value.shape[:2] != values[0].shape[:2] for value in target_values\n            ):\n                raise ValueError(\"Explicit targets must share training batch/time axes and layout\")\n            labels = {\n                name: value.squeeze(0) if was_2d else value\n                for name, value in zip(self.output_names, target_values)\n            }\n        return self._fit_prepared(\n            cast(Streams, training),\n            labels,\n            supervised_start=0,\n            supervised_stop=stop,\n            implicit=implicit,\n            readout_targets=readout_targets,\n        )\n\n    def _fit_prepared(\n        self,\n        training: Streams,\n        targets: Streams,\n        *,\n        supervised_start: int,\n        supervised_stop: int,\n        implicit: bool = False,\n        readout_targets: Mapping[str, torch.Tensor] | None = None,\n        trajectory_context: dict[str, Any] | None = None,\n        trajectory_system: tuple[Any, ...] | None = None,\n    ) -> Model:\n        \"\"\"Fit an admitted origin window, retaining every observed input row.\n\n        Private adapters supply already aligned labels for exactly\n        ``supervised_start:supervised_stop``. Absolute washout is applied once.\n        This separates regression support from the complete observed clock;\n        purging future labels must not move the cached forecasting boundary.\n        \"\"\"\n        self._validate_ports()\n        self._backend.validate_fit(self.graph)\n        self._validate_transform_ownership()\n        complete_history = self._requires_complete_history()\n        values, was_2d = self._streams(\n            training, self.input_names, self._input_widths, \"training\", finite=True\n        )\n        if (\n            type(supervised_start) is not int\n            or type(supervised_stop) is not int\n            or not 0 <= supervised_start < supervised_stop <= values[0].shape[1]\n        ):\n            raise ValueError(\n                \"Supervised origins must be a nonempty interval within observed inputs\"\n            )\n        target_values, targets_2d = self._streams(\n            targets, self.output_names, self._output_widths, \"targets\", finite=True\n        )\n        if targets_2d != was_2d or any(\n            value.shape[:2] != (values[0].shape[0], supervised_stop - supervised_start)\n            for value in target_values\n        ):\n            raise ValueError(\"Prepared targets must match the admitted origin window and layout\")\n        internal_heads = self._backend.internal_readouts(self.graph)\n        internal_targets: dict[str, torch.Tensor] = {}\n        if internal_heads:\n            if readout_targets is None:\n                raise ValueError(\n                    \"Provide readout_targets for internal fitted readouts; \"\n                    f\"expected {[name for name, _ in internal_heads]}\"\n                )\n            internal_values, internal_2d = self._streams(\n                readout_targets,\n                tuple(name for name, _ in internal_heads),\n                tuple(head.out_features for _, head in internal_heads),\n                \"readout_targets\",\n                finite=True,\n            )\n            if internal_2d != was_2d or any(\n                value.shape[:2] != values[0].shape[:2] for value in internal_values\n            ):\n                raise ValueError(\"readout_targets must share the complete input batch/time axes\")\n            internal_targets = dict(zip((name for name, _ in internal_heads), internal_values))\n        elif readout_targets is not None and (\n            not isinstance(readout_targets, Mapping) or len(readout_targets)\n        ):\n            raise ValueError(\"This graph has no internal fitted readouts for readout_targets\")\n        fit_start = max(self.washout, supervised_start)\n        train_inputs = tuple(value[:, :supervised_stop] for value in values)\n        target_values = tuple(value[:, fit_start - supervised_start :] for value in target_values)\n        if train_inputs[0].shape[1] <= fit_start:\n            raise ValueError(\"Training must contain washout plus at least one input/target pair\")\n        fitting_inputs = tuple(value[:, fit_start:] for value in train_inputs)\n        # Stage statistics and algebraic fitting on independent objects. Committing\n        # weights into the original graph preserves existing optimizer references.\n        with torch.inference_mode(False):\n            input_scalers = [copy.deepcopy(module) for module in self.input_scalers]\n            output_scalers = [copy.deepcopy(module) for module in self.output_scalers]\n        samples: dict[str, torch.Tensor] = {}\n        for group, staged_scalers, live_scalers, masks, fitting in (\n            (\"input\", input_scalers, self.input_scalers, self._custom_inputs, fitting_inputs),\n            (\"output\", output_scalers, self.output_scalers, self._custom_outputs, target_values),\n        ):\n            for index, (staged_scaler, original, custom, data) in enumerate(\n                zip(staged_scalers, live_scalers, masks, fitting)\n            ):\n                if custom:\n                    staged_scalers[index], samples[f\"_{group}_transform_sample_{index}\"] = (\n                        stage_transform(original, data)\n                    )\n                elif self.preprocessing is not None:\n                    # Unspecified implicit outputs retain the original input\n                    # supervised window even when their input has a custom map.\n                    source = fitting_inputs[0] if group == \"output\" and implicit else data\n                    cast(FittedNormalization, staged_scaler).fit(source)\n\n        def transformed(\n            modules: list[nn.Module], streams: tuple[torch.Tensor, ...], *, output: bool\n        ) -> tuple[torch.Tensor, ...]:\n            result = []\n            for index, (module, data) in enumerate(zip(modules, streams)):\n                with evaluating(module), torch.no_grad():\n                    value = (\n                        apply_transform(module, data)\n                        if self._transform_active(output=output, index=index)\n                        else data\n                    )\n                if not bool(torch.isfinite(value).all()):\n                    raise ValueError(\"Preprocessing produced nonfinite training values\")\n                result.append(value)\n            return tuple(result)\n\n        scaled = transformed(input_scalers, train_inputs, output=False)\n        scaled_targets = transformed(output_scalers, target_values, output=True)\n        with torch.inference_mode(False), torch.no_grad():\n            # Fitting starts from reset state. Exclude only transient carried\n            # states, which may retain non-leaf autograd history and therefore\n            # cannot be deep-copied. The live graph remains untouched if the\n            # staged fit fails, including its still-differentiable states.\n            transient_states = {\n                id(layer.state): None\n                for layer in self.graph.modules()\n                if isinstance(layer, BaseReservoirLayer) and layer.state is not None\n            }\n            candidate = copy.deepcopy(self.graph, transient_states)\n            self._backend.fit_prefix(\n                candidate,\n                scaled,\n                scaled_targets,\n                fit_start=fit_start,\n                readout_targets={\n                    name: value[:, fit_start:supervised_stop]\n                    for name, value in internal_targets.items()\n                },\n            )\n        history = []\n        tail_length = self.washout + self._feedback_plan(validate_widths=False).required_history\n        with torch.inference_mode(False), torch.no_grad():\n            for value in values:\n                tail = (value if complete_history else value[:, -tail_length:]).detach().clone()\n                history.append(tail.squeeze(0) if was_2d else tail)\n        # Solve reports are intentionally not checkpoint state. Transfer them\n        # from the successful staged fit by graph path without replacing live\n        # readouts/parameters, or losing diagnostics at the state-dict commit.\n        staged_reports: dict[str, Any] = {\n            path: layer.last_solve\n            for path, layer in candidate.named_modules()\n            if isinstance(layer, (AutoReadoutLayer, LSMRReadoutLayer))\n        }\n        live_solve_readouts = {\n            path: layer\n            for path, layer in self.graph.named_modules()\n            if isinstance(layer, (AutoReadoutLayer, LSMRReadoutLayer))\n        }\n        if staged_reports.keys() != live_solve_readouts.keys():\n            raise RuntimeError(\"Staged readout diagnostic paths do not match the live graph\")\n        with torch.inference_mode(False):\n            self.graph.load_state_dict(candidate.state_dict())\n        recurrent_graph(self.graph).reset_reservoirs()\n        for staged_scalers, previous, masks in (\n            (input_scalers, self.input_scalers, self._custom_inputs),\n            (output_scalers, self.output_scalers, self._custom_outputs),\n        ):\n            for staged_scaler, original, custom in zip(staged_scalers, previous, masks):\n                if custom:\n                    commit_transform_state(original, staged_scaler)\n                else:\n                    with torch.inference_mode(False):\n                        original.load_state_dict(staged_scaler.state_dict())\n        for name, sample in samples.items():\n            setattr(self, name, sample)\n        for index, tail in enumerate(history):\n            setattr(self, f\"_history_{index}\", tail)\n        self._fitted_flag = True\n        with torch.inference_mode(False):\n            self._fitted = torch.ones((), dtype=torch.bool, device=values[0].device)\n        self._trajectory_context = trajectory_context\n        object.__setattr__(self, \"_trajectory_system\", trajectory_system)\n        for path, layer in live_solve_readouts.items():\n            layer.last_solve = staged_reports[path]\n        return self\n\n    def _feedback_scaling_matches(self, input_index: int = 0, output_index: int = 0) -> bool:\n        if any((*self._custom_inputs, *self._custom_outputs)):\n            return False\n        if self.preprocessing is None:\n            return True\n        left, right = cast(FittedNormalization, self.input_scalers[input_index]), cast(\n            FittedNormalization, self.output_scalers[output_index]\n        )\n        return left.method == right.method and all(\n            torch.equal(a, b) for a, b in zip(left.buffers(), right.buffers())\n        )\n\n    def forecast(\n        self,\n        history: Streams | Trajectory | Mapping[str, Trajectory] | None = None,\n        *,\n        horizon: int,\n        future_inputs: Streams | Trajectory | Mapping[str, Trajectory] | None = None,\n        return_warmup: bool = False,\n        compile: bool = False,\n        execution: Literal[\"fast\", \"history\"] = \"fast\",\n        return_type: Literal[\"auto\", \"tensor\", \"trajectory\"] = \"auto\",\n    ) -> WorkflowOutput | Trajectory | dict[str, Trajectory]:\n        \"\"\"Return named heads aligned to the immediate unseen physical sample.\n\n        ``future_inputs`` names every input without a feedback connection.\n        Drivers start immediately after history and require\n        ``max(0, horizon - min(prediction_leads))`` samples. With the default\n        next-step head this is ``horizon - 1``. History must contain at least\n        the largest prediction lead and feedback delay. Warmup predictions\n        already provide the first unseen samples; they are never skipped.\n        ``return_warmup`` prepends predictions on the shared physical timeline\n        starting at history index ``max(prediction_leads)``.\n\n        Every call rebuilds pending feedback from history and temporarily\n        disables training noise. ``execution='fast'`` requires pointwise graph\n        modules or explicit reservoir adapters. ``'history'`` replays the full\n        growing input prefix for pure causal sequence modules, at higher cost.\n        Custom modules may declare ``supports_framewise=True`` when appropriate.\n        Compiled forecasting is currently available for symbolic graphs only;\n        parallel and coupled backends require ``compile=False``.\n\n        ``return_type=\"auto\"`` returns a TSDynamics trajectory after trajectory\n        fitting or with trajectory history; otherwise it returns tensors.\n        ``\"tensor\"`` avoids conversion to NumPy/CPU. A selected trajectory result\n        needs timestamped history or the cached training context; a new tensor\n        history has no absolute clock. Trajectory history is resampled to the\n        fitted physical step and must retain fitted component names/order.\n        \"\"\"\n        self._require_scaling()\n        if return_type not in (\"auto\", \"tensor\", \"trajectory\"):\n            raise ValueError(\"return_type must be 'auto', 'tensor', or 'trajectory'\")\n        horizon = positive_step_count(horizon, \"horizon\")\n        self._backend.validate_forecast(self.graph, compile=compile)\n        validate_forecast_execution(self.graph, execution, compile=compile)\n        from resdag.core._hooks import (\n            eager_with_hooks,\n            forecast_owner,\n            has_execution_hooks,\n            original_outputs,\n        )\n\n        owner = forecast_owner(self)\n        hooked = has_execution_hooks(owner)\n        if hooked:\n            eager_with_hooks(compile)\n            compile = False\n        plan = self._feedback_plan()\n        if any(not layer.is_fitted for _, layer in self._backend.fitted_readouts(self.graph)):\n            raise RuntimeError(\n                \"Forecast requires fitted terminal readouts; call fit(training) first\"\n            )\n        context = self._trajectory_context\n        system = self._trajectory_system\n        cached_history = history is None\n        clocked_history = is_trajectory(history) or has_trajectory_port(history)\n        if clocked_history:\n            prepared = prepare_trajectory_port_history(\n                history,\n                input_names=self.input_names,\n                input_widths=self._input_widths,\n                output_names=self.output_names,\n                output_widths=self._output_widths,\n                context=context,\n                dt=self.resample_dt,\n                method=self.resample_method,\n                output_systems=system,\n            )\n            context, system = prepared.context, prepared.output_systems\n            reference = module_reference(self.graph)\n            history = {\n                name: torch.tensor(\n                    data,\n                    dtype=None if reference is None else reference.dtype,\n                    device=None if reference is None else reference.device,\n                )\n                for name, data in zip(self.input_names, prepared.inputs)\n            }\n        trajectory_output = return_type == \"trajectory\" or (\n            return_type == \"auto\" and context is not None\n        )\n        if trajectory_output:\n            if context is None or (not cached_history and not clocked_history):\n                raise ValueError(\n                    \"Trajectory output needs timestamped trajectory history or cached \"\n                    \"trajectory fitting history; pass a Trajectory or return_type='tensor'\"\n                )\n            if set(context[\"outputs\"]) != set(self.output_names):\n                raise ValueError(\n                    \"Trajectory output needs per-head target component metadata; \"\n                    \"fit Trajectory targets or choose return_type='tensor'\"\n                )\n            trajectory_type()  # Optional dependency must fail before graph hooks execute.\n        if history is None:\n            if not self.is_fitted:\n                raise RuntimeError(\"No cached history; provide history or call fit(training) first\")\n            history = {\n                name: getattr(self, f\"_history_{index}\")\n                for index, name in enumerate(self.input_names)\n            }\n        values, was_2d = self._streams(\n            cast(Streams, history), self.input_names, self._input_widths, \"history\", finite=True\n        )\n        if values[0].shape[1] < plan.required_history:\n            raise ValueError(\n                f\"history needs at least {plan.required_history} samples to seed all \"\n                \"prediction leads and feedback delays\"\n            )\n        driver_names = tuple(self.input_names[index] for index in plan.driver_indices)\n        driver_widths = tuple(self._input_widths[index] for index in plan.driver_indices)\n        steps = plan.future_steps(horizon)\n        drivers: tuple[torch.Tensor, ...]\n        if not driver_names:\n            if future_inputs is not None:\n                raise ValueError(\"This graph has no future driver inputs\")\n            drivers = ()\n        elif future_inputs is None:\n            if steps:\n                raise ValueError(f\"future_inputs requires driver keys {list(driver_names)}\")\n            drivers = tuple(values[index][:, :0] for index in plan.driver_indices)\n        else:\n            if is_trajectory(future_inputs) or has_trajectory_port(future_inputs):\n                if context is None or (not cached_history and not clocked_history):\n                    raise ValueError(\n                        \"Trajectory drivers require timestamped or cached trajectory history; \"\n                        \"new Tensor history has no absolute clock\"\n                    )\n                arrays = prepare_trajectory_port_drivers(\n                    future_inputs,\n                    input_names=driver_names,\n                    input_widths=driver_widths,\n                    last_time=context[\"clock\"][\"last_time\"],\n                    dt=context[\"clock\"][\"dt\"],\n                    steps=steps,\n                    method=self.resample_method,\n                    input_records=context[\"inputs\"],\n                )\n                future_inputs = {\n                    name: torch.tensor(data, device=values[0].device, dtype=values[0].dtype)\n                    for name, data in zip(driver_names, arrays)\n                }\n            drivers, _ = self._streams(\n                cast(Streams, future_inputs),\n                driver_names,\n                driver_widths,\n                \"future_inputs\",\n                finite=True,\n                allow_empty=True,\n            )\n            if drivers[0].shape[0] != values[0].shape[0] or drivers[0].shape[1] < steps:\n                raise ValueError(\n                    f\"future_inputs must match the history batch and contain at least {steps} samples\"\n                )\n        times = None\n        if trajectory_output:\n            assert context is not None\n            times = trajectory_port_forecast_times(\n                context,\n                horizon,\n                history_length=values[0].shape[1],\n                warmup_lead=max(plan.leads),\n                return_warmup=return_warmup,\n            )\n        default_route = (\n            len(plan.routes) == 1\n            and plan.routes[0] == FeedbackRoute(0, 0, 1)\n            and all(lead == 1 for lead in plan.leads)\n        )\n        final_states = None\n        output: ModelOutput\n        with evaluating(owner):\n            if not hooked and drivers and drivers[0].shape[1]:\n                drivers = tuple(\n                    (\n                        apply_transform(self.input_scalers[index], value)\n                        if self._transform_active(output=False, index=index)\n                        else value\n                    )\n                    for index, value in zip(plan.driver_indices, drivers)\n                )\n            if hooked:\n                executor = ForecastSequenceExecutor(\n                    self.graph, execution, workflow=self, owner=owner\n                )\n                output, final_states = feedback_rollout(\n                    executor,\n                    values,\n                    drivers,\n                    plan,\n                    lambda route, value: value,\n                    horizon=horizon,\n                    return_warmup=return_warmup,\n                )\n            elif execution == \"fast\" and default_route and self._feedback_scaling_matches():\n                output = self._backend.forecast(\n                    self.graph,\n                    self._scaled_inputs(values),\n                    drivers or None,\n                    horizon=horizon,\n                    return_warmup=return_warmup,\n                    compile=compile,\n                )\n            else:\n                executor = ForecastSequenceExecutor(self.graph, execution, compile=compile)\n\n                def bridge(route: FeedbackRoute, value: torch.Tensor) -> torch.Tensor:\n                    if self._transform_active(output=True, index=route.output_index):\n                        value = apply_transform(\n                            self.output_scalers[route.output_index], value, inverse=True\n                        )\n                    if self._transform_active(output=False, index=route.input_index):\n                        value = apply_transform(self.input_scalers[route.input_index], value)\n                    return value\n\n                output, final_states = feedback_rollout(\n                    executor,\n                    self._scaled_inputs(values),\n                    drivers,\n                    plan,\n                    bridge,\n                    horizon=horizon,\n                    return_warmup=return_warmup,\n                )\n            result = (\n                original_outputs(cast(tuple[torch.Tensor, ...], output), self.output_names, was_2d)\n                if hooked\n                else self._outputs(output, was_2d)\n            )\n        if not trajectory_output:\n            if final_states is not None:\n                self._commit_forecast_states(final_states)\n            return result\n        assert context is not None and times is not None\n        # NumPy has no bfloat16 dtype. Conversion is confined to this explicit\n        # CPU result boundary; tensor forecasts retain their device and dtype.\n        result_values = (\n            {self.output_names[0]: result} if isinstance(result, torch.Tensor) else result\n        )\n        result_arrays = {}\n        for name, value in result_values.items():\n            numpy_dtype = torch.float32 if value.dtype == torch.bfloat16 else value.dtype\n            result_arrays[name] = value.detach().to(device=\"cpu\", dtype=numpy_dtype).numpy()\n        trajectory = forecast_trajectory_ports(\n            result_arrays,\n            context,\n            output_names=self.output_names,\n            output_systems=system,\n            times=times,\n        )\n        if final_states is not None:\n            self._commit_forecast_states(final_states)\n        return trajectory\n\n    def get_extra_state(self) -> dict[str, Any]:\n        \"\"\"Checkpoint metadata prevents silent remapping of equal-width ports.\"\"\"\n        return {\n            \"version\": 2,\n            \"input_names\": self.input_names,\n            \"output_names\": self.output_names,\n            \"input_widths\": self._input_widths,\n            \"output_widths\": self._output_widths,\n            \"backend\": copy.deepcopy(self._backend_schema),\n            \"preprocessing\": self.preprocessing,\n            \"transforms\": copy.deepcopy(self._transform_schema),\n            \"washout\": self.washout,\n            \"prediction_lead\": self.prediction_leads,\n            \"feedback\": (\n                None\n                if self._feedback is None\n                else [\n                    {\"output\": route.output, \"input\": route.input, \"delay\": route.delay}\n                    for route in self._feedback\n                ]\n            ),\n            \"resample_dt\": self.resample_dt,\n            \"resample_method\": self.resample_method,\n            \"trajectory\": copy.deepcopy(self._trajectory_context),\n        }\n\n    def _checkpoint_feedback(\n        self, state: dict[str, Any]\n    ) -> tuple[tuple[int, ...], tuple[Feedback, ...] | None]:\n        leads = prediction_leads(state[\"prediction_lead\"], self.output_names)\n        saved = state[\"feedback\"]\n        specs = None\n        if saved is not None:\n            if not isinstance(saved, (list, tuple)) or any(\n                not isinstance(route, dict) or set(route) != {\"output\", \"input\", \"delay\"}\n                for route in saved\n            ):\n                raise ValueError(\"feedback must contain output/input/delay connection records\")\n            specs = tuple(\n                Feedback(route[\"output\"], route[\"input\"], route[\"delay\"]) for route in saved\n            )\n        feedback_plan(\n            specs,\n            leads,\n            self.input_names,\n            self.output_names,\n            self._input_widths,\n            self._output_widths,\n            validate_widths=specs is not None,\n        )\n        return leads, specs\n\n    def _validate_metadata(self, state: Any) -> None:\n        if (\n            not isinstance(state, dict)\n            or type(state.get(\"version\")) is not int\n            or state[\"version\"] != 2\n        ):\n            raise RuntimeError(\n                \"Model checkpoint requires current metadata version 2; \"\n                \"reconstruct and refit models saved with older metadata\"\n            )\n        if set(state) != {\n            \"version\",\n            \"input_names\",\n            \"output_names\",\n            \"input_widths\",\n            \"output_widths\",\n            \"backend\",\n            \"preprocessing\",\n            \"transforms\",\n            \"washout\",\n            \"prediction_lead\",\n            \"feedback\",\n            \"resample_dt\",\n            \"resample_method\",\n            \"trajectory\",\n        }:\n            raise RuntimeError(\n                \"Invalid or unsupported older Model checkpoint metadata fields; \"\n                \"reconstruct and refit the model\"\n            )\n        if state[\"backend\"] != self._backend_schema:\n            raise RuntimeError(\n                \"Model checkpoint backend schema differs from this graph; reconstruct \"\n                \"matching backend geometry, members and aggregation\"\n            )\n        if state.get(\"transforms\") != self._transform_schema:\n            raise RuntimeError(\n                \"Model checkpoint custom transform schema differs; reconstruct matching port modules\"\n            )\n        for key, expected in (\n            (\"input_names\", self.input_names),\n            (\"output_names\", self.output_names),\n            (\"input_widths\", self._input_widths),\n            (\"output_widths\", self._output_widths),\n        ):\n            if state.get(key) != expected:\n                raise RuntimeError(\n                    f\"Model checkpoint {key} differs from this graph; reconstruct matching named ports\"\n                )\n        if state.get(\"preprocessing\") not in (\n            None,\n            \"minmax\",\n            \"standard\",\n            \"noncentered\",\n            \"meanpreserving\",\n        ):\n            raise RuntimeError(\"Invalid Model checkpoint preprocessing\")\n        try:\n            _washout(cast(int, state.get(\"washout\")))\n        except ValueError as error:\n            raise RuntimeError(\"Invalid Model checkpoint washout\") from error\n        try:\n            self._checkpoint_feedback(state)\n        except (ValueError, TypeError) as error:\n            raise RuntimeError(f\"Invalid Model checkpoint feedback: {error}\") from error\n        try:\n            validate_resampling_options(state[\"resample_dt\"], state[\"resample_method\"])\n            if state.get(\"trajectory\") is not None:\n                validate_trajectory_ports_context(\n                    state[\"trajectory\"],\n                    self.input_names,\n                    self._input_widths,\n                    self.output_names,\n                    self._output_widths,\n                    self._checkpoint_feedback(state)[0],\n                )\n        except (TypeError, ValueError) as error:\n            raise RuntimeError(\n                f\"Invalid Model checkpoint trajectory configuration: {error}\"\n            ) from error\n\n    def set_extra_state(self, state: Any) -> None:\n        \"\"\"Restore workflow configuration after validating the named graph schema.\"\"\"\n        self._validate_metadata(state)\n        self._preprocessing, self.washout = state[\"preprocessing\"], state[\"washout\"]\n        self._prediction_leads, self._feedback = self._checkpoint_feedback(state)\n        self.resample_dt, self.resample_method = validate_resampling_options(\n            state[\"resample_dt\"], state[\"resample_method\"]\n        )\n        self._trajectory_context = (\n            validate_trajectory_ports_context(\n                state[\"trajectory\"],\n                self.input_names,\n                self._input_widths,\n                self.output_names,\n                self._output_widths,\n                self._prediction_leads,\n            )\n            if state.get(\"trajectory\") is not None\n            else None\n        )\n        object.__setattr__(self, \"_trajectory_system\", None)\n\n    def _load_from_state_dict(\n        self,\n        state_dict: dict[str, Any],\n        prefix: str,\n        local_metadata: dict[str, Any],\n        strict: bool,\n        missing_keys: list[str],\n        unexpected_keys: list[str],\n        error_msgs: list[str],\n    ) -> None:\n        self._validate_transform_ownership()\n        metadata = state_dict.get(prefix + \"_extra_state\")\n        self._validate_metadata(metadata)\n        metadata = cast(dict[str, Any], metadata)\n        fitted = state_dict.get(prefix + \"_fitted\")\n        if (\n            not isinstance(fitted, torch.Tensor)\n            or fitted.shape != ()\n            or fitted.dtype != torch.bool\n            or fitted.device.type == \"meta\"\n        ):\n            raise RuntimeError(\"Invalid Model checkpoint fitted flag\")\n        fitted_flag = bool(fitted.item())\n        if metadata.get(\"trajectory\") is not None and not fitted_flag:\n            raise RuntimeError(\"Invalid Model checkpoint: trajectory history requires fitted model\")\n        if fitted_flag:\n            for path, _ in self._backend.fitted_readouts(self.graph):\n                flag = state_dict.get(prefix + f\"graph.{path}._is_fitted\")\n                if (\n                    not isinstance(flag, torch.Tensor)\n                    or flag.shape != ()\n                    or flag.dtype != torch.bool\n                    or flag.device.type == \"meta\"\n                    or not bool(flag.item())\n                ):\n                    raise RuntimeError(\n                        \"Invalid Model checkpoint: fitted workflow requires fitted readouts\"\n                    )\n        method = cast(NormMethod, metadata[\"preprocessing\"] or \"standard\")\n        custom_state: dict[str, torch.Tensor] = {}\n        # Standalone normalization restores unknown widths/rules. The surrounding\n        # named graph fixes both; preflight all scalers before mutating weights.\n        for group, scalers, widths, masks in (\n            (\"input_scalers\", self.input_scalers, self._input_widths, self._custom_inputs),\n            (\"output_scalers\", self.output_scalers, self._output_widths, self._custom_outputs),\n        ):\n            for index, (scaler, width, custom) in enumerate(zip(scalers, widths, masks)):\n                stem = prefix + f\"{group}.{index}.\"\n                if custom:\n                    sample_name = f\"_{'input' if group == 'input_scalers' else 'output'}_transform_sample_{index}\"\n                    sample = state_dict.get(prefix + sample_name)\n                    destination_sample = getattr(self, sample_name)\n                    assign = local_metadata.get(\"assign_to_params_buffers\", False)\n                    if (\n                        isinstance(sample, torch.Tensor)\n                        and not assign\n                        and sample.device.type != \"meta\"\n                    ):\n                        with torch.inference_mode(False), torch.no_grad():\n                            sample = sample.to(destination_sample, copy=True)\n                    try:\n                        clean, sample = checkpoint_transform(\n                            scaler,\n                            {\n                                key[len(stem) :]: value\n                                for key, value in state_dict.items()\n                                if key.startswith(stem)\n                            },\n                            sample,\n                            width,\n                            fitted=fitted_flag,\n                            assign=assign,\n                        )\n                    except (ValueError, TypeError, RuntimeError) as error:\n                        raise RuntimeError(\n                            f\"Invalid Model checkpoint custom transform {group}.{index}: {error}\"\n                        ) from error\n                    custom_state.update({stem + key: value for key, value in clean.items()})\n                    custom_state[prefix + sample_name] = sample\n                    continue\n                scaler_state = {\n                    key: state_dict[stem + key]\n                    for key in (\"_method_code\", \"_stat0\", \"_stat1\")\n                    if stem + key in state_dict\n                }\n                reference = cast(FittedNormalization, scaler)._stat0\n                with torch.inference_mode(False):\n                    probe = FittedNormalization(method).to(reference)\n                    probe.load_state_dict(\n                        scaler_state, assign=local_metadata.get(\"assign_to_params_buffers\", False)\n                    )\n                expected_width = width if fitted_flag and metadata[\"preprocessing\"] else None\n                if probe.method != method or probe.n_features != expected_width:\n                    raise RuntimeError(\n                        f\"Invalid Model checkpoint {group}: preprocessing method, feature \"\n                        \"width and fitted statistics must match the declared graph schema\"\n                    )\n        staged = []\n        for index, width in enumerate(self._input_widths):\n            key = prefix + f\"_history_{index}\"\n            if key not in state_dict:\n                raise RuntimeError(\"Model checkpoint is missing its cached history\")\n            value = state_dict[key]\n            if (\n                not isinstance(value, torch.Tensor)\n                or not value.is_floating_point()\n                or value.ndim not in (2, 3)\n                or value.shape[-1] != width\n                or value.device.type == \"meta\"\n                or not bool(torch.isfinite(value).all())\n            ):\n                raise RuntimeError(\"Invalid Model checkpoint history\")\n            with torch.inference_mode(False), torch.no_grad():\n                destination = getattr(self, f\"_history_{index}\")\n                converted = (\n                    value.detach().clone()\n                    if local_metadata.get(\"assign_to_params_buffers\", False)\n                    else value.to(destination, copy=True)\n                )\n                if not bool(torch.isfinite(converted).all()):\n                    raise RuntimeError(\"Model checkpoint history overflows the destination dtype\")\n                staged.append(converted)\n        if any(value.ndim != staged[0].ndim for value in staged):\n            raise RuntimeError(\"Invalid Model checkpoint history: input layouts differ\")\n        canonical = tuple(value.unsqueeze(0) if value.ndim == 2 else value for value in staged)\n        if metadata.get(\"trajectory\") is not None and (\n            staged[0].ndim != 2\n            or canonical[0].shape[1] > metadata[\"trajectory\"][\"clock\"][\"n_samples\"]\n        ):\n            raise RuntimeError(\"Invalid Model checkpoint trajectory history layout/count\")\n        try:\n            validate_sequence_inputs(\n                canonical,\n                feature_sizes=self._input_widths,\n                label=\"checkpoint history\",\n                allow_empty=not fitted_flag,\n            )\n        except (ValueError, TypeError) as error:\n            raise RuntimeError(f\"Invalid Model checkpoint history: {error}\") from error\n        with torch.inference_mode(False):\n            # The recursive Module loader consumes this same local mapping for\n            # child tensors. Install only fully preflighted normal tensors.\n            state_dict.update(custom_state)\n            for name, value in custom_state.items():\n                local_name = name.removeprefix(prefix)\n                if local_name.startswith((\"_input_transform_sample_\", \"_output_transform_sample_\")):\n                    setattr(self, local_name, torch.empty_like(value))\n            state_dict = dict(state_dict)\n            for index, value in enumerate(staged):\n                setattr(self, f\"_history_{index}\", torch.empty_like(value))\n                state_dict[prefix + f\"_history_{index}\"] = value\n            self._fitted = torch.empty_like(self._fitted)\n            state_dict[prefix + \"_fitted\"] = fitted.detach().clone()\n            super()._load_from_state_dict(\n                state_dict,\n                prefix,\n                local_metadata,\n                strict,\n                missing_keys,\n                unexpected_keys,\n                error_msgs,\n            )\n        self._fitted_flag = bool(self._fitted.item())\n"
      },
      "src/resdag/models/parallel_esn.py": {
        "sha256": "6d7f22e288499fd6367fbb555eeb910b3d04c06e91e4d9e8e7297c1d93db59a6",
        "source": "\"\"\"\nParallel Reservoir with Local States (Pathak et al. 2018)\n=========================================================\n\nThis module provides :func:`parallel_esn` and :class:`ParallelESNModel`, the\n**parallel / local-state** reservoir architecture of Pathak et al. 2018 for\nforecasting large spatiotemporally chaotic systems (PDEs / weather / coupled\nlattices) that a single global reservoir cannot scale to.\n\nThe idea: a spatially-extended state of dimension ``D`` is split into ``P``\noverlapping local **patches** of core width ``w`` (``P = D / w``), each with a\nhalo of ``g`` neighbouring cells on either side (so each patch *reads* width\n``w + 2g`` but *predicts* only its core width ``w``).  Every patch has its **own\nreservoir state**, but they all **share one set of reservoir weights** \u2014 so the\n``P`` patches advance as a **single batched matmul** with the patch axis playing\nthe role of the reservoir batch dimension.  Each patch's readout predicts only\nits core region; the per-patch core predictions are stitched back into the full\n``D``-dimensional next state, re-windowed into patches, and the loop repeats\n(closed-loop autoregressive forecast).\n\nThe reservoir size ``N`` and input/output widths (``w + 2g`` / ``w``) stay fixed\nas ``D`` grows; the batch count ``P`` grows instead. Computational work scales\nwith the number of patches, and batching lets accelerators process them in\nparallel. Runtime depends on patch count, reservoir size and available hardware.\n\nReferences\n----------\nJ. Pathak, B. Hunt, M. Girvan, Z. Lu, and E. Ott, \"Model-Free Prediction of\nLarge Spatiotemporally Chaotic Systems from Data: A Reservoir Computing\nApproach,\" Phys. Rev. Lett. 120, 024102 (2018).\n\nSee Also\n--------\nresdag.datasets.kuramoto_sivashinsky : The canonical spatiotemporal benchmark.\nresdag.models.classic_esn : Single global reservoir (the baseline it beats at\n    scale).\n\"\"\"\n\nfrom __future__ import annotations\n\nfrom collections.abc import Mapping\nfrom pathlib import Path\nfrom typing import Any, cast\n\nimport torch\n\nfrom resdag._contracts import module_reference, validate_sequence_inputs\nfrom resdag.core._execution import ReservoirStates\nfrom resdag.core._forecast import ForecastAlignment, prepare_forecast_inputs\nfrom resdag.core._persistence import (\n    load_checkpoint,\n    load_full_model,\n    save_checkpoint,\n    save_full_model,\n)\nfrom resdag.core.model import ReservoirModelModule\nfrom resdag.init.utils import InitializerSpec, TopologySpec\nfrom resdag.layers import ESNLayer\nfrom resdag.layers.readouts import ReadoutLayer\n\nfrom ._builder import ReadoutSpec, _make_readout\n\n\ndef _patch_gather_index(input_dim: int, core_width: int, halo: int) -> torch.Tensor:\n    \"\"\"Build the periodic per-patch gather index for windowing a full state.\n\n    Partitions ``input_dim`` into ``P = input_dim / core_width`` contiguous\n    cores and returns, for each patch, the ``core_width + 2 * halo`` **wrapped**\n    spatial indices it reads (its core plus ``halo`` neighbours on each side,\n    with periodic boundaries \u2014 the standard convention for the Kuramoto-\n    Sivashinsky and other periodic-domain benchmarks).\n\n    A single ``state[..., idx]`` with the returned index then windows the whole\n    field into all ``P`` patches at once (no Python loop over patches), which is\n    what lets the patches advance as one batched reservoir op.\n\n    Parameters\n    ----------\n    input_dim : int\n        Full spatial dimension ``D`` of the state.\n    core_width : int\n        Core width ``w`` predicted by each patch.  Must divide ``input_dim``.\n    halo : int\n        Number of neighbouring cells ``g`` added on each side of the core.\n\n    Returns\n    -------\n    torch.Tensor\n        Long tensor of shape ``(P, core_width + 2 * halo)`` where row ``p`` holds\n        the periodic indices for patch ``p`` (``P = input_dim // core_width``).\n\n    Raises\n    ------\n    ValueError\n        If ``core_width`` does not divide ``input_dim``, or if any argument is\n        out of range (non-positive core width, negative halo).\n    \"\"\"\n    if input_dim <= 0:\n        raise ValueError(f\"input_dim must be a positive integer, got {input_dim}.\")\n    if core_width <= 0:\n        raise ValueError(f\"core_width must be a positive integer, got {core_width}.\")\n    if halo < 0:\n        raise ValueError(f\"halo must be a non-negative integer, got {halo}.\")\n    if input_dim % core_width != 0:\n        raise ValueError(\n            f\"core_width ({core_width}) must divide input_dim ({input_dim}) evenly \"\n            f\"so the domain partitions into equal patches.\"\n        )\n    n_patches = input_dim // core_width\n    # Patch p's core starts at p*w; the windowed read spans [p*w - g, p*w + w + g).\n    patch_starts = torch.arange(n_patches).unsqueeze(1) * core_width  # (P, 1)\n    offsets = torch.arange(-halo, core_width + halo).unsqueeze(0)  # (1, w + 2g)\n    # Periodic wrap so patches near the boundary read across the seam.\n    return (patch_starts + offsets) % input_dim  # (P, w + 2g)\n\n\nclass ParallelESNModel(torch.nn.Module):\n    \"\"\"Parallel local-state reservoir for spatiotemporal forecasting.\n\n    Holds one shared-weight :class:`~resdag.layers.ESNLayer` (advanced batched\n    over patches) and one weight-tied :class:`~resdag.layers.readouts.ReadoutLayer`\n    (fitted once over the pooled per-patch data), plus the patch geometry\n    (``input_dim``, ``core_width``, ``halo``).  Build it with\n    :func:`parallel_esn` rather than directly.\n\n    The public workflow mirrors the rest of the library \u2014 :meth:`fit` then\n    :meth:`forecast` \u2014 but the forecasting is spatial-autoregressive: it stitches\n    per-patch core predictions into the full field and re-windows every step,\n    rather than feeding a single output straight back.\n\n    Parameters\n    ----------\n    reservoir : ESNLayer\n        The shared reservoir.  Its ``feedback_size`` must equal\n        ``core_width + 2 * halo`` (the per-patch input width).\n    readout : ReadoutLayer\n        The weight-tied readout.  Its ``in_features`` must equal the reservoir\n        size and its ``out_features`` must equal ``core_width``.\n    input_dim : int\n        Full spatial dimension ``D`` of the modelled field.\n    core_width : int\n        Core width ``w`` each patch predicts (``P = input_dim // core_width``).\n    halo : int\n        Halo width ``g`` (neighbouring cells read on each side of the core).\n\n    Attributes\n    ----------\n    reservoir : ESNLayer\n        The shared reservoir layer.\n    readout : ReadoutLayer\n        The weight-tied readout layer.\n    n_patches : int\n        Number of patches ``P = input_dim // core_width``.\n\n    See Also\n    --------\n    parallel_esn : Factory that builds and wires this class.\n    \"\"\"\n\n    #: Non-persistent buffer holding the ``(P, w + 2g)`` periodic gather index.\n    patch_index: torch.Tensor\n\n    def __init__(\n        self,\n        reservoir: ESNLayer,\n        readout: ReadoutLayer,\n        input_dim: int,\n        core_width: int,\n        halo: int,\n    ) -> None:\n        super().__init__()\n        patch_index = _patch_gather_index(input_dim, core_width, halo).to(\n            device=reservoir.reference_device_dtype()[0]\n        )\n        patch_width = core_width + 2 * halo\n        if reservoir.feedback_size != patch_width:\n            raise ValueError(\n                f\"reservoir.feedback_size ({reservoir.feedback_size}) must equal the \"\n                f\"per-patch input width core_width + 2*halo = {patch_width}.\"\n            )\n        if readout.out_features != core_width:\n            raise ValueError(\n                f\"readout.out_features ({readout.out_features}) must equal core_width \"\n                f\"({core_width}) \u2014 each patch predicts only its core region.\"\n            )\n        if readout.in_features != reservoir.reservoir_size:\n            raise ValueError(\n                f\"readout.in_features ({readout.in_features}) must equal the reservoir \"\n                f\"size ({reservoir.reservoir_size}).\"\n            )\n\n        self.reservoir = reservoir\n        self.readout = readout\n        self.input_dim = input_dim\n        self.core_width = core_width\n        self.halo = halo\n        self.n_patches = input_dim // core_width\n        # Non-persistent: rebuilt cheaply from geometry, moves with ``.to()``.\n        self.register_buffer(\n            \"patch_index\",\n            patch_index,\n            persistent=False,\n        )\n\n    # ------------------------------------------------------------------\n    # Windowing / stitching (batched over patches \u2014 no Python loop)\n    # ------------------------------------------------------------------\n\n    def forward(self, series: torch.Tensor, *, reset: bool = False) -> torch.Tensor:\n        \"\"\"Predict each timestep, preserving gradients through the model.\n\n        Accepts ``(batch, time, input_dim)`` and returns that shape. Reservoir\n        state carries across calls; use ``reset=True`` for independent batches.\n        This teacher-forced path composes with ordinary PyTorch modules and\n        optimizers. Use :meth:`forecast` for an autonomous rollout.\n        \"\"\"\n        validate_sequence_inputs(\n            (series,), feature_sizes=(self.input_dim,), reference=module_reference(self)\n        )\n        if reset:\n            self.reset_reservoirs()\n        states = self.reservoir(self.window(series))\n        batch, timesteps = series.shape[:2]\n        cores = cast(torch.Tensor, self.readout(states))\n        return (\n            cores.reshape(batch, self.n_patches, timesteps, self.core_width)\n            .permute(0, 2, 1, 3)\n            .reshape(batch, timesteps, self.input_dim)\n        )\n\n    def forward_stateless(\n        self,\n        *inputs: torch.Tensor,\n        states: Mapping[str, torch.Tensor] | None = None,\n        compile: bool = False,\n    ) -> tuple[torch.Tensor, ReservoirStates]:\n        \"\"\"Predict independently or continue explicit per-patch recurrent states.\n\n        Pass one ``(batch, time, input_dim)`` field. The returned ``reservoir``\n        state folds the patches into its batch axis, with shape\n        ``(batch * n_patches, reservoir_size)``. State tensors retain gradients;\n        this method leaves the model's stored streaming states untouched.\n        \"\"\"\n        validate_sequence_inputs(\n            inputs, feature_sizes=(self.input_dim,), reference=module_reference(self)\n        )\n        from resdag.core._hooks import call_with_states, has_execution_hooks\n\n        if has_execution_hooks(self):\n            return cast(\n                tuple[torch.Tensor, ReservoirStates],\n                call_with_states(self, inputs, states, {\"reservoir\": \"reservoir\"}, compile=compile),\n            )\n        series = inputs[0]\n        patches = self.window(series)\n        if states is None:\n            state = self.reservoir.cell.init_state(patches.shape[0], patches.device, patches.dtype)\n        else:\n            if set(states) != {\"reservoir\"}:\n                raise ValueError(\"Reservoir state keys must be exactly ['reservoir']\")\n            state = states[\"reservoir\"]\n            if not isinstance(state, torch.Tensor):\n                raise TypeError(\"State for 'reservoir' must be a torch.Tensor\")\n            self.reservoir.cell.validate_state(state)\n            if state.shape[0] != patches.shape[0]:\n                raise ValueError(\"State batch size must equal batch * n_patches\")\n            if state.device != patches.device or state.dtype != patches.dtype:\n                raise ValueError(\"State must match the input device and dtype\")\n        features, final = self.reservoir.forward_stateless([patches], state, compile=compile)\n        batch, timesteps = series.shape[:2]\n        cores = cast(torch.Tensor, self.readout(features))\n        output = (\n            cores.reshape(batch, self.n_patches, timesteps, self.core_width)\n            .permute(0, 2, 1, 3)\n            .reshape(batch, timesteps, self.input_dim)\n        )\n        return output, {\"reservoir\": final}\n\n    def as_module(self, *, stateful: bool = False) -> ReservoirModelModule:\n        \"\"\"Share this complete trained model with a larger PyTorch pipeline.\"\"\"\n        return ReservoirModelModule(self, stateful=stateful)\n\n    def window(self, series: torch.Tensor) -> torch.Tensor:\n        \"\"\"Window a full ``(batch, T, D)`` field into per-patch inputs.\n\n        Gathers, for every patch, its ``core_width + 2 * halo`` periodic cells in\n        one indexing op, then folds the patch axis into the batch axis so the\n        result drops straight into the shared reservoir as a batched sequence.\n\n        Parameters\n        ----------\n        series : torch.Tensor\n            Full field of shape ``(batch, T, input_dim)``.\n\n        Returns\n        -------\n        torch.Tensor\n            Windowed input of shape ``(batch * P, T, core_width + 2 * halo)`` \u2014\n            the patch axis is folded into the leading (reservoir-batch) axis.\n        \"\"\"\n        if series.dim() != 3 or series.shape[-1] != self.input_dim:\n            raise ValueError(\n                f\"series must be 3-D (batch, T, input_dim={self.input_dim}); \"\n                f\"got shape {tuple(series.shape)}.\"\n            )\n        # series: (B, T, D) -> gather patch cells -> (B, T, P, w+2g).\n        windowed = series[..., self.patch_index]\n        b, t, n_patches, patch_width = windowed.shape\n        # Move patches next to the batch axis and fold them in: (B*P, T, w+2g).\n        windowed = windowed.permute(0, 2, 1, 3).reshape(b * n_patches, t, patch_width)\n        return windowed\n\n    def _cores_from_index(self) -> torch.Tensor:\n        \"\"\"Column offsets of the core region inside each patch window (``(w,)``).\"\"\"\n        return torch.arange(self.halo, self.halo + self.core_width, device=self.patch_index.device)\n\n    def stitch(self, patch_cores: torch.Tensor) -> torch.Tensor:\n        \"\"\"Assemble per-patch core predictions into the full field.\n\n        Inverse of :meth:`window` for the core regions: patch ``p`` owns cores\n        ``[p*w : (p+1)*w]`` of the full field, so concatenating the patches' core\n        predictions along the spatial axis reconstructs the whole ``D``-wide\n        state.  With non-overlapping cores this is a contiguous reshape (no\n        averaging needed).\n\n        Parameters\n        ----------\n        patch_cores : torch.Tensor\n            Per-patch core predictions of shape ``(batch, P, core_width)``.\n\n        Returns\n        -------\n        torch.Tensor\n            Full field of shape ``(batch, input_dim)``.\n        \"\"\"\n        b = patch_cores.shape[0]\n        return patch_cores.reshape(b, self.input_dim)\n\n    # ------------------------------------------------------------------\n    # Reservoir-state management (delegates to the shared reservoir)\n    # ------------------------------------------------------------------\n\n    def reset_reservoirs(self) -> None:\n        \"\"\"Reset the shared reservoir's per-patch states (lazy re-init).\"\"\"\n        self.reservoir.reset_state()\n\n    def get_state(self) -> ReservoirStates:\n        \"\"\"Return a copy of the initialized, patch-batched streaming state.\"\"\"\n        state = self.reservoir.get_state()\n        return {} if state is None else {\"reservoir\": state}\n\n    def set_state(self, states: Mapping[str, torch.Tensor], strict: bool = True) -> None:\n        \"\"\"Restore the named recurrent state on the model's device and dtype.\"\"\"\n        if strict and set(states) != {\"reservoir\"}:\n            raise KeyError(\"Reservoir state keys must be exactly ['reservoir']\")\n        if \"reservoir\" in states:\n            import warnings\n\n            device, dtype = self.reservoir.reference_device_dtype()\n            state = states[\"reservoir\"]\n            if state.device != device or state.dtype != dtype:\n                warnings.warn(\n                    f\"State for 'reservoir' moved/cast to device={device}, dtype={dtype}\",\n                    UserWarning,\n                    stacklevel=2,\n                )\n            self.reservoir.set_state(state.to(device=device, dtype=dtype))\n\n    def get_reservoir_states(self) -> ReservoirStates:\n        \"\"\"Return the named recurrent state; alias of :meth:`get_state`.\"\"\"\n        return self.get_state()\n\n    def set_reservoir_states(self, states: Mapping[str, torch.Tensor], strict: bool = True) -> None:\n        \"\"\"Restore named recurrent state; alias of :meth:`set_state`.\"\"\"\n        self.set_state(states, strict=strict)\n\n    # ------------------------------------------------------------------\n    # Training\n    # ------------------------------------------------------------------\n\n    def fit(\n        self,\n        warmup: torch.Tensor,\n        train: torch.Tensor,\n        targets: torch.Tensor,\n        *,\n        reset: bool = True,\n    ) -> None:\n        \"\"\"Fit the weight-tied readout over all patches in one pooled solve.\n\n        Windows ``warmup`` / ``train`` into per-patch inputs, runs them through\n        the shared reservoir (batched over ``batch * P``), and fits the single\n        readout on the pooled ``(reservoir_state -> core_target)`` pairs from\n        every patch and timestep \u2014 the weight-tied readout of Pathak et al.\n\n        Parameters\n        ----------\n        warmup : torch.Tensor\n            Teacher-forced warmup field of shape ``(batch, warmup_steps, D)``\n            used only to synchronise the reservoir states.\n        train : torch.Tensor\n            Training field of shape ``(batch, train_steps, D)`` whose reservoir\n            states are regressed onto ``targets``.\n        targets : torch.Tensor\n            Next-step field of shape ``(batch, train_steps, D)`` \u2014 typically\n            ``train`` shifted one step ahead.  Each patch is supervised on its\n            own core slice of this field.\n        reset : bool, default=True\n            If ``True``, reset the reservoir states before warmup.\n\n        Raises\n        ------\n        ValueError\n            If any input is not 3-D, if their feature dimension is not\n            ``input_dim``, or if ``train`` and ``targets`` disagree on\n            batch/length.\n        \"\"\"\n        for name, arr in ((\"warmup\", warmup), (\"train\", train), (\"targets\", targets)):\n            if arr.dim() != 3:\n                raise ValueError(f\"{name} must be 3-D (batch, T, D); got shape {tuple(arr.shape)}.\")\n            if arr.shape[-1] != self.input_dim:\n                raise ValueError(\n                    f\"{name} has feature dim {arr.shape[-1]}, expected input_dim={self.input_dim}.\"\n                )\n        if train.shape[:2] != targets.shape[:2]:\n            raise ValueError(\n                f\"train and targets must share (batch, T); got {tuple(train.shape[:2])} \"\n                f\"vs {tuple(targets.shape[:2])}.\"\n            )\n        reference = module_reference(self)\n        for label, tensor in ((\"warmup\", warmup), (\"train\", train), (\"targets\", targets)):\n            validate_sequence_inputs(\n                (tensor,),\n                feature_sizes=(self.input_dim,),\n                reference=reference,\n                label=label,\n                allow_empty=label == \"warmup\",\n            )\n        if warmup.shape[0] != train.shape[0]:\n            raise ValueError(\"warmup and train must have the same batch size\")\n\n        if reset:\n            self.reset_reservoirs()\n\n        with torch.no_grad():\n            # Warmup: synchronise the per-patch reservoir states.\n            self.reservoir(self.window(warmup))\n            # Train pass: collect reservoir states for every patch and step.\n            states = self.reservoir(self.window(train))  # (B*P, train_steps, N)\n\n        # Per-patch core targets: window the target field and keep only the core\n        # columns (offsets [halo, halo + core_width)).  Same (B*P, T) folding as\n        # the states, so state[i] and target[i] are the same patch/step pair.\n        windowed_targets = self.window(targets)  # (B*P, T, w+2g)\n        core_targets = windowed_targets[..., self._cores_from_index()]  # (B*P, T, w)\n\n        # One pooled ridge solve over all patches (weight-tied readout).  fit()\n        # flattens (B*P, T, .) -> (B*P*T, .) internally.\n        self.readout.fit(states, core_targets)\n\n    # ------------------------------------------------------------------\n    # Forecasting (spatial-autoregressive, closed loop)\n    # ------------------------------------------------------------------\n\n    def forecast(\n        self,\n        warmup: torch.Tensor,\n        *,\n        horizon: int,\n        initial_feedback: torch.Tensor | None = None,\n        reset: bool = True,\n        return_warmup: bool = False,\n        alignment: ForecastAlignment = \"next\",\n    ) -> torch.Tensor:\n        \"\"\"Predict the next full fields after the observed ``warmup``.\n\n        Inputs have shape ``(batch, time, input_dim)`` and results have shape\n        ``(batch, horizon, input_dim)``. Slot zero is the final warmup prediction,\n        estimating the immediate unseen field. Each later step feeds the previous\n        prediction through the batched patches. ``horizon`` is a positive integer.\n\n        ``initial_feedback`` is a distinct extra field consumed after all warmup\n        fields, shaped ``(batch, 1, input_dim)``. It also permits empty history;\n        use ``reset=False`` to continue states with the previous final prediction\n        as this seed. The final returned prediction has not yet been consumed.\n\n        ``return_warmup=True`` prepends historical *predictions*, giving length\n        ``warmup_steps - 1 + horizon``. Explicit seeds give ``warmup_steps + horizon``.\n        ``alignment=\"legacy\"`` uses the old low-level ESN convention: omit the\n        final warmup prediction, then generate ``horizon`` steps, giving a\n        ``warmup_steps + horizon`` result when historical predictions are included.\n        The default future timing already matches earlier ParallelESN releases;\n        their ``return_warmup`` prefix contained raw observations instead.\n        \"\"\"\n        inputs, _, horizon, boundary = prepare_forecast_inputs(\n            warmup,\n            None,\n            num_inputs=1,\n            horizon=horizon,\n            initial_feedback=initial_feedback,\n            alignment=alignment,\n        )\n        warmup = inputs[0]\n        if warmup.shape[-1] != self.input_dim:\n            raise ValueError(\n                f\"warmup must have input_dim={self.input_dim} features; got {warmup.shape[-1]}\"\n            )\n        if not self.readout.is_fitted:\n            raise ValueError(\"forecast() requires a fitted readout; call fit() first.\")\n        from resdag.core._hooks import has_execution_hooks\n\n        forward = self if has_execution_hooks(self) else self.forward\n        with torch.no_grad():\n            warmup_outputs = forward(warmup, reset=reset)\n            current = (\n                initial_feedback if initial_feedback is not None else warmup_outputs[:, -1:, :]\n            )\n            outputs = torch.empty(\n                warmup.shape[0],\n                horizon,\n                self.input_dim,\n                dtype=warmup_outputs.dtype,\n                device=warmup_outputs.device,\n            )\n            if boundary:\n                outputs[:, :1, :] = current\n            for t in range(int(boundary), horizon):\n                current = forward(current)\n                outputs[:, t : t + 1, :] = current\n            if return_warmup:\n                prefix = warmup_outputs[:, :-1, :] if boundary else warmup_outputs\n                return torch.cat((prefix, outputs), dim=1)\n            return outputs\n\n    # ------------------------------------------------------------------\n    # Persistence\n    # ------------------------------------------------------------------\n\n    def save(\n        self,\n        path: str | Path,\n        include_states: bool = False,\n        **metadata: Any,\n    ) -> None:\n        \"\"\"Save weights and optional recurrent state; recreate the architecture to load.\"\"\"\n        save_checkpoint(self, path, include_states, metadata)\n\n    def load(\n        self,\n        path: str | Path,\n        strict: bool = True,\n        load_states: bool = False,\n        map_location: Any = None,\n    ) -> None:\n        \"\"\"Restore a matching model, optionally remapping saved tensor devices.\"\"\"\n        load_checkpoint(self, path, strict, load_states, map_location)\n\n    @classmethod\n    def load_from_file(\n        cls,\n        path: str | Path,\n        model: \"ParallelESNModel | None\" = None,\n        strict: bool = True,\n        load_states: bool = False,\n        map_location: Any = None,\n    ) -> \"ParallelESNModel\":\n        \"\"\"Restore weights into an already constructed matching model.\"\"\"\n        if model is None:\n            raise ValueError(\"model argument is required\")\n        model.load(path, strict=strict, load_states=load_states, map_location=map_location)\n        return model\n\n    def save_full(self, path: str | Path, **metadata: Any) -> None:\n        \"\"\"Serialize the whole model (architecture + weights + states) to a file.\n\n        Mirrors :meth:`resdag.core.ESNModel.save_full`: pickles the entire module\n        so :meth:`load_full` reconstructs it with no pre-built architecture.  The\n        file is a ``torch.save`` payload loaded back with ``weights_only=False`` \u2014\n        only open files you trust.\n\n        Parameters\n        ----------\n        path : str or Path\n            File path to save to. Parent directories are created if needed.\n        **metadata\n            Additional metadata stored alongside the model.\n        \"\"\"\n        save_full_model(self, path, metadata)\n\n    @classmethod\n    def load_full(\n        cls,\n        path: str | Path,\n        return_metadata: bool = False,\n        map_location: Any = None,\n    ) -> \"ParallelESNModel | tuple[ParallelESNModel, dict[str, Any]]\":\n        \"\"\"Reconstruct a model saved with :meth:`save_full`.\n\n        Parameters\n        ----------\n        path : str or Path\n            File path written by :meth:`save_full`.\n        return_metadata : bool, default=False\n            If ``True``, return ``(model, metadata)`` instead of just the model.\n        map_location : optional\n            Passed to ``torch.load`` to remap storage devices.\n\n        Returns\n        -------\n        ParallelESNModel or tuple of (ParallelESNModel, dict)\n            The reconstructed model, optionally paired with its metadata.\n\n        Raises\n        ------\n        ValueError\n            If the file does not contain a parallel model.\n\n        Warnings\n        --------\n        Loads with ``weights_only=False`` (unpickles arbitrary objects); only\n        call on trusted files.\n        \"\"\"\n        return load_full_model(cls, path, return_metadata, map_location)\n\n    def __repr__(self) -> str:\n        \"\"\"Return a concise string representation.\"\"\"\n        return (\n            f\"ParallelESNModel(input_dim={self.input_dim}, core_width={self.core_width}, \"\n            f\"halo={self.halo}, n_patches={self.n_patches}, \"\n            f\"reservoir_size={self.reservoir.reservoir_size})\"\n        )\n\n\ndef parallel_esn(\n    input_dim: int,\n    core_width: int,\n    halo: int,\n    reservoir_size: int = 500,\n    *,\n    # Reservoir params\n    topology: TopologySpec | None = None,\n    spectral_radius: float = 0.6,\n    leak_rate: float = 1.0,\n    input_scaling: float = 0.1,\n    feedback_initializer: InitializerSpec | None = None,\n    activation: str = \"tanh\",\n    bias: bool = True,\n    trainable: bool = False,\n    seed: Any = None,\n    # Readout params\n    readout: ReadoutSpec = \"ridge\",\n    readout_alpha: float = 1e-4,\n    readout_bias: bool = True,\n    readout_name: str = \"output\",\n    readout_kwargs: dict[str, Any] | None = None,\n    # Extra reservoir kwargs\n    **reservoir_kwargs: Any,\n) -> ParallelESNModel:\n    r\"\"\"Build a parallel local-state reservoir (Pathak et al. 2018).\n\n    Splits a spatially-extended field of dimension ``input_dim`` into ``P =\n    input_dim / core_width`` overlapping patches (core width ``core_width``, halo\n    ``halo`` on each side, periodic boundaries), all sharing **one** reservoir\n    (advanced batched over patches) and **one** weight-tied readout (core width\n    ``core_width``).  See :class:`ParallelESNModel` and the module docstring for\n    the full architecture and the forecasting loop.\n\n    The defaults (``spectral_radius=0.6``, ``input_scaling=0.1``,\n    ``readout_alpha=1e-4``) are tuned for the local-patch regime, which uses a\n    smaller, better-conditioned reservoir per patch than a single global ESN \u2014\n    the classic Pathak KS settings.  ``input_scaling=0.1`` in particular is\n    decisive: the per-patch input width (``core_width + 2*halo``) is large enough\n    that an unscaled ``uniform(-1, 1)`` input map drives ``tanh`` deep into\n    saturation, collapsing the reservoir's memory; scaling the input weights down\n    keeps the dynamics responsive (on the canonical L=22 KS field it is the\n    difference between a fraction of a Lyapunov time and ~4 Lyapunov times of\n    valid prediction).\n\n    Parameters\n    ----------\n    input_dim : int\n        Full spatial dimension ``D`` of the field (e.g. the KS grid size).\n    core_width : int\n        Core width ``w`` each patch predicts.  Must divide ``input_dim``.\n    halo : int\n        Halo width ``g`` \u2014 neighbouring cells read on each side of the core\n        (periodic).  The per-patch reservoir input width is ``core_width + 2 *\n        halo``.\n    reservoir_size : int, default=500\n        Number of units ``N`` in the shared reservoir (per patch).\n    topology : TopologySpec, optional\n        Topology for the recurrent weights.  Accepts a registry name, a\n        ``(name, params)`` tuple, a callable, or a configured\n        :class:`~resdag.init.topology.TopologyInitializer`.\n    spectral_radius : float, default=0.6\n        Target spectral radius for the recurrent weights.\n    leak_rate : float, default=1.0\n        Leaky-integration rate (1.0 = no leak).\n    input_scaling : float, default=0.1\n        Scale of the per-patch input (feedback) weights when\n        ``feedback_initializer`` is left at its default.  The weights are drawn\n        from ``uniform(-input_scaling, input_scaling)`` (via the ``\"random\"``\n        initializer), keeping the ``tanh`` reservoir out of saturation on a\n        wide per-patch input.  Ignored when an explicit ``feedback_initializer``\n        is supplied (it then owns the input-weight scale).\n    feedback_initializer : InitializerSpec, optional\n        Initializer for the per-patch input weights.  Same accepted forms as\n        ``topology``.  When given, it overrides ``input_scaling``.  Left at its\n        default (``None``), the factory uses ``(\"random\", {\"input_scaling\":\n        input_scaling})``.\n    activation : str, default=\"tanh\"\n        Activation function (``\"tanh\"``, ``\"relu\"``, ``\"sigmoid\"``,\n        ``\"identity\"``).\n    bias : bool, default=True\n        Whether the reservoir uses a bias term.\n    trainable : bool, default=False\n        Whether the reservoir weights are trainable.\n    seed : int or torch.Generator, optional\n        Reproducibility seed fixing every reservoir parameter.\n    readout : str or type[ReadoutLayer], default=\"ridge\"\n        A built-in readout name or a ReadoutLayer subclass, with the same\n        solver choices as :func:`resdag.models.classic_esn`.\n    readout_alpha : float, default=1e-4\n        Ridge regularization for the readout.\n    readout_bias : bool, default=True\n        Whether the readout uses a bias term.\n    readout_name : str, default=\"output\"\n        Name for the readout layer.\n    readout_kwargs : dict, optional\n        Additional readout constructor options. Architecture widths are fixed.\n    **reservoir_kwargs : Any\n        Additional keyword arguments forwarded to :class:`~resdag.layers.ESNLayer`\n        (e.g. ``sparse``, ``noise``, ``input_initializer``).\n\n    Returns\n    -------\n    ParallelESNModel\n        The assembled parallel reservoir, ready for :meth:`~ParallelESNModel.fit`\n        and :meth:`~ParallelESNModel.forecast`.\n\n    Raises\n    ------\n    ValueError\n        If ``core_width`` does not divide ``input_dim``, or if a size argument is\n        out of range.\n\n    Examples\n    --------\n    Forecast a Kuramoto-Sivashinsky field with local patches::\n\n    >>> import torch\n    >>> from resdag import kuramoto_sivashinsky\n    >>> from resdag.models import parallel_esn\n    >>> data = kuramoto_sivashinsky(3000, n_grid=64, dtype=torch.float64)\n    >>> model = parallel_esn(input_dim=64, core_width=4, halo=6, reservoir_size=400,\n    ...                      seed=0)\n    >>> warmup, train = data[:, :200], data[:, 200:2200]\n    >>> model.fit(warmup, train[:, :-1], train[:, 1:])   # doctest: +SKIP\n    >>> pred = model.forecast(train[:, -100:], horizon=400)  # doctest: +SKIP\n\n    See Also\n    --------\n    ParallelESNModel : The model class this factory builds.\n    resdag.datasets.kuramoto_sivashinsky : The canonical spatiotemporal benchmark.\n    resdag.models.classic_esn : Single global reservoir baseline.\n    \"\"\"\n    _patch_gather_index(input_dim, core_width, halo)\n    patch_width = core_width + 2 * halo\n\n    # Default the per-patch input map to a *scaled* random init: on a wide\n    # per-patch input an unscaled ``uniform(-1, 1)`` saturates the tanh\n    # reservoir (see the ``input_scaling`` docstring).  An explicit\n    # ``feedback_initializer`` overrides this and owns the input-weight scale.\n    if feedback_initializer is None:\n        feedback_initializer = (\"random\", {\"input_scaling\": input_scaling})\n\n    reservoir = ESNLayer(\n        reservoir_size=reservoir_size,\n        feedback_size=patch_width,\n        topology=topology,\n        spectral_radius=spectral_radius,\n        leak_rate=leak_rate,\n        feedback_initializer=feedback_initializer,\n        activation=activation,\n        bias=bias,\n        trainable=trainable,\n        seed=seed,\n        **reservoir_kwargs,\n    )\n\n    readout_layer = _make_readout(\n        readout,\n        in_features=reservoir_size,\n        out_features=core_width,\n        bias=readout_bias,\n        alpha=readout_alpha,\n        name=readout_name,\n        readout_kwargs=readout_kwargs,\n    ).to(device=reservoir.weight_hh.device, dtype=reservoir.weight_hh.dtype)\n\n    return ParallelESNModel(\n        reservoir=reservoir,\n        readout=readout_layer,\n        input_dim=input_dim,\n        core_width=core_width,\n        halo=halo,\n    )\n"
      }
    },
    "candidate": {
      "src/resdag/core/workflow.py": {
        "sha256": "0abe2d4def3d4582f79b5d5d4f0f846f0e9ac6803a0cd834e338b8d379781ff5",
        "source": "\"\"\"Named functional models with a fitted, standard PyTorch workflow.\n\nThe existing symbolic, parallel and coupled model families share this workflow.\nAlgebraic symbolic fitting requires one distinct terminal readout per output.\n\"\"\"\n\nfrom __future__ import annotations\n\nimport copy\nimport operator\nfrom collections.abc import Mapping, Sequence\nfrom pathlib import Path\nfrom typing import TYPE_CHECKING, Any, Literal, cast\n\nimport torch\nfrom pytorch_symbolic.symbolic_data import SymbolicData\nfrom torch import nn\n\nfrom resdag._contracts import module_reference, validate_sequence_inputs\nfrom resdag.core._execution import ModelOutput, ReservoirStates\nfrom resdag.core._feedback import (\n    Feedback,\n    FeedbackPlan,\n    FeedbackRoute,\n    feedback_plan,\n    feedback_rollout,\n    feedback_specs,\n    prediction_leads,\n)\nfrom resdag.core._forecast import positive_step_count\nfrom resdag.core._forecast_capabilities import (\n    ForecastSequenceExecutor,\n    validate_forecast_execution,\n)\nfrom resdag.core._modes import evaluating\nfrom resdag.core._preprocessing import FittedNormalization\nfrom resdag.core._workflow_backends import recurrent_graph, workflow_backend\nfrom resdag.core._workflow_transforms import (\n    apply_transform,\n    checkpoint_transform,\n    commit_transform_state,\n    stage_transform,\n    transform_schema,\n    validate_custom_transform,\n    validate_transform_ownership,\n)\nfrom resdag.core.model import ESNModel\nfrom resdag.data._trajectory import (\n    is_trajectory,\n    trajectory_type,\n    validate_resampling_options,\n)\nfrom resdag.data._trajectory_ports import (\n    forecast_trajectory_ports,\n    has_trajectory_port,\n    prepare_trajectory_port_drivers,\n    prepare_trajectory_port_history,\n    prepare_trajectory_ports,\n    trajectory_port_forecast_times,\n    validate_trajectory_ports_context,\n)\nfrom resdag.data.prepare import NormMethod\nfrom resdag.layers.readouts import AutoReadoutLayer, LSMRReadoutLayer\nfrom resdag.layers.reservoirs import BaseReservoirLayer\n\nif TYPE_CHECKING:\n    from tsdynamics.data import Trajectory\n\n\nStreams = torch.Tensor | Mapping[str, torch.Tensor]\nWorkflowOutput = torch.Tensor | dict[str, torch.Tensor]\nPreprocessing = NormMethod | Literal[\"off\"] | None\n\n\ndef _port_names(names: Sequence[str], count: int, label: str) -> tuple[str, ...]:\n    if isinstance(names, str):\n        raise TypeError(f\"{label} must be a sequence of names, not a string\")\n    result = tuple(names)\n    if len(result) != count or any(not isinstance(name, str) or not name for name in result):\n        raise ValueError(f\"{label} must contain {count} non-empty string names\")\n    if len(set(result)) != len(result):\n        raise ValueError(f\"{label} must contain distinct names\")\n    return tuple(str(name) for name in result)\n\n\ndef _washout(value: int) -> int:\n    try:\n        count = operator.index(value)\n    except TypeError:\n        raise ValueError(\"washout must be a non-negative integer\") from None\n    if isinstance(value, bool) or count < 0:\n        raise ValueError(\"washout must be a non-negative integer\")\n    return count\n\n\nclass Model(nn.Module):\n    \"\"\"Wrap a named functional DAG in a common training/prediction workflow.\n\n    Supply ``inputs={name: symbolic_input}`` and ``outputs={name: symbolic_output}``,\n    or ``graph=existing_model`` with optional ordered ``input_names`` and\n    ``output_names``. The graph is registered once as :attr:`graph`; it remains\n    available for raw, already-normalized tensor execution. Existing symbolic,\n    parallel local-state and coupled ensemble backends are supported. Parallel\n    ports describe the full field; coupled members share one aggregate output.\n    Coupled fitting trains member readouts only. A custom feed-forward aggregator\n    is supplied/configured by the user and can be optimized separately with\n    ordinary PyTorch. Reservoirs hidden inside an aggregator require ordinary\n    stateful forward rather than explicit-state execution or forecasting.\n\n    ``fit(series)`` learns future prediction for one input/output of equal\n    width. ``fit(inputs, targets={output_name: tensor})`` instead fits explicit,\n    time-aligned targets; all streams include the same washout prefix. Declared intermediate heads may feed\n    later reservoirs; ``readout_targets`` supervises internal fitted heads\n    without adding them to public outputs.\n\n    ``forward`` accepts floating Torch tensors, preserves 2-D/3-D layout and\n    gradients, applies fitted scaling and returns original units. Calls carry\n    recurrent state by default; call :meth:`reset_state` between unrelated\n    sequences. One head returns a Tensor; several return a named dictionary.\n\n    Preprocessing is ``\"standard\"`` by default, any existing normalization\n    method, or ``\"off\"``/``None``. Statistics use training inputs/targets after\n    washout only. Implicit targets share their input's statistics. Feedback\n    automatically converts each output back to original units before applying\n    its destination input's scaling.\n\n    ``prediction_lead`` declares the physical target distance for each head:\n    input at step ``t`` predicts target at ``t + lead``. The default is one;\n    a mapping overrides named heads. ``feedback`` supplies explicit\n    :class:`Feedback` connections with independent graph-step delays. Without\n    connections, the first output automatically feeds the first input after\n    its prediction lead. An empty sequence leaves all inputs externally driven.\n\n    ``state_dict`` includes scaling, ordered port metadata and the observed tail;\n    reconstruct the same DAG before loading. ``tune`` compares candidates and\n    installs a refitted winner; its report exposes the Optuna study. Complete\n    ``save(\"run.pt\")`` and ``rd.load`` preserve the complete model; diagram\n    suffixes export its declared structure without running it.\n\n    With the optional ``dynamics`` extra, bare or named TSDynamics trajectories\n    use one shared observed clock. Explicit targets are aligned to each head's\n    physical prediction lead. Forecasts return one trajectory or a named\n    dictionary, with target component names and shared future times.\n    ``return_type=\"tensor\"`` keeps predictions on the model device.\n    Ordinary ``forward`` always uses Torch tensors.\n    Uneven timestamps are automatically interpolated with ``resample_method``\n    (linear, PCHIP or cubic); ``resample_dt`` controls the physical step.\n    \"\"\"\n\n    _fitted: torch.Tensor\n    _trajectory_system: tuple[Any, ...] | None\n\n    def __init__(\n        self,\n        *,\n        inputs: Mapping[str, SymbolicData] | None = None,\n        outputs: Mapping[str, SymbolicData] | None = None,\n        graph: nn.Module | None = None,\n        input_names: Sequence[str] | None = None,\n        output_names: Sequence[str] | None = None,\n        washout: int = 100,\n        preprocessing: Preprocessing = \"standard\",\n        input_transforms: Mapping[str, nn.Module] | None = None,\n        output_transforms: Mapping[str, nn.Module] | None = None,\n        prediction_lead: int | Mapping[str, int] = 1,\n        feedback: Sequence[Feedback] | None = None,\n        resample_dt: float | None = None,\n        resample_method: Literal[\"linear\", \"pchip\", \"cubic\"] = \"linear\",\n    ) -> None:\n        super().__init__()\n        self.washout = _washout(washout)\n        self.resample_dt, self.resample_method = validate_resampling_options(\n            resample_dt, resample_method\n        )\n        self._trajectory_context: dict[str, Any] | None = None\n        object.__setattr__(self, \"_trajectory_system\", None)\n        if preprocessing not in (\n            None,\n            \"off\",\n            \"minmax\",\n            \"standard\",\n            \"noncentered\",\n            \"meanpreserving\",\n        ):\n            raise ValueError(\"preprocessing must be a known normalization method, 'off', or None\")\n        self._preprocessing = None if preprocessing in (None, \"off\") else preprocessing\n        if graph is not None:\n            if inputs is not None or outputs is not None:\n                raise ValueError(\"Supply graph= or named symbolic inputs/outputs, not both\")\n            backend = workflow_backend(graph)\n            interface = backend.describe(graph)\n            in_names = (\n                input_names\n                if input_names is not None\n                else tuple(\n                    \"input\" if len(interface.input_widths) == 1 else f\"input_{i}\"\n                    for i in range(len(interface.input_widths))\n                )\n            )\n            out_names = (\n                output_names\n                if output_names is not None\n                else tuple(\n                    \"output\" if len(interface.output_widths) == 1 else f\"output_{i}\"\n                    for i in range(len(interface.output_widths))\n                )\n            )\n        else:\n            if input_names is not None or output_names is not None:\n                raise ValueError(\"input_names/output_names belong to the graph= constructor\")\n            if (\n                not isinstance(inputs, Mapping)\n                or not inputs\n                or not isinstance(outputs, Mapping)\n                or not outputs\n            ):\n                raise ValueError(\"Provide non-empty named symbolic inputs and outputs, or graph=\")\n            if not all(\n                isinstance(node, SymbolicData) for node in (*inputs.values(), *outputs.values())\n            ):\n                raise TypeError(\"inputs and outputs must map names to symbolic graph nodes\")\n            in_names, out_names = tuple(inputs), tuple(outputs)\n            _port_names(in_names, len(inputs), \"inputs\")\n            _port_names(out_names, len(outputs), \"outputs\")\n            graph = ESNModel(tuple(inputs.values()), tuple(outputs.values()))\n            backend = workflow_backend(graph)\n            interface = backend.describe(graph)\n        self.input_names = _port_names(in_names, len(interface.input_widths), \"input_names\")\n        self.output_names = _port_names(out_names, len(interface.output_widths), \"output_names\")\n        self.graph = graph\n        self._backend = backend\n        self._backend_interface_schema = interface.schema\n        self._backend_schema = backend.checkpoint_schema(graph, interface)\n        self._backend_references = interface.references\n        self._input_widths = interface.input_widths\n        self._output_widths = interface.output_widths\n        self._prediction_leads = prediction_leads(prediction_lead, self.output_names)\n        self._feedback = feedback_specs(feedback)\n        self._feedback_plan(validate_widths=self._feedback is not None)\n        method = cast(NormMethod, self._preprocessing or \"standard\")\n        overrides = []\n        for mapping, names in (\n            (input_transforms, self.input_names),\n            (output_transforms, self.output_names),\n        ):\n            if mapping is not None and (\n                not isinstance(mapping, Mapping) or set(mapping) - set(names)\n            ):\n                raise ValueError(\n                    f\"Transform override keys must be declared port names: {list(names)}\"\n                )\n            overrides.append(dict(mapping or {}))\n        self._custom_inputs = tuple(name in overrides[0] for name in self.input_names)\n        self._custom_outputs = tuple(name in overrides[1] for name in self.output_names)\n        originals = tuple(module for mapping in overrides for module in mapping.values())\n        if any(not isinstance(module, nn.Module) for module in originals):\n            raise TypeError(\"Transform overrides must be torch.nn.Module instances\")\n        validate_transform_ownership(graph, originals)\n        for mapping, names, widths in (\n            (overrides[0], self.input_names, self._input_widths),\n            (overrides[1], self.output_names, self._output_widths),\n        ):\n            for name, width in zip(names, widths):\n                if name in mapping:\n                    validate_custom_transform(mapping[name], width)\n        self.input_scalers = nn.ModuleList(\n            overrides[0].get(name, FittedNormalization(method)) for name in self.input_names\n        )\n        self.output_scalers = nn.ModuleList(\n            overrides[1].get(name, FittedNormalization(method)) for name in self.output_names\n        )\n        reference = module_reference(graph)\n        if reference is not None:\n            self.input_scalers.to(device=reference.device, dtype=reference.dtype)\n            self.output_scalers.to(device=reference.device, dtype=reference.dtype)\n        self._transform_schema = self._custom_transform_schema()\n        for group, masks, widths in (\n            (\"input\", self._custom_inputs, self._input_widths),\n            (\"output\", self._custom_outputs, self._output_widths),\n        ):\n            for index, (custom, width) in enumerate(zip(masks, widths)):\n                if custom:\n                    with torch.inference_mode(False):\n                        sample = (\n                            torch.zeros(1, 3, width)\n                            if reference is None\n                            else reference.new_zeros(1, 3, width)\n                        )\n                    self.register_buffer(f\"_{group}_transform_sample_{index}\", sample)\n        for index, width in enumerate(self._input_widths):\n            empty = torch.empty(0, width) if reference is None else reference.new_empty(0, width)\n            self.register_buffer(f\"_history_{index}\", empty)\n        self.register_buffer(\n            \"_fitted\", torch.tensor(False, device=None if reference is None else reference.device)\n        )\n        self._fitted_flag = False\n        self.register_load_state_dict_post_hook(self._synchronize_loaded_buffers)\n\n    def _synchronize_loaded_buffers(self, module: nn.Module, incompatible_keys: Any) -> None:\n        # PyTorch shares this key list across the whole loading tree. Missing\n        # sibling keys under strict=False do not prevent this graph's tensors\n        # from being assigned and must not skip its derived-buffer repair.\n        self._backend.synchronize_loaded_buffers(self.graph)\n\n    @property\n    def preprocessing(self) -> NormMethod | None:\n        \"\"\"The fallback policy; explicit transform overrides apply independently.\"\"\"\n        # Keep typing-only unions out of the captured forward graph.\n        return cast(\"NormMethod | None\", self._preprocessing)\n\n    def _custom_transform_schema(self) -> tuple[Any, ...]:\n        return tuple(\n            tuple(\n                transform_schema(module, width) if custom else None\n                for module, custom, width in zip(modules, masks, widths)\n            )\n            for modules, masks, widths in (\n                (self.input_scalers, self._custom_inputs, self._input_widths),\n                (self.output_scalers, self._custom_outputs, self._output_widths),\n            )\n        )\n\n    def _transform_active(self, *, output: bool, index: int) -> bool:\n        return (\n            self.preprocessing is not None\n            or (self._custom_outputs if output else self._custom_inputs)[index]\n        )\n\n    def _validate_transform_ownership(self) -> None:\n        validate_transform_ownership(\n            self.graph,\n            tuple(\n                module\n                for modules, masks in (\n                    (self.input_scalers, self._custom_inputs),\n                    (self.output_scalers, self._custom_outputs),\n                )\n                for module, custom in zip(modules, masks)\n                if custom\n            ),\n        )\n\n    @property\n    def is_fitted(self) -> bool:\n        \"\"\"Whether this workflow has completed fitting or restored a fitted checkpoint.\"\"\"\n        return self._fitted_flag\n\n    @property\n    def prediction_leads(self) -> dict[str, int]:\n        \"\"\"Physical target distances by public output name.\"\"\"\n        return dict(zip(self.output_names, self._prediction_leads))\n\n    @property\n    def feedback(self) -> tuple[Feedback, ...] | None:\n        \"\"\"Explicit connections, or ``None`` for the automatic first-port route.\"\"\"\n        return self._feedback\n\n    def _feedback_plan(self, *, validate_widths: bool = True) -> FeedbackPlan:\n        return feedback_plan(\n            self._feedback,\n            self._prediction_leads,\n            self.input_names,\n            self.output_names,\n            self._input_widths,\n            self._output_widths,\n            validate_widths=validate_widths,\n        )\n\n    @property\n    def internal_readout_names(self) -> tuple[str, ...]:\n        \"\"\"Target keys for internal fitted heads, without exposing extra predictions.\"\"\"\n        self._validate_ports()\n        self._backend.validate_fit(self.graph)\n        return tuple(name for name, _ in self._backend.internal_readouts(self.graph))\n\n    def _requires_complete_history(self) -> bool:\n        if self._backend.kind == \"parallel\":\n            return False\n        try:\n            validate_forecast_execution(self.graph, \"fast\")\n        except ValueError:\n            return True\n        return False\n\n    def _commit_forecast_states(self, states: ReservoirStates) -> None:\n        \"\"\"Store evolved state without turning it into a user-pinned restore.\"\"\"\n        reservoirs = {\n            name: layer\n            for name, layer in self.graph.named_modules()\n            if isinstance(layer, BaseReservoirLayer)\n        }\n        if set(states) != set(reservoirs):\n            raise RuntimeError(\"Forecast executor returned an inconsistent reservoir state schema\")\n        staged = {}\n        with torch.inference_mode(False), torch.no_grad():\n            for name, layer in reservoirs.items():\n                layer.cell.validate_state(states[name])\n                staged[name] = states[name].detach().clone()\n        for name, layer in reservoirs.items():\n            layer.reset_state()\n            layer.state = staged[name]\n\n    def _streams(\n        self,\n        data: Streams,\n        names: tuple[str, ...],\n        widths: tuple[int, ...],\n        label: str,\n        *,\n        finite: bool = False,\n        allow_empty: bool = False,\n    ) -> tuple[tuple[torch.Tensor, ...], bool]:\n        values: tuple[torch.Tensor, ...]\n        if isinstance(data, torch.Tensor):\n            if len(names) != 1:\n                raise ValueError(f\"{label} requires a mapping with keys {list(names)}\")\n            values = (data,)\n        elif isinstance(data, Mapping):\n            if set(data) != set(names):\n                raise ValueError(f\"{label} keys must be {list(names)}; got {list(data)}\")\n            values = tuple(data[name] for name in names)\n        else:\n            raise TypeError(f\"{label} must be a torch.Tensor or a named tensor mapping\")\n        if not all(isinstance(value, torch.Tensor) for value in values):\n            raise TypeError(f\"{label} values must be torch.Tensor instances\")\n        two_dimensional = values[0].ndim == 2\n        if any(value.ndim != values[0].ndim for value in values):\n            raise ValueError(f\"{label} streams must use the same 2-D or 3-D layout\")\n        canonical = tuple(value.unsqueeze(0) if two_dimensional else value for value in values)\n        validate_sequence_inputs(\n            canonical,\n            feature_sizes=widths,\n            reference=module_reference(self.graph),\n            label=label,\n            allow_empty=allow_empty,\n        )\n        if finite and any(not bool(torch.isfinite(value).all()) for value in canonical):\n            raise ValueError(f\"{label} must contain only finite values\")\n        return canonical, two_dimensional\n\n    def _require_scaling(self) -> None:\n        self._validate_ports()\n        if (\n            self.preprocessing is not None or any((*self._custom_inputs, *self._custom_outputs))\n        ) and not self.is_fitted:\n            raise RuntimeError(\"Model preprocessing is not fitted; call fit(training) first\")\n\n    def _validate_ports(self) -> None:\n        if self._custom_transform_schema() != self._transform_schema:\n            raise ValueError(\n                \"Custom transform registered structure changed; construct a matching Model\"\n            )\n        try:\n            interface = self._backend.describe(self.graph)\n            valid = (\n                interface.input_widths == self._input_widths\n                and interface.output_widths == self._output_widths\n                and interface.schema == self._backend_interface_schema\n                and len(interface.references) == len(self._backend_references)\n                and all(a is b for a, b in zip(interface.references, self._backend_references))\n            )\n        except (ValueError, TypeError, AttributeError):\n            valid = False\n        if not valid:\n            raise ValueError(\n                \"The raw graph's input/output ports changed; construct a new Model \"\n                \"with the updated named ports and backend structure before executing it\"\n            )\n\n    def _scaled_inputs(self, inputs: tuple[torch.Tensor, ...]) -> tuple[torch.Tensor, ...]:\n        return tuple(\n            (\n                apply_transform(scaler, value)\n                if self._transform_active(output=False, index=index)\n                else value\n            )\n            for index, (scaler, value) in enumerate(zip(self.input_scalers, inputs))\n        )\n\n    def _outputs(self, output: ModelOutput, two_dimensional: bool) -> WorkflowOutput:\n        values = output if isinstance(output, tuple) else (output,)\n        if len(values) != len(self.output_names):\n            raise RuntimeError(\"Graph output count no longer matches the declared named outputs\")\n        restored: list[torch.Tensor] = []\n        for scaler, value in zip(self.output_scalers, values):\n            value = (\n                apply_transform(scaler, value, inverse=True)\n                if self._transform_active(output=True, index=len(restored))\n                else value\n            )\n            restored.append(value.squeeze(0) if two_dimensional else value)\n        return restored[0] if len(restored) == 1 else dict(zip(self.output_names, restored))\n\n    def forward(self, inputs: Streams) -> WorkflowOutput:\n        \"\"\"Predict in original units, retaining gradients and carried recurrent state.\"\"\"\n        self._require_scaling()\n        values, was_2d = self._streams(inputs, self.input_names, self._input_widths, \"inputs\")\n        return self._outputs(self.graph(*self._scaled_inputs(values)), was_2d)\n\n    def forward_stateless(\n        self,\n        inputs: Streams,\n        *,\n        states: Mapping[str, torch.Tensor] | None = None,\n        compile: bool = False,\n    ) -> tuple[WorkflowOutput, ReservoirStates]:\n        \"\"\"Predict original units with caller-managed recurrent states and gradients.\"\"\"\n        self._require_scaling()\n        self._backend.validate_stateless(self.graph)\n        from resdag.core._hooks import call_with_states, has_execution_hooks, state_paths\n\n        if has_execution_hooks(self):\n            return cast(\n                tuple[WorkflowOutput, ReservoirStates],\n                call_with_states(\n                    self, (inputs,), states, state_paths(self, \"graph.\"), compile=compile\n                ),\n            )\n        values, was_2d = self._streams(inputs, self.input_names, self._input_widths, \"inputs\")\n        output, final = recurrent_graph(self.graph).forward_stateless(\n            *self._scaled_inputs(values), states=states, compile=compile\n        )\n        return self._outputs(output, was_2d), final\n\n    def reset_state(self) -> None:\n        \"\"\"Start the next ordinary forward from the reservoirs' configured reset states.\"\"\"\n        recurrent_graph(self.graph).reset_reservoirs()\n\n    def get_state(self) -> ReservoirStates:\n        \"\"\"Copy reservoir states, excluding a forecast's ephemeral feedback queues.\n\n        Forecast calls replay history and construct fresh delay queues. These\n        tensors alone do not resume a delayed forecast at its previous clock.\n        \"\"\"\n        return recurrent_graph(self.graph).get_state()\n\n    def set_state(self, states: Mapping[str, torch.Tensor], strict: bool = True) -> None:\n        \"\"\"Restore ordinary-forward reservoir states, not delayed-rollout queues.\"\"\"\n        recurrent_graph(self.graph).set_state(states, strict=strict)\n\n    def plot_model(\n        self,\n        *,\n        save_path: str | Path | None = None,\n        format: str | None = None,\n        show_shapes: bool = True,\n        show_trainable: bool = False,\n        rankdir: str = \"LR\",\n    ) -> Any:\n        \"\"\"Display a DAG in notebooks or export SVG/PNG/PDF/DOT without running it.\"\"\"\n        from resdag.core._diagram import plot_model\n\n        self._validate_ports()\n        return plot_model(\n            self,\n            save_path=save_path,\n            format=format,\n            show_shapes=show_shapes,\n            show_trainable=show_trainable,\n            rankdir=rankdir,\n        )\n\n    @property\n    def save_formats(self) -> tuple[str, ...]:\n        \"\"\"Supported complete-model checkpoint and diagram suffixes.\"\"\"\n        return (\"pt\", \"pth\", \"svg\", \"png\", \"pdf\", \"dot\")\n\n    def save(\n        self,\n        path: str | Path,\n        *,\n        format: str | None = None,\n        include_state: bool = True,\n        trusted: bool = False,\n        metadata: Mapping[str, Any] | None = None,\n        **diagram_options: Any,\n    ) -> Any:\n        \"\"\"Save a complete loadable model (.pt/.pth) or a diagram by suffix.\n\n        ``rd.load(path)`` reconstructs checkpoints without a prebuilt DAG.\n        Current ordinary-forward memory is included by default. Set\n        ``trusted=True`` only to bundle notebook-defined Python code; loading\n        such a bundle also requires explicit trust. Diagram formats are\n        SVG/PNG/PDF/DOT and accept :meth:`plot_model` options.\n        \"\"\"\n        destination = Path(path)\n        suffix = destination.suffix.lower().lstrip(\".\")\n        if format is not None and not isinstance(format, str):\n            raise TypeError(\"format must be a string or None\")\n        selected = format.lower() if isinstance(format, str) else suffix or \"pt\"\n        if selected not in self.save_formats or (suffix and suffix != selected):\n            raise ValueError(f\"Save format/suffix must agree and be one of {self.save_formats}\")\n        if not suffix:\n            destination = destination.with_suffix(f\".{selected}\")\n        if selected not in (\"pt\", \"pth\"):\n            if trusted or metadata is not None or not include_state:\n                raise ValueError(\n                    \"trusted, metadata and include_state options apply to model checkpoints\"\n                )\n            return self.plot_model(save_path=destination, format=selected, **diagram_options)\n        if diagram_options:\n            raise TypeError(\n                f\"Diagram options cannot be used with a model checkpoint: {list(diagram_options)}\"\n            )\n        from resdag.artifacts import save_model\n\n        self._validate_ports()\n        return save_model(\n            self, destination, include_state=include_state, trusted=trusted, metadata=metadata\n        )\n\n    def tune(\n        self,\n        training: Streams | Trajectory | Mapping[str, Trajectory],\n        targets: Streams | Trajectory | Mapping[str, Trajectory] | None = None,\n        *,\n        preset: Literal[\"quick\", \"balanced\", \"thorough\"] = \"balanced\",\n        n_trials: int | None = None,\n        horizon: int | None = None,\n        n_jobs: int = 1,\n        **options: Any,\n    ) -> Model:\n        \"\"\"Tune autonomous forecasts, refit the winner and return this model.\n\n        Requires ``resdag[hpo]``. The final 20% is held out while comparing\n        candidates, then the winner is refitted on all supplied data. Keep a\n        separate final test set. Built-in classic/OTT graphs have an automatic\n        rebuilding recipe. ``factory(params, seed)`` rebuilds custom DAGs;\n        without one, custom sizes and weights stay fixed and alpha/washout can vary.\n        ``search_space(trial)`` uses ordinary Optuna suggestions. Advanced\n        options and :attr:`tuning_report` are documented in the tuning guide.\n        A failure leaves this model unchanged. Tune before creating optimizers.\n        \"\"\"\n        from resdag.hpo import _require_optuna\n\n        _require_optuna()\n        from resdag.hpo.tuning import tune_model\n\n        tune_model(\n            self,\n            training,\n            targets,\n            preset=preset,\n            n_trials=n_trials,\n            horizon=horizon,\n            n_jobs=n_jobs,\n            **options,\n        )\n        return self\n\n    def fit(\n        self,\n        training: Streams | Trajectory | Mapping[str, Trajectory],\n        targets: Streams | Trajectory | Mapping[str, Trajectory] | None = None,\n        *,\n        readout_targets: Mapping[str, torch.Tensor] | None = None,\n    ) -> Model:\n        \"\"\"Fit public and internal heads transactionally and retain the original observed tail.\n\n        Implicit supervision pairs input ``t`` with observation\n        ``t + prediction_lead`` and retains the complete observed tail.\n        Explicit targets are already caller-aligned to input indices; declared\n        leads describe their physical timestamps without shifting those arrays.\n        Successful fitting resets streaming state. Failed fitting leaves the\n        existing graph, fitted preprocessing and cached history unchanged.\n        Bare or named TSDynamics trajectories share one physical input grid.\n        Explicit trajectory targets are sampled at origin + prediction_lead*dt;\n        tensors remain caller-aligned. Regression uses jointly supported origins\n        after absolute washout. Target source observations after the common input\n        endpoint are held out before interpolation. The cached tail includes the\n        final observed inputs, even after the last supervised origin. Tensor\n        refitting clears trajectory defaults on success.\n\n        ``readout_targets={\"stage1\": tensor}`` supervises internal readouts\n        without exposing them as outputs. Keys use the readout's ``name`` or\n        graph path; coupled members use ``models.<index>.<name>``. Tensors share\n        the complete input time axis, including washout, and express the desired\n        internal output units without automatic output scaling. For trajectory\n        inputs, align these tensors to the prepared shared input grid.\n        \"\"\"\n        self._validate_ports()\n        implicit = targets is None\n        if is_trajectory(training) or has_trajectory_port(training):\n            prepared = prepare_trajectory_ports(\n                training,\n                input_names=self.input_names,\n                input_widths=self._input_widths,\n                output_names=self.output_names,\n                output_widths=self._output_widths,\n                prediction_leads=self._prediction_leads,\n                targets=targets,\n                dt=self.resample_dt,\n                method=self.resample_method,\n            )\n            reference = module_reference(self.graph)\n            dtype = None if reference is None else reference.dtype\n            device = None if reference is None else reference.device\n            inputs = {\n                name: torch.tensor(data, dtype=dtype, device=device)\n                for name, data in zip(self.input_names, prepared.inputs)\n            }\n            labels = {\n                name: torch.tensor(data, dtype=dtype, device=device)\n                for name, data in zip(self.output_names, prepared.targets)\n            }\n            return self._fit_prepared(\n                inputs,\n                labels,\n                supervised_start=prepared.supervised_start,\n                supervised_stop=prepared.supervised_stop,\n                implicit=implicit,\n                trajectory_context=prepared.context,\n                trajectory_system=prepared.output_systems,\n                readout_targets=readout_targets,\n            )\n        if is_trajectory(targets) or has_trajectory_port(targets):\n            raise TypeError(\n                \"Trajectory targets require clocked Trajectory training inputs; \"\n                \"Tensor targets remain caller-aligned\"\n            )\n        values, was_2d = self._streams(\n            cast(Streams, training), self.input_names, self._input_widths, \"training\", finite=True\n        )\n        stop = values[0].shape[1]\n        if implicit:\n            if (\n                len(values) != 1\n                or len(self.output_names) != 1\n                or self._input_widths != self._output_widths\n            ):\n                raise ValueError(\n                    \"Implicit fitting requires one input/output of equal width; \"\n                    \"provide explicit named targets for custom graphs\"\n                )\n            lead = self._prediction_leads[0]\n            stop -= lead\n            labels = {\n                self.output_names[0]: (\n                    values[0][:, lead:].squeeze(0) if was_2d else values[0][:, lead:]\n                )\n            }\n        else:\n            target_values, targets_2d = self._streams(\n                cast(Streams, targets),\n                self.output_names,\n                self._output_widths,\n                \"targets\",\n                finite=True,\n            )\n            if targets_2d != was_2d or any(\n                value.shape[:2] != values[0].shape[:2] for value in target_values\n            ):\n                raise ValueError(\"Explicit targets must share training batch/time axes and layout\")\n            labels = {\n                name: value.squeeze(0) if was_2d else value\n                for name, value in zip(self.output_names, target_values)\n            }\n        return self._fit_prepared(\n            cast(Streams, training),\n            labels,\n            supervised_start=0,\n            supervised_stop=stop,\n            implicit=implicit,\n            readout_targets=readout_targets,\n        )\n\n    def _fit_prepared(\n        self,\n        training: Streams,\n        targets: Streams,\n        *,\n        supervised_start: int,\n        supervised_stop: int,\n        implicit: bool = False,\n        readout_targets: Mapping[str, torch.Tensor] | None = None,\n        trajectory_context: dict[str, Any] | None = None,\n        trajectory_system: tuple[Any, ...] | None = None,\n    ) -> Model:\n        \"\"\"Fit an admitted origin window, retaining every observed input row.\n\n        Private adapters supply already aligned labels for exactly\n        ``supervised_start:supervised_stop``. Absolute washout is applied once.\n        This separates regression support from the complete observed clock;\n        purging future labels must not move the cached forecasting boundary.\n        \"\"\"\n        self._validate_ports()\n        self._backend.validate_fit(self.graph)\n        self._validate_transform_ownership()\n        complete_history = self._requires_complete_history()\n        values, was_2d = self._streams(\n            training, self.input_names, self._input_widths, \"training\", finite=True\n        )\n        if (\n            type(supervised_start) is not int\n            or type(supervised_stop) is not int\n            or not 0 <= supervised_start < supervised_stop <= values[0].shape[1]\n        ):\n            raise ValueError(\n                \"Supervised origins must be a nonempty interval within observed inputs\"\n            )\n        target_values, targets_2d = self._streams(\n            targets, self.output_names, self._output_widths, \"targets\", finite=True\n        )\n        if targets_2d != was_2d or any(\n            value.shape[:2] != (values[0].shape[0], supervised_stop - supervised_start)\n            for value in target_values\n        ):\n            raise ValueError(\"Prepared targets must match the admitted origin window and layout\")\n        internal_heads = self._backend.internal_readouts(self.graph)\n        internal_targets: dict[str, torch.Tensor] = {}\n        if internal_heads:\n            if readout_targets is None:\n                raise ValueError(\n                    \"Provide readout_targets for internal fitted readouts; \"\n                    f\"expected {[name for name, _ in internal_heads]}\"\n                )\n            internal_values, internal_2d = self._streams(\n                readout_targets,\n                tuple(name for name, _ in internal_heads),\n                tuple(head.out_features for _, head in internal_heads),\n                \"readout_targets\",\n                finite=True,\n            )\n            if internal_2d != was_2d or any(\n                value.shape[:2] != values[0].shape[:2] for value in internal_values\n            ):\n                raise ValueError(\"readout_targets must share the complete input batch/time axes\")\n            internal_targets = dict(zip((name for name, _ in internal_heads), internal_values))\n        elif readout_targets is not None and (\n            not isinstance(readout_targets, Mapping) or len(readout_targets)\n        ):\n            raise ValueError(\"This graph has no internal fitted readouts for readout_targets\")\n        fit_start = max(self.washout, supervised_start)\n        train_inputs = tuple(value[:, :supervised_stop] for value in values)\n        target_values = tuple(value[:, fit_start - supervised_start :] for value in target_values)\n        if train_inputs[0].shape[1] <= fit_start:\n            raise ValueError(\"Training must contain washout plus at least one input/target pair\")\n        fitting_inputs = tuple(value[:, fit_start:] for value in train_inputs)\n        # Stage statistics and algebraic fitting on independent objects. Committing\n        # weights into the original graph preserves existing optimizer references.\n        with torch.inference_mode(False):\n            input_scalers = [copy.deepcopy(module) for module in self.input_scalers]\n            output_scalers = [copy.deepcopy(module) for module in self.output_scalers]\n        samples: dict[str, torch.Tensor] = {}\n        for group, staged_scalers, live_scalers, masks, fitting in (\n            (\"input\", input_scalers, self.input_scalers, self._custom_inputs, fitting_inputs),\n            (\"output\", output_scalers, self.output_scalers, self._custom_outputs, target_values),\n        ):\n            for index, (staged_scaler, original, custom, data) in enumerate(\n                zip(staged_scalers, live_scalers, masks, fitting)\n            ):\n                if custom:\n                    staged_scalers[index], samples[f\"_{group}_transform_sample_{index}\"] = (\n                        stage_transform(original, data)\n                    )\n                elif self.preprocessing is not None:\n                    # Unspecified implicit outputs retain the original input\n                    # supervised window even when their input has a custom map.\n                    source = fitting_inputs[0] if group == \"output\" and implicit else data\n                    cast(FittedNormalization, staged_scaler).fit(source)\n\n        def transformed(\n            modules: list[nn.Module], streams: tuple[torch.Tensor, ...], *, output: bool\n        ) -> tuple[torch.Tensor, ...]:\n            result = []\n            for index, (module, data) in enumerate(zip(modules, streams)):\n                with evaluating(module), torch.no_grad():\n                    value = (\n                        apply_transform(module, data)\n                        if self._transform_active(output=output, index=index)\n                        else data\n                    )\n                if not bool(torch.isfinite(value).all()):\n                    raise ValueError(\"Preprocessing produced nonfinite training values\")\n                result.append(value)\n            return tuple(result)\n\n        scaled = transformed(input_scalers, train_inputs, output=False)\n        scaled_targets = transformed(output_scalers, target_values, output=True)\n        with torch.inference_mode(False), torch.no_grad():\n            # Fitting starts from reset state. Exclude only transient carried\n            # states, which may retain non-leaf autograd history and therefore\n            # cannot be deep-copied. The live graph remains untouched if the\n            # staged fit fails, including its still-differentiable states.\n            transient_states = {\n                id(layer.state): None\n                for layer in self.graph.modules()\n                if isinstance(layer, BaseReservoirLayer) and layer.state is not None\n            }\n            candidate = copy.deepcopy(self.graph, transient_states)\n            self._backend.fit_prefix(\n                candidate,\n                scaled,\n                scaled_targets,\n                fit_start=fit_start,\n                readout_targets={\n                    name: value[:, fit_start:supervised_stop]\n                    for name, value in internal_targets.items()\n                },\n            )\n        history = []\n        tail_length = self.washout + self._feedback_plan(validate_widths=False).required_history\n        with torch.inference_mode(False), torch.no_grad():\n            for value in values:\n                tail = (value if complete_history else value[:, -tail_length:]).detach().clone()\n                history.append(tail.squeeze(0) if was_2d else tail)\n        # Solve reports are intentionally not checkpoint state. Transfer them\n        # from the successful staged fit by graph path without replacing live\n        # readouts/parameters, or losing diagnostics at the state-dict commit.\n        staged_reports: dict[str, Any] = {\n            path: layer.last_solve\n            for path, layer in candidate.named_modules()\n            if isinstance(layer, (AutoReadoutLayer, LSMRReadoutLayer))\n        }\n        live_solve_readouts = {\n            path: layer\n            for path, layer in self.graph.named_modules()\n            if isinstance(layer, (AutoReadoutLayer, LSMRReadoutLayer))\n        }\n        if staged_reports.keys() != live_solve_readouts.keys():\n            raise RuntimeError(\"Staged readout diagnostic paths do not match the live graph\")\n        with torch.inference_mode(False):\n            self.graph.load_state_dict(candidate.state_dict())\n        recurrent_graph(self.graph).reset_reservoirs()\n        for staged_scalers, previous, masks in (\n            (input_scalers, self.input_scalers, self._custom_inputs),\n            (output_scalers, self.output_scalers, self._custom_outputs),\n        ):\n            for staged_scaler, original, custom in zip(staged_scalers, previous, masks):\n                if custom:\n                    commit_transform_state(original, staged_scaler)\n                else:\n                    with torch.inference_mode(False):\n                        original.load_state_dict(staged_scaler.state_dict())\n        for name, sample in samples.items():\n            setattr(self, name, sample)\n        for index, tail in enumerate(history):\n            setattr(self, f\"_history_{index}\", tail)\n        self._fitted_flag = True\n        with torch.inference_mode(False):\n            self._fitted = torch.ones((), dtype=torch.bool, device=values[0].device)\n        self._trajectory_context = trajectory_context\n        object.__setattr__(self, \"_trajectory_system\", trajectory_system)\n        for path, layer in live_solve_readouts.items():\n            layer.last_solve = staged_reports[path]\n        return self\n\n    def _feedback_scaling_matches(self, input_index: int = 0, output_index: int = 0) -> bool:\n        if any((*self._custom_inputs, *self._custom_outputs)):\n            return False\n        if self.preprocessing is None:\n            return True\n        left, right = cast(FittedNormalization, self.input_scalers[input_index]), cast(\n            FittedNormalization, self.output_scalers[output_index]\n        )\n        return left.method == right.method and all(\n            torch.equal(a, b) for a, b in zip(left.buffers(), right.buffers())\n        )\n\n    def forecast(\n        self,\n        history: Streams | Trajectory | Mapping[str, Trajectory] | None = None,\n        *,\n        horizon: int,\n        future_inputs: Streams | Trajectory | Mapping[str, Trajectory] | None = None,\n        return_warmup: bool = False,\n        compile: bool = False,\n        execution: Literal[\"fast\", \"history\"] = \"fast\",\n        return_type: Literal[\"auto\", \"tensor\", \"trajectory\"] = \"auto\",\n    ) -> WorkflowOutput | Trajectory | dict[str, Trajectory]:\n        \"\"\"Return named heads aligned to the immediate unseen physical sample.\n\n        ``future_inputs`` names every input without a feedback connection.\n        Drivers start immediately after history and require\n        ``max(0, horizon - min(prediction_leads))`` samples. With the default\n        next-step head this is ``horizon - 1``. History must contain at least\n        the largest prediction lead and feedback delay. Warmup predictions\n        already provide the first unseen samples; they are never skipped.\n        ``return_warmup`` prepends predictions on the shared physical timeline\n        starting at history index ``max(prediction_leads)``.\n\n        Every call rebuilds pending feedback from history and temporarily\n        disables training noise. ``execution='fast'`` requires pointwise graph\n        modules or explicit reservoir adapters. ``'history'`` replays the full\n        growing input prefix for pure causal sequence modules, at higher cost.\n        Custom modules may declare ``supports_framewise=True`` when appropriate.\n        Compiled forecasting is currently available for symbolic graphs only;\n        parallel and coupled backends require ``compile=False``.\n\n        ``return_type=\"auto\"`` returns a TSDynamics trajectory after trajectory\n        fitting or with trajectory history; otherwise it returns tensors.\n        ``\"tensor\"`` avoids conversion to NumPy/CPU. A selected trajectory result\n        needs timestamped history or the cached training context; a new tensor\n        history has no absolute clock. Trajectory history is resampled to the\n        fitted physical step and must retain fitted component names/order.\n        \"\"\"\n        self._require_scaling()\n        if return_type not in (\"auto\", \"tensor\", \"trajectory\"):\n            raise ValueError(\"return_type must be 'auto', 'tensor', or 'trajectory'\")\n        horizon = positive_step_count(horizon, \"horizon\")\n        self._backend.validate_forecast(self.graph, compile=compile)\n        validate_forecast_execution(self.graph, execution, compile=compile)\n        from resdag.core._hooks import (\n            eager_with_hooks,\n            forecast_owner,\n            has_execution_hooks,\n            original_outputs,\n        )\n\n        owner = forecast_owner(self)\n        hooked = has_execution_hooks(owner)\n        if hooked:\n            eager_with_hooks(compile)\n            compile = False\n        plan = self._feedback_plan()\n        if any(not layer.is_fitted for _, layer in self._backend.fitted_readouts(self.graph)):\n            raise RuntimeError(\n                \"Forecast requires fitted terminal readouts; call fit(training) first\"\n            )\n        context = self._trajectory_context\n        system = self._trajectory_system\n        cached_history = history is None\n        clocked_history = is_trajectory(history) or has_trajectory_port(history)\n        if clocked_history:\n            prepared = prepare_trajectory_port_history(\n                history,\n                input_names=self.input_names,\n                input_widths=self._input_widths,\n                output_names=self.output_names,\n                output_widths=self._output_widths,\n                context=context,\n                dt=self.resample_dt,\n                method=self.resample_method,\n                output_systems=system,\n            )\n            context, system = prepared.context, prepared.output_systems\n            reference = module_reference(self.graph)\n            history = {\n                name: torch.tensor(\n                    data,\n                    dtype=None if reference is None else reference.dtype,\n                    device=None if reference is None else reference.device,\n                )\n                for name, data in zip(self.input_names, prepared.inputs)\n            }\n        trajectory_output = return_type == \"trajectory\" or (\n            return_type == \"auto\" and context is not None\n        )\n        if trajectory_output:\n            if context is None or (not cached_history and not clocked_history):\n                raise ValueError(\n                    \"Trajectory output needs timestamped trajectory history or cached \"\n                    \"trajectory fitting history; pass a Trajectory or return_type='tensor'\"\n                )\n            if set(context[\"outputs\"]) != set(self.output_names):\n                raise ValueError(\n                    \"Trajectory output needs per-head target component metadata; \"\n                    \"fit Trajectory targets or choose return_type='tensor'\"\n                )\n            trajectory_type()  # Optional dependency must fail before graph hooks execute.\n        if history is None:\n            if not self.is_fitted:\n                raise RuntimeError(\"No cached history; provide history or call fit(training) first\")\n            history = {\n                name: getattr(self, f\"_history_{index}\")\n                for index, name in enumerate(self.input_names)\n            }\n        values, was_2d = self._streams(\n            cast(Streams, history), self.input_names, self._input_widths, \"history\", finite=True\n        )\n        if values[0].shape[1] < plan.required_history:\n            raise ValueError(\n                f\"history needs at least {plan.required_history} samples to seed all \"\n                \"prediction leads and feedback delays\"\n            )\n        driver_names = tuple(self.input_names[index] for index in plan.driver_indices)\n        driver_widths = tuple(self._input_widths[index] for index in plan.driver_indices)\n        steps = plan.future_steps(horizon)\n        drivers: tuple[torch.Tensor, ...]\n        if not driver_names:\n            if future_inputs is not None:\n                raise ValueError(\"This graph has no future driver inputs\")\n            drivers = ()\n        elif future_inputs is None:\n            if steps:\n                raise ValueError(f\"future_inputs requires driver keys {list(driver_names)}\")\n            drivers = tuple(values[index][:, :0] for index in plan.driver_indices)\n        else:\n            if is_trajectory(future_inputs) or has_trajectory_port(future_inputs):\n                if context is None or (not cached_history and not clocked_history):\n                    raise ValueError(\n                        \"Trajectory drivers require timestamped or cached trajectory history; \"\n                        \"new Tensor history has no absolute clock\"\n                    )\n                arrays = prepare_trajectory_port_drivers(\n                    future_inputs,\n                    input_names=driver_names,\n                    input_widths=driver_widths,\n                    last_time=context[\"clock\"][\"last_time\"],\n                    dt=context[\"clock\"][\"dt\"],\n                    steps=steps,\n                    method=self.resample_method,\n                    input_records=context[\"inputs\"],\n                )\n                future_inputs = {\n                    name: torch.tensor(data, device=values[0].device, dtype=values[0].dtype)\n                    for name, data in zip(driver_names, arrays)\n                }\n            drivers, _ = self._streams(\n                cast(Streams, future_inputs),\n                driver_names,\n                driver_widths,\n                \"future_inputs\",\n                finite=True,\n                allow_empty=True,\n            )\n            if drivers[0].shape[0] != values[0].shape[0] or drivers[0].shape[1] < steps:\n                raise ValueError(\n                    f\"future_inputs must match the history batch and contain at least {steps} samples\"\n                )\n        times = None\n        if trajectory_output:\n            assert context is not None\n            times = trajectory_port_forecast_times(\n                context,\n                horizon,\n                history_length=values[0].shape[1],\n                warmup_lead=max(plan.leads),\n                return_warmup=return_warmup,\n            )\n        default_route = (\n            len(plan.routes) == 1\n            and plan.routes[0] == FeedbackRoute(0, 0, 1)\n            and all(lead == 1 for lead in plan.leads)\n        )\n        final_states = None\n        output: ModelOutput\n        with evaluating(owner):\n            if not hooked and drivers and drivers[0].shape[1]:\n                drivers = tuple(\n                    (\n                        apply_transform(self.input_scalers[index], value)\n                        if self._transform_active(output=False, index=index)\n                        else value\n                    )\n                    for index, value in zip(plan.driver_indices, drivers)\n                )\n            if hooked:\n                executor = ForecastSequenceExecutor(\n                    self.graph, execution, workflow=self, owner=owner\n                )\n                output, final_states = feedback_rollout(\n                    executor,\n                    values,\n                    drivers,\n                    plan,\n                    lambda route, value: value,\n                    horizon=horizon,\n                    return_warmup=return_warmup,\n                )\n            elif execution == \"fast\" and default_route and self._feedback_scaling_matches():\n                output = self._backend.forecast(\n                    self.graph,\n                    self._scaled_inputs(values),\n                    drivers or None,\n                    horizon=horizon,\n                    return_warmup=return_warmup,\n                    compile=compile,\n                )\n            else:\n                executor = ForecastSequenceExecutor(self.graph, execution, compile=compile)\n\n                def bridge(route: FeedbackRoute, value: torch.Tensor) -> torch.Tensor:\n                    if self._transform_active(output=True, index=route.output_index):\n                        value = apply_transform(\n                            self.output_scalers[route.output_index], value, inverse=True\n                        )\n                    if self._transform_active(output=False, index=route.input_index):\n                        value = apply_transform(self.input_scalers[route.input_index], value)\n                    return value\n\n                output, final_states = feedback_rollout(\n                    executor,\n                    self._scaled_inputs(values),\n                    drivers,\n                    plan,\n                    bridge,\n                    horizon=horizon,\n                    return_warmup=return_warmup,\n                )\n            result = (\n                original_outputs(cast(tuple[torch.Tensor, ...], output), self.output_names, was_2d)\n                if hooked\n                else self._outputs(output, was_2d)\n            )\n        if not trajectory_output:\n            if final_states is not None:\n                self._commit_forecast_states(final_states)\n            return result\n        assert context is not None and times is not None\n        # NumPy has no bfloat16 dtype. Conversion is confined to this explicit\n        # CPU result boundary; tensor forecasts retain their device and dtype.\n        result_values = (\n            {self.output_names[0]: result} if isinstance(result, torch.Tensor) else result\n        )\n        result_arrays = {}\n        for name, value in result_values.items():\n            numpy_dtype = torch.float32 if value.dtype == torch.bfloat16 else value.dtype\n            result_arrays[name] = value.detach().to(device=\"cpu\", dtype=numpy_dtype).numpy()\n        trajectory = forecast_trajectory_ports(\n            result_arrays,\n            context,\n            output_names=self.output_names,\n            output_systems=system,\n            times=times,\n        )\n        if final_states is not None:\n            self._commit_forecast_states(final_states)\n        return trajectory\n\n    def get_extra_state(self) -> dict[str, Any]:\n        \"\"\"Checkpoint metadata prevents silent remapping of equal-width ports.\"\"\"\n        return {\n            \"version\": 2,\n            \"input_names\": self.input_names,\n            \"output_names\": self.output_names,\n            \"input_widths\": self._input_widths,\n            \"output_widths\": self._output_widths,\n            \"backend\": copy.deepcopy(self._backend_schema),\n            \"preprocessing\": self.preprocessing,\n            \"transforms\": copy.deepcopy(self._transform_schema),\n            \"washout\": self.washout,\n            \"prediction_lead\": self.prediction_leads,\n            \"feedback\": (\n                None\n                if self._feedback is None\n                else [\n                    {\"output\": route.output, \"input\": route.input, \"delay\": route.delay}\n                    for route in self._feedback\n                ]\n            ),\n            \"resample_dt\": self.resample_dt,\n            \"resample_method\": self.resample_method,\n            \"trajectory\": copy.deepcopy(self._trajectory_context),\n        }\n\n    def _checkpoint_feedback(\n        self, state: dict[str, Any]\n    ) -> tuple[tuple[int, ...], tuple[Feedback, ...] | None]:\n        leads = prediction_leads(state[\"prediction_lead\"], self.output_names)\n        saved = state[\"feedback\"]\n        specs = None\n        if saved is not None:\n            if not isinstance(saved, (list, tuple)) or any(\n                not isinstance(route, dict) or set(route) != {\"output\", \"input\", \"delay\"}\n                for route in saved\n            ):\n                raise ValueError(\"feedback must contain output/input/delay connection records\")\n            specs = tuple(\n                Feedback(route[\"output\"], route[\"input\"], route[\"delay\"]) for route in saved\n            )\n        feedback_plan(\n            specs,\n            leads,\n            self.input_names,\n            self.output_names,\n            self._input_widths,\n            self._output_widths,\n            validate_widths=specs is not None,\n        )\n        return leads, specs\n\n    def _validate_metadata(self, state: Any) -> None:\n        if (\n            not isinstance(state, dict)\n            or type(state.get(\"version\")) is not int\n            or state[\"version\"] != 2\n        ):\n            raise RuntimeError(\n                \"Model checkpoint requires current metadata version 2; \"\n                \"reconstruct and refit models saved with older metadata\"\n            )\n        if set(state) != {\n            \"version\",\n            \"input_names\",\n            \"output_names\",\n            \"input_widths\",\n            \"output_widths\",\n            \"backend\",\n            \"preprocessing\",\n            \"transforms\",\n            \"washout\",\n            \"prediction_lead\",\n            \"feedback\",\n            \"resample_dt\",\n            \"resample_method\",\n            \"trajectory\",\n        }:\n            raise RuntimeError(\n                \"Invalid or unsupported older Model checkpoint metadata fields; \"\n                \"reconstruct and refit the model\"\n            )\n        if state[\"backend\"] != self._backend_schema:\n            raise RuntimeError(\n                \"Model checkpoint backend schema differs from this graph; reconstruct \"\n                \"matching backend geometry, members and aggregation\"\n            )\n        if state.get(\"transforms\") != self._transform_schema:\n            raise RuntimeError(\n                \"Model checkpoint custom transform schema differs; reconstruct matching port modules\"\n            )\n        for key, expected in (\n            (\"input_names\", self.input_names),\n            (\"output_names\", self.output_names),\n            (\"input_widths\", self._input_widths),\n            (\"output_widths\", self._output_widths),\n        ):\n            if state.get(key) != expected:\n                raise RuntimeError(\n                    f\"Model checkpoint {key} differs from this graph; reconstruct matching named ports\"\n                )\n        if state.get(\"preprocessing\") not in (\n            None,\n            \"minmax\",\n            \"standard\",\n            \"noncentered\",\n            \"meanpreserving\",\n        ):\n            raise RuntimeError(\"Invalid Model checkpoint preprocessing\")\n        try:\n            _washout(cast(int, state.get(\"washout\")))\n        except ValueError as error:\n            raise RuntimeError(\"Invalid Model checkpoint washout\") from error\n        try:\n            self._checkpoint_feedback(state)\n        except (ValueError, TypeError) as error:\n            raise RuntimeError(f\"Invalid Model checkpoint feedback: {error}\") from error\n        try:\n            validate_resampling_options(state[\"resample_dt\"], state[\"resample_method\"])\n            if state.get(\"trajectory\") is not None:\n                validate_trajectory_ports_context(\n                    state[\"trajectory\"],\n                    self.input_names,\n                    self._input_widths,\n                    self.output_names,\n                    self._output_widths,\n                    self._checkpoint_feedback(state)[0],\n                )\n        except (TypeError, ValueError) as error:\n            raise RuntimeError(\n                f\"Invalid Model checkpoint trajectory configuration: {error}\"\n            ) from error\n\n    def set_extra_state(self, state: Any) -> None:\n        \"\"\"Restore workflow configuration after validating the named graph schema.\"\"\"\n        self._validate_metadata(state)\n        self._preprocessing, self.washout = state[\"preprocessing\"], state[\"washout\"]\n        self._prediction_leads, self._feedback = self._checkpoint_feedback(state)\n        self.resample_dt, self.resample_method = validate_resampling_options(\n            state[\"resample_dt\"], state[\"resample_method\"]\n        )\n        self._trajectory_context = (\n            validate_trajectory_ports_context(\n                state[\"trajectory\"],\n                self.input_names,\n                self._input_widths,\n                self.output_names,\n                self._output_widths,\n                self._prediction_leads,\n            )\n            if state.get(\"trajectory\") is not None\n            else None\n        )\n        object.__setattr__(self, \"_trajectory_system\", None)\n\n    def _load_from_state_dict(\n        self,\n        state_dict: dict[str, Any],\n        prefix: str,\n        local_metadata: dict[str, Any],\n        strict: bool,\n        missing_keys: list[str],\n        unexpected_keys: list[str],\n        error_msgs: list[str],\n    ) -> None:\n        self._validate_transform_ownership()\n        metadata = state_dict.get(prefix + \"_extra_state\")\n        self._validate_metadata(metadata)\n        metadata = cast(dict[str, Any], metadata)\n        fitted = state_dict.get(prefix + \"_fitted\")\n        if (\n            not isinstance(fitted, torch.Tensor)\n            or fitted.shape != ()\n            or fitted.dtype != torch.bool\n            or fitted.device.type == \"meta\"\n        ):\n            raise RuntimeError(\"Invalid Model checkpoint fitted flag\")\n        fitted_flag = bool(fitted.item())\n        if metadata.get(\"trajectory\") is not None and not fitted_flag:\n            raise RuntimeError(\"Invalid Model checkpoint: trajectory history requires fitted model\")\n        if fitted_flag:\n            for path, _ in self._backend.fitted_readouts(self.graph):\n                flag = state_dict.get(prefix + f\"graph.{path}._is_fitted\")\n                if (\n                    not isinstance(flag, torch.Tensor)\n                    or flag.shape != ()\n                    or flag.dtype != torch.bool\n                    or flag.device.type == \"meta\"\n                    or not bool(flag.item())\n                ):\n                    raise RuntimeError(\n                        \"Invalid Model checkpoint: fitted workflow requires fitted readouts\"\n                    )\n        method = cast(NormMethod, metadata[\"preprocessing\"] or \"standard\")\n        custom_state: dict[str, torch.Tensor] = {}\n        # Standalone normalization restores unknown widths/rules. The surrounding\n        # named graph fixes both; preflight all scalers before mutating weights.\n        for group, scalers, widths, masks in (\n            (\"input_scalers\", self.input_scalers, self._input_widths, self._custom_inputs),\n            (\"output_scalers\", self.output_scalers, self._output_widths, self._custom_outputs),\n        ):\n            for index, (scaler, width, custom) in enumerate(zip(scalers, widths, masks)):\n                stem = prefix + f\"{group}.{index}.\"\n                if custom:\n                    sample_name = f\"_{'input' if group == 'input_scalers' else 'output'}_transform_sample_{index}\"\n                    sample = state_dict.get(prefix + sample_name)\n                    destination_sample = getattr(self, sample_name)\n                    assign = local_metadata.get(\"assign_to_params_buffers\", False)\n                    if (\n                        isinstance(sample, torch.Tensor)\n                        and not assign\n                        and sample.device.type != \"meta\"\n                    ):\n                        with torch.inference_mode(False), torch.no_grad():\n                            sample = sample.to(destination_sample, copy=True)\n                    try:\n                        clean, sample = checkpoint_transform(\n                            scaler,\n                            {\n                                key[len(stem) :]: value\n                                for key, value in state_dict.items()\n                                if key.startswith(stem)\n                            },\n                            sample,\n                            width,\n                            fitted=fitted_flag,\n                            assign=assign,\n                        )\n                    except (ValueError, TypeError, RuntimeError) as error:\n                        raise RuntimeError(\n                            f\"Invalid Model checkpoint custom transform {group}.{index}: {error}\"\n                        ) from error\n                    custom_state.update({stem + key: value for key, value in clean.items()})\n                    custom_state[prefix + sample_name] = sample\n                    continue\n                scaler_state = {\n                    key: state_dict[stem + key]\n                    for key in (\"_method_code\", \"_stat0\", \"_stat1\")\n                    if stem + key in state_dict\n                }\n                reference = cast(FittedNormalization, scaler)._stat0\n                with torch.inference_mode(False):\n                    probe = FittedNormalization(method).to(reference)\n                    probe.load_state_dict(\n                        scaler_state, assign=local_metadata.get(\"assign_to_params_buffers\", False)\n                    )\n                expected_width = width if fitted_flag and metadata[\"preprocessing\"] else None\n                if probe.method != method or probe.n_features != expected_width:\n                    raise RuntimeError(\n                        f\"Invalid Model checkpoint {group}: preprocessing method, feature \"\n                        \"width and fitted statistics must match the declared graph schema\"\n                    )\n        staged = []\n        for index, width in enumerate(self._input_widths):\n            key = prefix + f\"_history_{index}\"\n            if key not in state_dict:\n                raise RuntimeError(\"Model checkpoint is missing its cached history\")\n            value = state_dict[key]\n            if (\n                not isinstance(value, torch.Tensor)\n                or not value.is_floating_point()\n                or value.ndim not in (2, 3)\n                or value.shape[-1] != width\n                or value.device.type == \"meta\"\n                or not bool(torch.isfinite(value).all())\n            ):\n                raise RuntimeError(\"Invalid Model checkpoint history\")\n            with torch.inference_mode(False), torch.no_grad():\n                destination = getattr(self, f\"_history_{index}\")\n                converted = (\n                    value.detach().clone()\n                    if local_metadata.get(\"assign_to_params_buffers\", False)\n                    else value.to(destination, copy=True)\n                )\n                if not bool(torch.isfinite(converted).all()):\n                    raise RuntimeError(\"Model checkpoint history overflows the destination dtype\")\n                staged.append(converted)\n        if any(value.ndim != staged[0].ndim for value in staged):\n            raise RuntimeError(\"Invalid Model checkpoint history: input layouts differ\")\n        canonical = tuple(value.unsqueeze(0) if value.ndim == 2 else value for value in staged)\n        if metadata.get(\"trajectory\") is not None and (\n            staged[0].ndim != 2\n            or canonical[0].shape[1] > metadata[\"trajectory\"][\"clock\"][\"n_samples\"]\n        ):\n            raise RuntimeError(\"Invalid Model checkpoint trajectory history layout/count\")\n        try:\n            validate_sequence_inputs(\n                canonical,\n                feature_sizes=self._input_widths,\n                label=\"checkpoint history\",\n                allow_empty=not fitted_flag,\n            )\n        except (ValueError, TypeError) as error:\n            raise RuntimeError(f\"Invalid Model checkpoint history: {error}\") from error\n        with torch.inference_mode(False):\n            # The recursive Module loader consumes this same local mapping for\n            # child tensors. Install only fully preflighted normal tensors.\n            state_dict.update(custom_state)\n            for name, value in custom_state.items():\n                local_name = name.removeprefix(prefix)\n                if local_name.startswith((\"_input_transform_sample_\", \"_output_transform_sample_\")):\n                    setattr(self, local_name, torch.empty_like(value))\n            state_dict = dict(state_dict)\n            for index, value in enumerate(staged):\n                setattr(self, f\"_history_{index}\", torch.empty_like(value))\n                state_dict[prefix + f\"_history_{index}\"] = value\n            self._fitted = torch.empty_like(self._fitted)\n            state_dict[prefix + \"_fitted\"] = fitted.detach().clone()\n            super()._load_from_state_dict(\n                state_dict,\n                prefix,\n                local_metadata,\n                strict,\n                missing_keys,\n                unexpected_keys,\n                error_msgs,\n            )\n        self._fitted_flag = bool(self._fitted.item())\n"
      }
    }
  },
  "summary": {
    "all_hashes_exact": true,
    "comparisons": [
      {
        "all_hashes_exact": true,
        "case": "b1-p8",
        "fit_seconds": {
          "baseline_seconds": 0.010665208499631262,
          "candidate_seconds": 0.010867708000660059,
          "speedup": 0.9813668621740207
        },
        "history_forecast_seconds": {
          "baseline_seconds": 0.007423311999446014,
          "candidate_seconds": 0.006758916000762838,
          "speedup": 1.0982991945170186
        },
        "round": 0
      },
      {
        "all_hashes_exact": true,
        "case": "b1-p64",
        "fit_seconds": {
          "baseline_seconds": 0.05214154200075427,
          "candidate_seconds": 0.053610041501087835,
          "speedup": 0.9726077529653887
        },
        "history_forecast_seconds": {
          "baseline_seconds": 0.021272187999784364,
          "candidate_seconds": 0.020426770999620203,
          "speedup": 1.0413876965762177
        },
        "round": 0
      },
      {
        "all_hashes_exact": true,
        "case": "b4-p8",
        "fit_seconds": {
          "baseline_seconds": 0.02824704199883854,
          "candidate_seconds": 0.029533103999710875,
          "speedup": 0.9564535444399977
        },
        "history_forecast_seconds": {
          "baseline_seconds": 0.013616083500892273,
          "candidate_seconds": 0.012422791500284802,
          "speedup": 1.09605667136731
        },
        "round": 0
      },
      {
        "all_hashes_exact": true,
        "case": "b4-p64",
        "fit_seconds": {
          "baseline_seconds": 0.19298302100105502,
          "candidate_seconds": 0.20770387499942444,
          "speedup": 0.9291257613830738
        },
        "history_forecast_seconds": {
          "baseline_seconds": 0.06523787500009348,
          "candidate_seconds": 0.06380089549929835,
          "speedup": 1.0225228735357004
        },
        "round": 0
      },
      {
        "all_hashes_exact": true,
        "case": "b1-p8",
        "fit_seconds": {
          "baseline_seconds": 0.01048514599824557,
          "candidate_seconds": 0.01044741650002834,
          "speedup": 1.0036113711190828
        },
        "history_forecast_seconds": {
          "baseline_seconds": 0.007287479000297026,
          "candidate_seconds": 0.006908958001076826,
          "speedup": 1.0547869880177596
        },
        "round": 1
      },
      {
        "all_hashes_exact": true,
        "case": "b1-p64",
        "fit_seconds": {
          "baseline_seconds": 0.052576042000509915,
          "candidate_seconds": 0.05178725000041595,
          "speedup": 1.0152313938293234
        },
        "history_forecast_seconds": {
          "baseline_seconds": 0.021098604001963395,
          "candidate_seconds": 0.019567437999285175,
          "speedup": 1.078250714413106
        },
        "round": 1
      },
      {
        "all_hashes_exact": true,
        "case": "b4-p8",
        "fit_seconds": {
          "baseline_seconds": 0.028507124499810743,
          "candidate_seconds": 0.0290180624997447,
          "speedup": 0.9823924150711836
        },
        "history_forecast_seconds": {
          "baseline_seconds": 0.01394287499897473,
          "candidate_seconds": 0.012721604000034858,
          "speedup": 1.0959997653547875
        },
        "round": 1
      },
      {
        "all_hashes_exact": true,
        "case": "b4-p64",
        "fit_seconds": {
          "baseline_seconds": 0.19388639550015796,
          "candidate_seconds": 0.1947582914999657,
          "speedup": 0.9955231893179352
        },
        "history_forecast_seconds": {
          "baseline_seconds": 0.06596229200113157,
          "candidate_seconds": 0.06336666649986,
          "speedup": 1.0409620017060122
        },
        "round": 1
      }
    ],
    "counts": {
      "cases": 4,
      "fresh_processes": 8,
      "timed_fit_forecast_pairs": 64,
      "untimed_warmup_fit_forecast_pairs": 32
    },
    "protocol_sha256": "e83786ae59794b1ca7adcad98ceae77be5a7bc3cdf5dbbd0d135760316cad00e",
    "script_sha256": "1a4fd99511477569770a49a9609a4cba1640f8c6bb89e332e29ea0dbe93086d3"
  },
  "title": "Guarded single-frame parallel CPU forecast: frozen source comparison",
  "verification": {
    "focused_test_source": {
      "sha256": "04426597f3354cd406f616b0683f68e62720c293adc93d33d76f77e5bb0ad9e2",
      "source": "\"\"\"Parallel CPU forecast specialization agrees with the original sequence loop.\"\"\"\n\nfrom __future__ import annotations\n\nimport copy\nimport types\n\nimport pytest\nimport torch\nfrom torch.nn.modules import module as module_runtime\n\nimport resdag as rd\nfrom resdag.layers.cells import ESNCell\nfrom resdag.layers.readouts import ReadoutLayer\nfrom resdag.models.parallel_esn import ParallelESNModel\n\n\ndef _model(batch=1, *, trainable=False):\n    graph = rd.parallel_esn(\n        input_dim=16,\n        core_width=4,\n        halo=2,\n        reservoir_size=9,\n        spectral_radius=0.3,\n        leak_rate=0.7,\n        seed=7,\n        trainable=trainable,\n        dtype=torch.float64,\n        readout_alpha=0.01,\n    ).eval()\n    generator = torch.Generator().manual_seed(19)\n    observations = torch.randn(batch, 24, 32, generator=generator).double()[..., ::2]\n    graph.fit(observations[:, :3], observations[:, 3:-1], observations[:, 4:])\n    return graph, observations[:, -5:]\n\n\ndef _original_loop(\n    model,\n    history,\n    *,\n    horizon=5,\n    initial_feedback=None,\n    reset=True,\n    return_warmup=False,\n    alignment=\"next\",\n):\n    \"\"\"Independent original full-sequence calls, including boundary ownership.\"\"\"\n    with torch.no_grad():\n        warmup = model(history, reset=reset)\n        current = initial_feedback if initial_feedback is not None else warmup[:, -1:]\n        boundary = alignment == \"next\" and initial_feedback is None\n        values = [current] if boundary else []\n        for _ in range(int(boundary), horizon):\n            current = model(current)\n            values.append(current)\n        output = torch.cat(values, dim=1)\n        if return_warmup:\n            prefix = warmup[:, :-1] if boundary else warmup\n            output = torch.cat((prefix, output), dim=1)\n        return output\n\n\ndef _assert_matches(model, history, **kwargs):\n    kwargs.setdefault(\"horizon\", 5)\n    reference = copy.deepcopy(model)\n    expected = _original_loop(reference, history, **kwargs)\n    actual = model.forecast(history, **kwargs)\n    torch.testing.assert_close(actual, expected, rtol=0, atol=0)\n    torch.testing.assert_close(model.reservoir.state, reference.reservoir.state, rtol=0, atol=0)\n    assert model.reservoir._state_user_set == reference.reservoir._state_user_set\n    return actual\n\n\n@pytest.mark.parametrize(\"batch,trainable\", [(1, False), (3, True)])\n@pytest.mark.parametrize(\n    \"scenario\", [\"next\", \"prefix\", \"legacy\", \"seed\", \"empty\", \"continue\", \"one\"]\n)\ndef test_forecast_matches_original_sequence_loop(batch, trainable, scenario):\n    model, history = _model(batch, trainable=trainable)\n    assert not history.is_contiguous()\n    kwargs = {}\n    if scenario == \"prefix\":\n        kwargs[\"return_warmup\"] = True\n    elif scenario == \"legacy\":\n        kwargs.update(alignment=\"legacy\", return_warmup=True)\n    elif scenario in (\"seed\", \"empty\"):\n        kwargs[\"initial_feedback\"] = history[:, -1:]\n        if scenario == \"empty\":\n            history = history[:, :0]\n    elif scenario == \"continue\":\n        model(history, reset=True)\n        kwargs[\"reset\"] = False\n    elif scenario == \"one\":\n        kwargs[\"horizon\"] = 1\n    _assert_matches(model, history, **kwargs)\n\n\ndef test_builtin_forecast_selects_single_frame_path_once(monkeypatch):\n    model, history = _model()\n    calls = []\n    step = model._forecast_single_frame\n\n    def counted(series):\n        calls.append(series.shape)\n        return step(series)\n\n    monkeypatch.setattr(model, \"_forecast_single_frame\", counted)\n    _assert_matches(model, history, horizon=5)\n    assert calls == [(1, 1, 16)] * 4\n\n\ndef _forbid_fast_path(model):\n    def forbidden(*args):\n        pytest.fail(\"Custom behavior must use the original sequence path\")\n\n    model._forecast_single_frame = forbidden\n\n\n@pytest.mark.parametrize(\n    \"location\",\n    [\n        \"model_instance\",\n        \"model_subclass\",\n        \"window\",\n        \"reservoir_instance\",\n        \"reservoir_subclass\",\n        \"cell_instance\",\n        \"cell_subclass\",\n        \"readout_instance\",\n        \"readout_subclass\",\n        \"readout_mro\",\n        \"readout_dispatch\",\n        \"activation\",\n    ],\n)\ndef test_custom_methods_retain_native_sequence_dispatch(location):\n    model, history = _model()\n    _forbid_fast_path(model)\n    if location == \"model_instance\":\n        model.forward = types.MethodType(\n            lambda self, *a, **k: ParallelESNModel.forward(self, *a, **k) + 0.01, model\n        )\n    elif location == \"model_subclass\":\n\n        class CustomParallel(ParallelESNModel):\n            def forward(self, *args, **kwargs):\n                return super().forward(*args, **kwargs) + 0.01\n\n        model.__class__ = CustomParallel\n    elif location == \"window\":\n        model.window = types.MethodType(\n            lambda self, series: ParallelESNModel.window(self, series).flip(0), model\n        )\n    elif location == \"reservoir_instance\":\n        model.reservoir.forward = types.MethodType(\n            lambda self, *a, **k: rd.ESNLayer.forward(self, *a, **k) + 0.01, model.reservoir\n        )\n    elif location == \"reservoir_subclass\":\n\n        class CustomReservoir(rd.ESNLayer):\n            def forward(self, *args, **kwargs):\n                return super().forward(*args, **kwargs) + 0.01\n\n        model.reservoir.__class__ = CustomReservoir\n    elif location == \"cell_instance\":\n        model.reservoir.cell.project_inputs = types.MethodType(\n            lambda self, inputs: ESNCell.project_inputs(self, inputs) + 0.01, model.reservoir.cell\n        )\n    elif location == \"cell_subclass\":\n\n        class CustomCell(ESNCell):\n            def step(self, projected, state):\n                return super().step(projected + 0.01, state)\n\n        model.reservoir.cell.__class__ = CustomCell\n    elif location in (\"readout_instance\", \"readout_subclass\"):\n\n        def mutating(self, values):\n            # The full sequence path isolates this mutation from final state.\n            values.add_(0.01)\n            return ReadoutLayer.forward(self, values)\n\n        if location == \"readout_instance\":\n            model.readout.forward = types.MethodType(mutating, model.readout)\n        else:\n\n            class CustomReadout(type(model.readout)):\n                forward = mutating\n\n            model.readout.__class__ = CustomReadout\n    elif location == \"readout_mro\":\n\n        class MutatingLinear(torch.nn.Linear):\n            def forward(self, values):\n                values.add_(0.01)\n                return super().forward(values)\n\n        class CustomReadout(type(model.readout), MutatingLinear):\n            pass\n\n        model.readout.__class__ = CustomReadout\n    elif location == \"readout_dispatch\":\n\n        def mutating_call(self, values, *args, **kwargs):\n            values.add_(0.01)\n            return torch.nn.Module._call_impl(self, values, *args, **kwargs)\n\n        model.readout._call_impl = types.MethodType(mutating_call, model.readout)\n    else:\n        model.reservoir.cell.activation_fn = lambda values: torch.tanh(values) * 0.9\n    _assert_matches(model, history)\n\n\n@pytest.mark.parametrize(\"location\", [\"model\", \"reservoir\", \"readout\", \"global_pre\", \"global_post\"])\ndef test_local_and_global_hooks_retain_native_sequence_dispatch(location):\n    model, history = _model()\n    _forbid_fast_path(model)\n    handle = None\n    if location == \"global_pre\":\n        handle = module_runtime.register_module_forward_pre_hook(\n            lambda module, args: (args[0] + 0.01,) if isinstance(module, ReadoutLayer) else None\n        )\n    elif location == \"global_post\":\n        handle = module_runtime.register_module_forward_hook(\n            lambda module, args, output: output + 0.01 if isinstance(module, ReadoutLayer) else None\n        )\n    else:\n        target = model if location == \"model\" else getattr(model, location)\n        handle = target.register_forward_hook(lambda module, args, output: output + 0.01)\n    try:\n        _assert_matches(model, history)\n    finally:\n        handle.remove()\n\n\ndef test_protected_state_error_and_ownership_match_original():\n    model, history = _model()\n    state = torch.ones(8, 9, dtype=torch.float64)\n    model.reservoir.set_state(state)\n    stored = model.reservoir.state\n    with pytest.raises(RuntimeError, match=\"batch size\"):\n        model.forecast(history, horizon=3, reset=False)\n    assert model.reservoir.state is stored\n    assert model.reservoir._state_user_set\n\n\n@pytest.mark.parametrize(\"context\", [\"inference\", \"autocast\"])\ndef test_inference_and_autocast_contexts_match_original(context):\n    model, history = _model()\n    if context == \"autocast\":\n        _forbid_fast_path(model)\n    manager = (\n        torch.inference_mode()\n        if context == \"inference\"\n        else torch.autocast(\"cpu\", dtype=torch.bfloat16)\n    )\n    with manager:\n        _assert_matches(model, history)\n\n\ndef test_forward_ad_primal_and_tangent_match_original_sequence_loop():\n    model, history = _model()\n    reference = copy.deepcopy(model)\n    with torch.autograd.forward_ad.dual_level():\n        dual = torch.autograd.forward_ad.make_dual(history, torch.ones_like(history) * 0.2)\n        expected = _original_loop(reference, dual, horizon=4)\n        actual = model.forecast(dual, horizon=4)\n        expected = torch.autograd.forward_ad.unpack_dual(expected)\n        actual = torch.autograd.forward_ad.unpack_dual(actual)\n        torch.testing.assert_close(actual.primal, expected.primal, rtol=0, atol=0)\n        torch.testing.assert_close(actual.tangent, expected.tangent, rtol=0, atol=0)\n"
    },
    "focused_tests": {
      "command": "python -m pytest tests/test_models/test_parallel_forecast_step.py tests/test_models/test_parallel_esn.py --no-cov -q",
      "deselected": 1,
      "existing_parallel_cases": 25,
      "new_cases": 36,
      "passed": 61,
      "warning": "18 existing initializer TorchScript deprecation warnings on Python3.14; benchmark deselected by repository default."
    },
    "gradient_scope": "Exact forward-AD primal/tangent of the changed forecast path; ordinary trainable/noncontiguous forward gradients checked during diagnostics. Forecast remains no_grad for reverse mode.",
    "mypy": "Parallel model module passed; parent separately checked205 runtime modules.",
    "previous_report_equivalence": {
      "all_coefficient_prediction_state_hashes_exact": true,
      "all_warmup_and_timed_workflows": 96,
      "cases": 4,
      "fresh_processes": 8,
      "previous_report_commit": "34938890a5d650b6964b70ba2122dc462a4ad600",
      "previous_report_path": "docs/assets/data/phase-five-parallel-cpu-2026-10-23.json",
      "previous_report_sha256": "f02fe9b6de0fd143248afe491f215032a81bde75f784da11572523f26d014653",
      "scope": "Every warmup and timed workflow retained exactly the previous public report coefficient, prediction and state fingerprints after the shared typing-only wrapper fix."
    },
    "ruff": "Changed runtime module and new focused tests passed."
  }
}
