  We price European-style options written on forward contracts in a commodity
market, which we model with an infinite-dimensional Heath-Jarrow-Morton (HJM)
approach. For this purpose we introduce a new class of state-dependent
volatility operators that map the square integrable noise into the
Filipovi\'{c} space of forward curves. For calibration, we specify a fully
parametrized version of our model and train a neural network to approximate the
true option price as a function of the model parameters. This neural network
can then be used to calibrate the HJM parameters based on observed option
prices. We conduct a numerical case study based on artificially generated
option prices in a deterministic volatility setting. In this setting we derive
closed pricing formulas, allowing us to benchmark the neural network based
calibration approach. We also study calibration in illiquid markets with a
large bid-ask spread. The experiments reveal a high degree of accuracy in
recovering the prices after calibration, even if the original meaning of the
model parameters is partly lost in the approximation step.
