Major update to Baikal/BaikalVacuum

Create issue
Issue #2645 new
Zach Etienne created an issue

First off, there are no new features or new parameters/parameter defaults in this update. All math kernels are identical as well. This is strictly the result of a modernization of the code generation infrastructure.

The codegen of Baikal and BaikalVacuum has been updated to conform to the latest NRPy+ standards, which emphasize registration of C functions with NRPy+ instead of oodles of .h files that can be hard to track. Parallel codegen is far more robust, and maintainability has been greatly improved (./run_Jupyter_notebook.sh Tutorial-ETK_thorn-BaikalETK.ipynb is the only means to generate the thorns; before the Jupyter notebook contents were completely copied into separate Python modules).

Here are the steps needed to validate this latest version against the original:

  1. Clone the latest NRPy+ repo: git clone https://github.com/zachetienne/nrpytutorial.git
  2. Make sure you have jupyter and sympy installed (pip install jupyter sympy)
  3. Make sure you have downloaded the latest ET release https://einsteintoolkit.org/download.html
  4. Go into the nrpytutorial directory and type ./convert_jupyter_to_python_and_run.sh Tutorial-ETK_thorn-BaikalETK.ipynb
  5. Step 4 above should've generated the updated Baikal & BaikalVacuum thorns.
  6. E.g., go into BaikalVacuum/src/ and diff a RHS file against the latest ET release version via:
    diff -w rhs_eval_BaikalVacuum_order_4.c [path to latest ET release]/arrangements/WVUThorns/BaikalVacuum/src/BSSN_RHSs_enable_Tmunu_False_FD_order_4.c
    notice that -w ignores whitespace differences, which is important since the latest version does proper tabbing. You'll see that the math kernel is identical, and the only differences include things like adding CCTK_ATTRIBUTE_UNUSED to various automatically generated constants, which may not be used and using NGHOSTS=cctk_nghostzones[0] consistently.
    Other RHS orders, Ricci evaluations, and constraint calculations can be compared in a similar fashion.

The pull request is here:

https://bitbucket.org/zach_etienne/wvuthorns/pull-requests/12/modernize-baikal-baikalvacuum-codegen

I will merge this pull request on Tuesday Sept 27, unless there are objections.

Comments (1)

  1. Log in to comment