| 75 | 
  | 
  | 
| 76 | 
 make adall | 
 make adall | 
| 77 | 
  | 
  | 
| 78 | 
  | 
 STEP 3: | 
| 79 | 
  | 
 ###### | 
| 80 | 
  | 
 Compare reference outputs. | 
| 81 | 
  | 
  | 
| 82 | 
  | 
 # uncompress outputs in results_... directories: | 
| 83 | 
  | 
 gunzip ../results_shallow_*/output.txt.gz | 
| 84 | 
  | 
  | 
| 85 | 
  | 
 # extract gradients from TAF-generated adjoint: | 
| 86 | 
  | 
 grep grad-res ../results_shallow_taf/output.txt | 
| 87 | 
  | 
  | 
| 88 | 
  | 
 # extract gradients from OpenAD-generated adjoint: | 
| 89 | 
  | 
 grep ' salt/theta ' ../results_shallow_openad/output.txt | 
| 90 | 
  | 
  | 
| 91 | 
  | 
 The two positions tested via gradient checks (results_shallow_taf) are | 
| 92 | 
  | 
 (i,j,k) = (43,2,1) and (44,2,1) | 
| 93 | 
  | 
 Find corresponding locations in ' salt/theta ' output  | 
| 94 | 
  | 
 (which outputs whole theta, salt gradient) | 
| 95 | 
  | 
  |