- Rating
- 2
- Confidence
- 4
- Informativeness
- 2
- Presentation
- 3
- Soundness
- 2
Read review
Paper summary
This paper proposes HFluxNO, an in-context neural solver for families of hyperbolic conservation laws. Given a short trajectory from an unknown system, a recurrent vision transformer encodes the trajectory into a context vector, a hypernetwork uses that vector to generate the parameters of a neural numerical-flux model, and the resulting flux is applied through a finite-volume update. The finite-volume structure guarantees exact conservation by construction. The authors evaluate on five families spanning 1D/2D, scalar/vector systems, different fluxes, and distribution shifts, including an unseen sine flux and shock-dominated initial conditions. HFluxNO generally outperforms DPOT and DISCO, while maintaining exact conservation, although it develops grid-scale oscillations on longer Euler rollouts and loses to the baselines on shock-dominated shallow water.
Critical strengths
One strength of the paper is the combination of in-context adaptation with an exact conservation guarantee. The finite-volume construction gives a real structural guarantee that the generic in-context baselines do not have, and the empirical results suggest that this is useful for long autoregressive rollouts. The comparison is also reasonably thorough, including unseen fluxes and shock-dominated initial conditions rather than only standard interpolation tests. I also like the component-level analysis. In particular, the authors compare against alternatives that receive the same context and separately replace the encoder, conditioning mechanism, and conservative target. This makes the architectural claims substantially better supported than many papers in this area.
Critical weaknesses
My main concern is that the paper somewhat overstates what is demonstrated about robustness to unseen conservation laws. The most striking zero-shot result is training on the cubic family and testing on a sine flux, but this is still a relatively controlled synthetic setting with the same periodic Cartesian discretization and the same general scalar conservation-law structure. More importantly, the model is trained on a fairly narrow family of fluxes and the paper does not establish how far the inferred flux generalizes beyond this type of functional variation. I would be more convinced by substantially more diverse unseen flux families or a clearer analysis of what information in the 20-frame context actually makes the new flux identifiable. There is also a substantive limitation in the claimed "robust" solver: conservation is guaranteed, but stability and physical admissibility are not. The paper itself shows that HFluxNO develops grid-scale oscillations in Euler at longer horizons and performs worse than the baselines on shock-dominated shallow water. This is not a minor implementation issue, since shocks and admissibility are central to the motivation for choosing hyperbolic conservation laws in the first place. The paper is candid about this limitation, but I think it weakens the broader claim that the numerical structure provides a robust foundation for in-context PDE modeling.
Questions for authors
- What evidence supports the claim that the context window is actually identifying the underlying flux, not learning a good predictor for the distribution of trajectories seen during training? In particular, can you quantify how accurately the inferred solver/flux predicts dynamics for substantially different coefficient regimes or flux families?
- How sensitive are the results to the particular choice of 20 context states? Does increasing or decreasing the context length materially change the ability to generalize to the unseen sine flux? How does performance change with context length, time step/CFL number, and rollout horizon?
- Since stability and entropy admissibility are not guaranteed, how often does the generated flux produce nonphysical states or unstable rollouts across the test distribution? The long-horizon Euler oscillations suggest that exact conservation alone may be insufficient for the intended shock-dominated setting.
- Can the same in-context framework be extended to an entropy-stable or monotone numerical flux without sacrificing the ability to generate the solver parameters from context?
- Can the authors compare against relevant in-context operator-learning methods such as ICON, PDE generalization of ICON, In-Context Neural PDE, and Nonlocal Attention Operator, rather than only conventional neural-operator baselines?
- What are the training and inference costs, including the size of the generated numerical-flux network and the per-step runtime/memory overhead?
- Since the positional encoding is tied to the training grid and the time step is fixed, does the method transfer to different resolutions or CFL conditions?
5 comments
Reply to reviewer AyEF (1/4)
We thank the reviewer for these detailed questions. The general comment lists the revisions and defines the terms that we use below (context length, rollout, the two trivial baselines). This reply follows the order of the questions and completes our earlier reply on Q1 and Q6.
Q1. What does the context identify? Our earlier reply showed that a solver generated once and held for several steps is more accurate than one regenerated at every step. The revision reports this on 1D and 2D cubic (Appendix E, Table 10, which holds the 2D numbers of that reply). Those numbers are 20-step errors, taken over all 20 steps as defined in Section 5, and not final-frame errors as that reply labeled them. With the solver held for eight steps, the 20-step error falls by 20% and 24% in distribution, the latter where we wrote 25% before.
To answer the question further, we performed additional experiments that systematically corrupt or exchange the context frames read by the encoder, while the solver advances the true state (Section 6.1, Appendix G). A change in the prediction can then come only from a change in the generated solver. All errors are one-step errors on 1D cubic.
- The dynamics are needed. With the 20 context states in a random order, or with the last state repeated 20 times, the error rises to that of the identity baseline (0.94 and 0.98 of it, against 0.07 with the true context). The states alone, without their time evolution, are of no use to the model.
- The equation is read from the context. A context from a trajectory with other coefficients makes the prediction worse than the identity baseline (1.23 of its error). The cost grows with the distance between the two fluxes, from 7.4 to 22.4 times the true-context error, measured among replacement contexts that cover all values of the advanced state (Table 15).
- The flux is represented over the visited states. A context from another solution of the same equation is not free. Its cost depends on its coverage, the fraction of the values of the advanced state that lie within the range of values in the replacement context. The error falls from 11.3 to 2.2 times that of the true context as the coverage rises from below one half to one (Table 14).
We therefore claim identification in a limited form, and the revision states the limit (Sections 6.1 and 7). The model does not recover the flux as a function, or its coefficients. It generates a solver that is accurate for the equation shown in the context, over the states that the context visited. A factor of 2.2 remains even at full coverage, which we attribute to the coarseness of our coverage measure and have not resolved. We also do not test extrapolation to a disjoint coefficient range inside the cubic family, since the test coefficients are unseen draws from the training range.
Different flux families. The submitted sine flux was nearly a cubic, as Reviewer DHwv pointed out. The revision replaces it with a rescaled sine flux, f(u) = (a/|b|)·sin(bu) in four bins of |b| up to 4, and the Buckley–Leverett flux of two-phase flow in three bins of the mobility ratio. Both move away from the cubic family in measured steps while the maximum wave speed stays fixed (Fig. 3, Appendix J.2). The distance is the relative residual of the wave speed f′ from that of the closest cubic, 0.00 to 0.36 across the sine bins and 0.19 to 0.43 for Buckley–Leverett (Table 24). The cubic-trained models are evaluated without retraining.
- HFluxNO has the lowest 20-step error on all eleven sets. In relative ℓ² its error is 20% to 40% below DISCO's and 44% to 72% below DPOT's.
- On smooth data its error doubles across the sine sweep (0.046 to 0.102) and stays below that of the identity baseline, which DPOT reaches.
- On Buckley–Leverett it is flat at 0.073, against 0.110 to 0.120 for DISCO and 0.161 to 0.174 for DPOT.
- The limit is visible on the farthest sine flux, where HFluxNO's fronts fall behind the reference within three context lengths (Fig. 10(b)). Section 7 states it.
These tests remain in the setting that the reviewer describes, which is scalar, one-dimensional and on the training grid. We state the claim for that setting.
Reply to reviewer AyEF (2/4)
Q2. Context length, time step, CFL number and rollout horizon (Appendix I). All errors here are one-step errors on 1D cubic, so that they are not mixed with the accumulation of error in a rollout.
- Context length. We trained models with 5, 10, 20 and 40 context states, three runs each. In distribution the error (×10⁻³) is 5.11, 4.30, 3.80 and 3.77, so it stops improving at 20 states. On the unseen sine fluxes 40 states still help, by 11% and 12% in the two bins nearest to the training family and by 4% and 1% in the two farthest (Table 19). A trained model does not transfer to another length. The submitted model, run with 5, 10 or 40 states, reaches 1.17, 0.59 and 0.53 of the error of the identity baseline, against 0.07 with 20 (Table 20).
- CFL number. The CFL number is the number of cells that the fastest wave crosses in one time step. At the training grid and time step it varies across the test trajectories from 0.05 to 10.7, because the wave speed does. We sort the test segments into twelve bins of equal count. HFluxNO has the lowest error in every bin, and its error does not grow with the CFL number (Fig. 9).
- Time step. The encoder does not receive Δt, and the finite-volume update takes it explicitly, so the generated solver can be applied at another step. With the context at the training step, one update at 0.5Δt or 2Δt gives 1.7 and 10 times the error at Δt. These errors are 0.23 and 0.37 of the error of the identity baseline, against 0.07 at Δt (Table 21). The generated flux is thus a flux for the training step. The baselines share this restriction, since DPOT maps frames to the next frame and DISCO integrates its vector field over a fixed unit interval.
- Rollout horizon. Fig. 4(a) follows the error over 80 steps, four context lengths, together with the two trivial baselines. Table 12 counts the rollouts of each model that are worse than trivial by 20, 40 and 80 steps (see Q3).
In summary, the accuracy holds across what varies inside the training distribution, the wave speed, and the model is tied to what is fixed during training, the context length and the time step. Section 7 lists both among the limitations.
Q7. Resolution and CFL transfer. We answer this question here because it continues Q2. We tested the CFL number only as it varies across test trajectories at the training grid and time step, where the accuracy holds. We did not test another resolution, and the current model cannot be run at one, because the learned positional encoding of the encoder ties it to the training grid, as Section 7 and Appendix A.1 state. The patch-based encoders of the baselines have the same restriction. Lifting the restriction to one grid, time step and context length is among the next steps of Section 8.
Response to Reviewer AyEF (Q1 and Q6)
We thank the reviewer for the detailed and balanced review. We address Q1 (whether the context identifies the flux) and Q6 (inference cost) here with a new experiment; the remaining questions will be addressed in a separate response.
Q1. Does the context identify a solver, or does the model learn a trajectory predictor?
In the default rollout, HFluxNO re-encodes the most recent 20 frames at every step. As the rollout proceeds, these frames are increasingly the model's own predictions, so the flux network is regenerated from a context that it has itself produced. If the encoder and hypernetwork were only learning a good next-frame predictor for the training distribution, the generated flux network should be useful only for the step it was generated for.
To test this, we decouple flux generation from time stepping. The flux network is generated once from the current window and then held fixed for n consecutive finite-volume steps; only after n steps is it regenerated from the latest window. n=1 recovers the original rollout exactly (we verified a maximum absolute difference of 0 in float32). Results on the 2D cubic family, 20-step rollout, final-frame error (×10−1, mean ± std over 3 seeds):
A flux network generated once and applied for eight steps is not only usable but more accurate: the 20-step relative ℓ2 error decreases by 25% in distribution and by 18% on shock-dominated initial conditions. The improvement is monotone in n and holds for every seed individually. The generated flux therefore behaves as a self-contained numerical solver that remains valid over many time steps without access to the context, which is what one expects if the context determines the dynamics rather than the next frame. The gain also suggests that per-step re-encoding feeds the model's own prediction error back into the generated solver; holding the solver fixed removes this feedback path.
Q6. Inference cost
The same experiment shows that the encoder and hypernetwork need not be evaluated at every step. With refresh every n steps, they are called 20/n times per 20-step rollout instead of 20 times, and every other step evaluates only the generated flux network inside the finite-volume update. With n=8, the context is processed 3 times instead of 20 per rollout while the error is reduced, so the cost of parameter generation is amortized over many solver steps rather than paid at every step.