CFD Online Logo CFD Online URL
www.cfd-online.com
[Sponsors]
Home > Forums > Software User Forums > SU2

Can't find SU2_CFD_AD and SU2_DOT_AD

Register Blogs Community New Posts Updated Threads Search

Like Tree1Likes

Reply
 
LinkBack Thread Tools Search this Thread Display Modes
Old   March 8, 2024, 09:24
Smile Can't find SU2_CFD_AD and SU2_DOT_AD
  #1
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
Hi guys,
I'm trying to do the example on SU2 webpage called "Constrained shape design of a transonic turbulent airfoil at a cte. CL". However im unable to find the SU2_CFD_AD and SU2_DOT_AD as shown in the image. Im also attaching a screenshot of my repository where the only tools shown are those.
Thank you.
Attached Images
File Type: jpg tools .jpg (31.4 KB, 11 views)
File Type: jpg Necessary tools.jpg (144.6 KB, 8 views)
David_002 is offline   Reply With Quote

Old   March 8, 2024, 10:28
Default
  #2
New Member
 
Join Date: Feb 2022
Posts: 18
Rep Power: 4
cristopher_morales is on a distinguished road
Hi David,

Did you compile SU2 with the option: -Denable-autodiff=true ?

Best regards,

Cristopher Morales Ubal
cristopher_morales is offline   Reply With Quote

Old   March 26, 2024, 12:38
Default
  #3
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
Hi Christopher, thank you for your reply.
I'm not aware to have done this but I'm unable to understand how to complie it with that option.
Could you explain the steps to follow what you mention?
Thank you for your time and attention.
David_002 is offline   Reply With Quote

Old   March 27, 2024, 11:27
Default
  #4
New Member
 
Join Date: Feb 2022
Posts: 18
Rep Power: 4
cristopher_morales is on a distinguished road
Quote:
Originally Posted by David_002 View Post
Hi Christopher, thank you for your reply.
I'm not aware to have done this but I'm unable to understand how to complie it with that option.
Could you explain the steps to follow what you mention?
Thank you for your time and attention.

Hi David,


You can compile SU2 using these commands:


./meson.py build --reconfigure -Dwarning_level=2 -Denable-autodiff=true -Denable-directdiff=false -Dwith-mpi=enabled -Denable-cgns=true -Denable-tecio=false --prefix=/home/mech001/20215667/SU2


where --prefix=/home/mech001/20215667/SU2 is the installation directory.



Best regards,


Cristopher Morales Ubal
cristopher_morales is offline   Reply With Quote

Old   March 27, 2024, 16:50
Smile
  #5
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
Hi Cristopher, thanks for your reply.
As I'm using it in windows I've changed the / by \ for directories.
If I write ./meson.py it just opens the python script but using python meson.py it seems to install something. However there is an error as it can't find the directory (see attached picture). For me this is strange as the directory is marked with double \\ instead of just one \. Do you have any clue on this?
Thank you very much.
Attached Images
File Type: jpg SU2 error.jpg (134.1 KB, 5 views)
David_002 is offline   Reply With Quote

Old   March 27, 2024, 17:40
Default
  #6
Senior Member
 
bigfoot
Join Date: Dec 2011
Location: Netherlands
Posts: 504
Rep Power: 17
bigfootedrockmidget is on a distinguished road
Here is your main mistake:

Quote:
Originally Posted by David_002 View Post
As I'm using it in windows

Use Linux, which is a real developers platform. You can install it inside a virtual box if for some reason you still need have windows for something.
There are so many things that you need to set up in windows to get this running that this is by far the easiest option for you.
bigfootedrockmidget is offline   Reply With Quote

Old   March 28, 2024, 04:52
Default
  #7
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
Thank you for your reply.
Would you recommend to use WSL 2 or to use a virtualbox?
Thank you
David_002 is offline   Reply With Quote

Old   March 28, 2024, 08:44
Smile
  #8
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
Hi Cristopher and bigfootedrockmidget,
I've already install and compiled everything except the AD build in an Ubuntu Linux system.
Have you been able to use the AD build? If so, which version of SU2 did you use and which steps did you follow?
Thank you.
David_002 is offline   Reply With Quote

