This was a note in another issue, but I believe it warrants its own issue to keep track of this.
why does quad_lon_lat_evaluate_ir_array care about missing_r8 but quad_lon_lat_evaluate_ii_array does not?
Note the missing_ok_in_state is for models like CLM that have some members with missing values and others with non-missing values at the same location.
2580 ! Rectangular bilinear interpolation
!>@todo FIXME should this code check invals(:) for MISSING_R8?
!> it costs time and for grids that don't have missing data it is
!> not needed. should it call allow_missing_in_state() on init and
!> key off that? (i think yes.)
if (missing_ok_in_state) then
! have to do the items individually because some items might
! have missing and others not.
do i=1, nitems
if (any(invals(:, i) == MISSING_R8)) then
outvals(i) = MISSING_R8
istatus(i) = 1
else
xbot(1) = invals(1, i) + lon_fract * (invals(2, i) - invals(1, i))
xtop(1) = invals(4, i) + lon_fract * (invals(3, i) - invals(4, i))
outvals(i) = xbot(1) + lat_fract * (xtop(1) - xbot(1))
istatus(i) = 0
endif
enddo
return
else
edit: why does quad_lon_lat_evaluate_ir_array care about missing_r8 but quad_lon_lat_evaluate_ii_array does not?
Originally posted by @hkershaw-brown in #249
This was a note in another issue, but I believe it warrants its own issue to keep track of this.
why does
quad_lon_lat_evaluate_ir_arraycare about missing_r8 butquad_lon_lat_evaluate_ii_arraydoes not?Note the missing_ok_in_state is for models like CLM that have some members with missing values and others with non-missing values at the same location.
Originally posted by @hkershaw-brown in #249