exojax icon indicating copy to clipboard operation
exojax copied to clipboard

GPU dependence and non-reproducibility of radiative transfer (small error)

Open HajimeKawahara opened this issue 2 years ago • 1 comments

During the review of #265 , we found that there is non-reproducibility of radiative transfer results for MODIT and PreMODIT. This can be confirmed by the unit tests:

  • exojax/tests/unittests/spec/modit/modit_test.py
  • exojax/tests/unittests/spec/premodit/premodit_spectrum_test.py

Differences

  • within 0.2 % using A100
  • within 2% using GeForce RTX 3080
  • intergpu error ~ 3% between A100 and RTX3080

Diff between A100 and RTX3080 by @ykawashima

slack-imgs

HajimeKawahara avatar Jul 19 '22 02:07 HajimeKawahara

from jax.config import config                                                                                          
config.update("jax_enable_x64", True)

The use of f64 looks avoids this problem.

HajimeKawahara avatar Jul 22 '22 01:07 HajimeKawahara