CFD Online Discussion Forums

CFD Online Discussion Forums (https://www.cfd-online.com/Forums/)
-   SU2 Installation (https://www.cfd-online.com/Forums/su2-installation/)
-   -   SU2 compilation with different AD library than CoDiPack (https://www.cfd-online.com/Forums/su2-installation/230849-su2-compilation-different-ad-library-than-codipack.html)

snes_chalmers October 8, 2020 10:14

SU2 compilation with different AD library than CoDiPack
 
Hello SU2-ers,

I was wondering how to compile SU2 using a different AD tool than the default CoDiPack. I need this in order to benchmark different AD tools and I see that ADOLC is (or was previously) supported in the sources. Nevertheless, whenever I try to use the preconfigure.py file to select ADOLC, the compilation fails (and no options seem available using the meson+ninja build tools). Does anyone know if it is still possible to use ADOL-c with SU2? If it is possible, could anyone guide me or point to a thread that shows how to do it?

Thanks in advance for any information.

cheers,

JoN

pcg October 9, 2020 06:54

I don't much know nor care about past versions, but currently it is CoDi and Medi pack only.

However, all types and functions are nicely wrapped, you might get away with modifying only:
Common/include/basic_types/ad_structure.hpp
Common/src/basic_types/ad_structure.cpp
Common/include/basic_types/datatype_structure.hpp
Common/include/linear_algebra/CSysSolve_b.hpp
Common/src/linear_algebra/CSysSolve_b.cpp

If you go the route of modifying the code, consider joining the SU2 slack channel https://su2code.github.io/ (button on top bar) we have weekly developers meetings and I think we would all be interested in seeing this comparison, and happy to help with anything.

If you use older version your measurements will be masked by performance bottlenecks we used to have. Version 7.0.7 is 4+ times faster than 6.2.0.

Regards

snes_chalmers October 9, 2020 09:00

Reply
 
Thanks PCG for your prompt reponse and for making it clear that ADOLC is no longer currently supported with SU2 v7+. I will take a look at the files you mention to see if I can manage to make it work. I will also seemingly need to modify the compilation scripts which might not be straightforward for me because I have no prior experience with meson and ninja.

thanks again for coming to the aid of su2 users and devs:).

cheers,

JoN

Quote:

Originally Posted by pcg (Post 784885)
I don't much know nor care about past versions, but currently it is CoDi and Medi pack only.

However, all types and functions are nicely wrapped, you might get away with modifying only:
Common/include/basic_types/ad_structure.hpp
Common/src/basic_types/ad_structure.cpp
Common/include/basic_types/datatype_structure.hpp
Common/include/linear_algebra/CSysSolve_b.hpp
Common/src/linear_algebra/CSysSolve_b.cpp

If you go the route of modifying the code, consider joining the SU2 slack channel https://su2code.github.io/ (button on top bar) we have weekly developers meetings and I think we would all be interested in seeing this comparison, and happy to help with anything.

If you use older version your measurements will be masked by performance bottlenecks we used to have. Version 7.0.7 is 4+ times faster than 6.2.0.

Regards


pcg October 9, 2020 18:32

Happy to help.

If ADOLC is header only like CoDi it is just a matter of mimicking what is done in the file meson.build for option "enable-autodiff".


All times are GMT -4. The time now is 21:17.