ss3-source-code icon indicating copy to clipboard operation
ss3-source-code copied to clipboard

[Bug]: SPR/YPR profile and global_MSY not using correct biology vectors

Open Rick-Methot-NOAA opened this issue 1 year ago • 1 comments

Describe the bug

These calculations were using biology from the last year of forecast, not the biology associated with Benchmark specifications. This is all being worked on in the issue #191 that worked on correcting use of biology vectors for benchmark calculations.

To Reproduce

set up model with time-varying biology and set benchmark years to not be styr. Output provided by SS3.20.22 was not sufficient to see how time-varying biology was being used for these SPR/YPR

Expected behavior

correct results

Screenshots

No response

Which OS are you seeing the problem on?

No response

Which version of SS3 are you seeing the problem on?

No response

Additional Context

No response

Rick-Methot-NOAA avatar Oct 04 '24 00:10 Rick-Methot-NOAA

Benchmark quantities stored in y = styr-3

  • Ave_Size
  • NatM (surv1 is stored by season only, but is only used by Pope's F method)
  • Wt_Age_t, which includes (-2 for fecundity, -1 for beg of year, 0 for mid year wt.)
  • save_sel_num (used for output only)
  • sel_a
  • sel_l
  • sel_l_r
  • migrrate
  • retain
  • retain_a
  • discmort
  • discmort2_a
  • discmort2
  • discmort_a

Seasonal values that yet derived from above in Make_FishSelex() sel_dead_num and 5 other sel vectors

vector created in get_mat_fec() for spawn season only fec and then gets stored in Wt_Age_t(t, -2, g)

Quantities used in equil_calcs, so all need to be available before calls to equil_calc: t_base = styr + (eq_yr - styr) * nseas - 1; recr_dist(y natM(t_base + natM(t, natM(t_base + 1 Hermaphro_val(GP4(g) migrrate(bio_yr sel_dead_bio(s and 5 similar sel_ vectors pred_M2(f1, t) using t=t_base+s Wt_Age_beg(s fec(


add temp output of bio_yr and t_base to check what equil_calc is using. Find that during forecast the bio_yr was set to endyr, not to the current forecast year.

Rick-Methot-NOAA avatar Oct 04 '24 01:10 Rick-Methot-NOAA