<SYSTEM_TASK:>
Solve the following problem using Python, implementing the functions described below, one line at a time
<END_TASK>
<USER_TASK:>
Description:
 def com_google_fonts_check_unitsperem(ttFont):
 """Checking unitsPerEm value is reasonable."""

  upem = ttFont['head'].unitsPerEm
  target_upem = [2**i for i in range(4, 15)]
  target_upem.append(1000)
  target_upem.append(2000)
  if upem < 16 or upem > 16384:
    yield FAIL, ("The value of unitsPerEm at the head table"
                 " must be a value between 16 and 16384."
                 " Got '{}' instead.").format(upem)
  elif upem not in target_upem:
    yield WARN, ("In order to optimize performance on some"
                 " legacy renderers, the value of unitsPerEm"
                 " at the head table should idealy be"
                 " a power of between 16 to 16384."
                 " And values of 1000 and 2000 are also"
                 " common and may be just fine as well."
                 " But we got upm={} instead.").format(upem)
  else:
    yield PASS, ("unitsPerEm value ({}) on the 'head' table"
                 " is reasonable.").format(upem)