def advantage(cpu_dt, gpu_dt):
 assert ((gpu_dt >= 0) and (cpu_dt >= 0))
 if ((gpu_dt == 0) and (cpu_dt == 0)):
  return numpy.nan
 elif (gpu_dt == 0):
  return numpy.inf
 else:
  return (cpu_dt / gpu_dt)

def advantage ( cpu_dt , gpu_dt ) : assert ( ( gpu_dt >= 0 ) and ( cpu_dt >= 0 ) ) if ( ( gpu_dt == 0 ) and ( cpu_dt == 0 ) ) : return numpy . nan elif ( gpu_dt == 0 ) : return numpy . inf else : return ( cpu_dt / gpu_dt )
return ratio of cpu_dt / gpu_dt .