Old   March 30, 2024, 08:56
Default
  #9
New Member
 
Join Date: Feb 2022
Posts: 18
Rep Power: 4
cristopher_morales is on a distinguished road
Quote:
Originally Posted by David_002 View Post
Hi Cristopher and bigfootedrockmidget,
I've already install and compiled everything except the AD build in an Ubuntu Linux system.
Have you been able to use the AD build? If so, which version of SU2 did you use and which steps did you follow?
Thank you.
Hi David,

you can compile the AD using the latest version of SU2, be sure that you use the develop branch. if you open the terminal within the SU2 folder , you can type:

git status

then you will see the branch where you are.

you can switch to develop using the following command:

git checkout develop

and then recompile again using this command line:

./meson.py build --reconfigure -Dwarning_level=2 -Denable-autodiff=true -Denable-directdiff=false -Dwith-mpi=enabled -Denable-cgns=true -Denable-tecio=false --prefix=/home/mech001/20215667/SU2

you must also download FADO and add the path of FADO in your .bashrc file.
you can do it opening a terminal and type:

nano .bashrc

and then you should add the lines in the picture attached.



best regards,

Cristopher Morales Ubal
Attached Images
File Type: jpg fado installation.JPG (11.4 KB, 4 views)
cristopher_morales is offline   Reply With Quote

Old   March 30, 2024, 09:16
Default
  #10
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
Hi Cristopher,
when typing git status there is an error saying: fatal: no es un repositorio git (ni ninguno de los directorios superiores): .git
sorry it is in spanish (traduction): it is not a git repository. Any idea on this? Thank you.
David_002 is offline   Reply With Quote

Old   March 30, 2024, 09:18
Default
  #11
New Member
 
Join Date: Feb 2022
Posts: 18
Rep Power: 4
cristopher_morales is on a distinguished road
Quote:
Originally Posted by David_002 View Post
Hi Cristopher,
when typing git status there is an error saying: fatal: no es un repositorio git (ni ninguno de los directorios superiores): .git
sorry it is in spanish (traduction): it is not a git repository. Any idea on this? Thank you.
Hi David,

could you share an screenshot of the folder where you have installed SU2?

and a screenshot of your terminal?
cristopher_morales is offline   Reply With Quote

Old   March 30, 2024, 09:20
Default
  #12
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
This would be it. Descargas means downloads.
Attached Images
File Type: png Captura desde 2024-03-30 15-19-43.png (27.5 KB, 3 views)
File Type: png Captura desde 2024-03-30 15-18-59.png (78.3 KB, 2 views)
David_002 is offline   Reply With Quote

Old   March 30, 2024, 09:22
Default
  #13
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
Would it be possible to make any kind of call by meets or discord?
David_002 is offline   Reply With Quote

Old   March 30, 2024, 09:24
Default
  #14
New Member
 
Join Date: Feb 2022
Posts: 18
Rep Power: 4
cristopher_morales is on a distinguished road
Quote:
Originally Posted by David_002 View Post
This would be it. Descargas means downloads.
How did you download SU2? did you use

git clone https://github.com/su2code/SU2.git

?
cristopher_morales is offline   Reply With Quote

Old   March 30, 2024, 09:29
Default
  #15
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
The steps I've followed are this:
1. Download the 8.0.1 version from SU2 release in the tar format
2. then use command: tar xzvf SU2-8.0.1.tar.gz
3. then use cd to get inside this folder
4. then: sudo apt install git
5. then: ./meson.py build
6. then: ./ninja -C build install
7. then: nano .bashrc to include the paths
8. then source ~./bashrc to save it

9. end
David_002 is offline   Reply With Quote

Old   March 31, 2024, 13:08
Default
  #16
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
Dear Cristopher, as the 8.0.1 version was not working well for me I installed version 7.0.4 which works fine.

I've installed everything and then I then tried to reconfigure for the AD build using the command you pasted (./meson.py build --reconfigure -Dwarning_level=2 -Denable-autodiff=true -Denable-directdiff=false -Dwith-mpi=enabled -Denable-cgns=true -Denable-tecio=false --prefix=/home/mech001/20215667/SU2

