logger.debug("SUB id=%s transit='%sUTC''%sLST' for %s %s task_proposed_center_time='%s'",scheduling_unit.id,transit_timestamp,transit_timestamp_lst,station,pointing.str_astro(),task_proposed_center_time)
logger.debug("SUB id=%s transit='%sUTC''%sLST' for %s %s near task_proposed_center_time='%s'",scheduling_unit.id,transit_timestamp,transit_timestamp_lst,station,pointing.str_astro(),task_proposed_center_time)
result.message="offset of %s[s] at task_center='%s' from transit at '%s' at %s for %s is not within [%s, %s]"%(offset,task_proposed_center_time,transit_timestamp,station,pointing,transit_from_limit,transit_to_limit)
logger.debug(result)
# transit minus half duration is by definition the optimal start_time
# also take the task relative start time against the su.starttime into account
result.message="offset of %s[s] at task_center='%s' from transit at '%s' at %s for %s is not within [%s, %s]"%(offset,task_proposed_center_time,transit_timestamp,station,pointing,transit_from_limit,transit_to_limit)
# log and early exit, cause the constraint is not met.
logger.debug(result)
returnresult
ifresult.message:
# the message was set for one or more failing task/target/station transit_offset constraints
result.score=0
else:
# all task/target/station transit_offset constraints were met.
# compute overall score
# 1.0 when proposed_center_time==transit_timestamp