B:BD[
3.252] → [
2.629:864]
outputs = monitor.snapshot()(inputs)
outputs = tf.math.multiply(255, tf.reshape(outputs, (512, 1024, outputs.shape[1])))
image = tensor_to_surface(outputs)
sdl2.SDL_BlitSurface(image, None, windowsurface, None)
if time.monotonic() - last_rendered > 15:
outputs = monitor.snapshot()(inputs)
outputs = tf.math.multiply(255, tf.reshape(outputs, (512, 1024, outputs.shape[1])))
image = tensor_to_surface(outputs)
sdl2.SDL_BlitSurface(image, None, windowsurface, None)
last_rendered = time.monotonic()
sdl2.SDL_FreeSurface(image)