Compile ADF version when you create a new objective function #511
uttamcadambi07
started this conversation in
General
Replies: 1 comment
-
Yes, you need to compile the AD version of DAFoam if you have a new objective. It is hard to tell what the problem was. I suggest you create a fork of the DAFoam repo and update your codes to the fork. Then, we should be able to take a look. |
Beta Was this translation helpful? Give feedback.
0 replies
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment
-
Hi,
I have created a new objective function. This does cell-volume weighted averaging to handle grid mismatch to compute the objective function as a difference between the velocities.
This function was tested on the periodic hill and primal solver converges, so does the adjoint and the optimization works well.
Now, I am using the same objective function but to do a position optimization. I want to use a reference data set and try to move my CFD mesh to match the reference data set.
I performed the optimziation and got very very small values of the gradients.
To verify, I tried using the forwardAD. But it ends with -nan as the derivative.
I have not compiled dafoam in forward mode AD after I added the objective function - could this be the reason?
Please advise - I can provide more details on request.
Beta Was this translation helpful? Give feedback.
All reactions