Skip to content

Commit

Permalink
Merge pull request #1492 from su2code/feature_fix_recording_SOLUTION_…
Browse files Browse the repository at this point in the history
…AND_MESH

Changed the registration of AD input variables in CDiscAdjFluidIteration
  • Loading branch information
pcarruscag committed Jan 14, 2022
2 parents 7cfe302 + f71c598 commit b784edf
Show file tree
Hide file tree
Showing 3 changed files with 6 additions and 8 deletions.
2 changes: 1 addition & 1 deletion Common/include/CConfig.hpp
Original file line number Diff line number Diff line change
Expand Up @@ -4246,7 +4246,7 @@ class CConfig {
unsigned short GetRef_Inc_NonDim(void) const { return Ref_Inc_NonDim; }

/*!
* \brief Get the kind of SU2 software component.
* \brief Set the kind of SU2 software component.
* \return Kind of the SU2 software component.
*/
void SetKind_SU2(SU2_COMPONENT val_kind_su2) { Kind_SU2 = val_kind_su2 ; }
Expand Down
10 changes: 4 additions & 6 deletions SU2_CFD/src/drivers/CDiscAdjSinglezoneDriver.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -434,9 +434,8 @@ void CDiscAdjSinglezoneDriver::DirectRun(RECORDING kind_recording){
}

void CDiscAdjSinglezoneDriver::MainRecording(){

/*--- SetRecording stores the computational graph on one iteration of the direct problem. Calling it with NONE
* as argument ensures that all information from a previous recording is removed. ---*/
/*--- SetRecording stores the computational graph on one iteration of the direct problem. Calling it with
* RECORDING::CLEAR_INDICES as argument ensures that all information from a previous recording is removed. ---*/

SetRecording(RECORDING::CLEAR_INDICES);

Expand All @@ -447,9 +446,8 @@ void CDiscAdjSinglezoneDriver::MainRecording(){
}

void CDiscAdjSinglezoneDriver::SecondaryRecording(){

/*--- SetRecording stores the computational graph on one iteration of the direct problem. Calling it with NONE
* as argument ensures that all information from a previous recording is removed. ---*/
/*--- SetRecording stores the computational graph on one iteration of the direct problem. Calling it with
* RECORDING::CLEAR_INDICES as argument ensures that all information from a previous recording is removed. ---*/

SetRecording(RECORDING::CLEAR_INDICES);

Expand Down
2 changes: 1 addition & 1 deletion SU2_CFD/src/iteration/CDiscAdjFluidIteration.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -507,7 +507,7 @@ void CDiscAdjFluidIteration::RegisterInput(CSolver***** solver, CGeometry**** ge
}
}

if (kind_recording == RECORDING::MESH_COORDS) {
if (kind_recording == RECORDING::MESH_COORDS || kind_recording == RECORDING::SOLUTION_AND_MESH) {
/*--- Register node coordinates as input ---*/

geometry[iZone][iInst][MESH_0]->RegisterCoordinates();
Expand Down

0 comments on commit b784edf

Please sign in to comment.