Skip to main content
QUICK REVIEW

[论文解读] Hamiltonian Neural Networks

Sam Greydanus, Misko Dzamba|arXiv (Cornell University)|Jun 4, 2019
Machine Learning in Materials Science参考文献 43被引用 315
一句话总结

该论文提出哈密顿神经网络(HNNs),通过学习参数化哈密顿量以在动力系统中强制能量守恒,在长期保真度和精确可逆性方面优于基线网络。

ABSTRACT

Even though neural networks enjoy widespread use, they still struggle to learn the basic laws of physics. How might we endow them with better inductive biases? In this paper, we draw inspiration from Hamiltonian mechanics to train models that learn and respect exact conservation laws in an unsupervised manner. We evaluate our models on problems where conservation of energy is important, including the two-body problem and pixel observations of a pendulum. Our model trains faster and generalizes better than a regular neural network. An interesting side effect is that our model is perfectly reversible in time.

研究动机与目标

  • 激发在神经网络中引入物理信息约束偏置的需求。
  • 提出用神经网络学习哈密顿量函数以在无监督下实现守恒定律。
  • 展示在多种物理任务中改进的长期动力学与能量守恒。

提出的方法

  • 将哈密顿量 H_theta 参数化为一个神经网络,该网络将坐标 (q, p) 映射到一个标量能量近似值。
  • 计算辛梯度 S_H = (∂H/∂p, -∂H/∂q),以获得时间导数,并使用 RK4 求解器进行积分。
  • 使用图内梯度损失 L_HNN = ||∂H/∂p - dq/dt||_2 + ||∂H/∂q + dp/dt||_2 进行训练,以强制精确守恒定律。
  • 在包括理想弹簧-质量系统、理想摆、真实摆、双体问题以及像素基摆动力学的任务上进行评估。
  • 通过将自编码器与 HNN 结合并在潜在空间添加损失来鼓励哈密顿结构,从而扩展到像素观测。
Figure 1: Learning the Hamiltonian of a mass-spring system. The variables $q$ and $p$ correspond to position and momentum coordinates. As there is no friction, the baseline’s inner spiral is due to model errors. By comparison, the Hamiltonian Neural Network learns to exactly conserve a quantity that
Figure 1: Learning the Hamiltonian of a mass-spring system. The variables $q$ and $p$ correspond to position and momentum coordinates. As there is no friction, the baseline’s inner spiral is due to model errors. By comparison, the Hamiltonian Neural Network learns to exactly conserve a quantity that

实验结果

研究问题

  • RQ1神经网络是否能够学习一个在动力系统中实现能量守恒的哈密顿量?
  • RQ2哈密顿神经网络在简单和复杂物理任务中是否比标准神经网络具有更好的泛化和能量守恒?
  • RQ3HNN 能否从像素数据训练以建模动力系统?
  • RQ4将哈密顿结构引入对学习动力学的可逆性和长期稳定性有何影响?

主要发现

任务基线训练损失HNN 训练损失基线测试损失HNN 测试损失基线能量HNN 能量
1: 理想弹簧-质量系统37± 237± 237± 236± 2170± 20.38±.1
2: 理想摆33± 233± 235± 236± 242± 1025± 5
3: 真实摆2.7±.29.2±.52.2±.36.0±.6390± 714± 5
4: 双体 (×10^6)33± 13.0±.130±.12.8±.16.3e4± 3e439± 5
5: 像素摆18±.219±.217±.318±.39.3± 1.15±.01
  • HNN 学习一个能量样的守恒量,并显著降低相较基线的能量漂移。
  • 在所有五个任务中,HNN 的训练/测试损失与基线相近,但能量守恒效果更好(在若干任务中能量均方误差低出数量级)。
  • HNN 能扩展到更大规模的系统(例如双体问题),具有较强的能量守恒和比基线更慢的发散。
  • 基于像素的实验表明 HNN 能从潜在表示学习动力学,并在数百帧内比基线更好地保持能量。
  • HNN 中的守恒量与总能量密切相似(在一个常数因子内),表明学习到的哈密顿量捕捉了本质物理。
Figure 2: Analysis of models trained on three simple physics tasks. In the first column, we observe that the baseline model’s dynamics gradually drift away from the ground truth. The HNN retains a high degree of accuracy, even obscuring the black baseline in the first two plots. In the second column
Figure 2: Analysis of models trained on three simple physics tasks. In the first column, we observe that the baseline model’s dynamics gradually drift away from the ground truth. The HNN retains a high degree of accuracy, even obscuring the black baseline in the first two plots. In the second column

更好的研究,从现在开始

从论文设计到论文写作,大幅缩短您的研究时间。

无需绑定信用卡

本解读由 AI 生成,并经人工编辑审核。