where --prefix=/home/mech001/20215667/SU2 is the installation directory)

(see picture 1). It works fine. But then when calling ninja it gives me the following error for the mpi.h. Do you have any clue about why?

In order to reconfigure something the procedure is to first define the configuration with meson and then use ninja to install the packages?


Thank you for your time and help.
Attached Images
File Type: jpg error 1 31-03-2024.jpg (125.3 KB, 3 views)
File Type: jpg 2 31-03-2024.jpg (92.9 KB, 3 views)
File Type: jpg 1 31-03-2024.jpg (133.7 KB, 2 views)
David_002 is offline   Reply With Quote

Old   April 1, 2024, 05:15
Default
  #17
New Member
 
Join Date: Feb 2022
Posts: 18
Rep Power: 4
cristopher_morales is on a distinguished road
Quote:
Originally Posted by David_002 View Post
Dear Cristopher, as the 8.0.1 version was not working well for me I installed version 7.0.4 which works fine.

I've installed everything and then I then tried to reconfigure for the AD build using the command you pasted (./meson.py build --reconfigure -Dwarning_level=2 -Denable-autodiff=true -Denable-directdiff=false -Dwith-mpi=enabled -Denable-cgns=true -Denable-tecio=false --prefix=/home/mech001/20215667/SU2

where --prefix=/home/mech001/20215667/SU2 is the installation directory)

(see picture 1). It works fine. But then when calling ninja it gives me the following error for the mpi.h. Do you have any clue about why?

In order to reconfigure something the procedure is to first define the configuration with meson and then use ninja to install the packages?


Thank you for your time and help.
Hi David,

it seems that you have not installed an MPI, you can follow this installation procedure:

https://rantahar.github.io/introduct...mpi/setup.html

In order to reconfigure something the procedure is to first define the configuration with meson and then use ninja to install the packages?

Yes, you must reconfigure meson and next use ninja to compile.

Best regards.

Cristopher Morales
cristopher_morales is offline   Reply With Quote

Old   April 1, 2024, 11:08
Default
  #18
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
Hi Cristopher,
For the case of SU2 version 7.0.4, after compiling with ninja, comands:
make and then: sudo make install are used. What does these commands do and are they necessary after each reconfiguration?
Thank you.
David_002 is offline   Reply With Quote

Old   April 1, 2024, 13:00
Default
  #19
New Member
 
Join Date: Feb 2022
Posts: 18
Rep Power: 4
cristopher_morales is on a distinguished road
Quote:
Originally Posted by David_002 View Post
Hi Cristopher,
For the case of SU2 version 7.0.4, after compiling with ninja, comands:
make and then: sudo make install are used. What does these commands do and are they necessary after each reconfiguration?
Thank you.
Hi David,

I think sudo make install is not needed after each reconfiguration.

Best regards,

Cristopher Morales Ubal
cristopher_morales is offline   Reply With Quote

Old   April 1, 2024, 15:19
Default
  #20
New Member
 
Join Date: Mar 2024
Posts: 14
Rep Power: 2
David_002 is on a distinguished road
Dear Cristopher.
I've followed the steps you mentioned and try to run the example shown in: https://su2code.github.io/tutorials/...ained_RAE2822/

However, when running:
shape_optimization.py -g DISCRETE_ADJOINT -o SLSQP -f turb_SA_RAE2822.cfg

This is the error it says (see picture). It looks like it is unable to find the SU2_CFD_AD, however i can find it in the folder (see picture). Should this location be added to the nano .basrhc in some way? Could it be any other error?

Once again, thank you for your time and help.
Attached Images
File Type: png Captura desde 2024-04-01 21-17-30.png (169.0 KB, 6 views)
File Type: png Captura desde 2024-04-01 21-18-03.png (56.0 KB, 4 views)
David_002 is offline   Reply With Quote

Reply

Tags
cfd, su2, tools


Posting Rules
You may not post new threads
You may not post replies
You may not post attachments
You may not edit your posts

BB code is On
Smilies are On
[IMG] code is On
HTML code is Off
Trackbacks are Off
Pingbacks are On
Refbacks are On



All times are GMT -4. The time now is 10:29.