Save bake image as 32 bit float?

That still does not work. Saving by hand works fine.

Here is the test code:

import bpy

mat_node_tree = bpy.context.active_object.material_slots['Material'].material.node_tree

img_name = "test.tif"
image = bpy.data.images.new(name=img_name, width=256, height=256, float_buffer=True)
image.filepath = "//"+img_name

image_node = mat_node_tree.nodes.new(type="ShaderNodeTexImage")
image_node.image = image
image_node.select = True
mat_node_tree.nodes.active = image_node

bpy.ops.object.bake(type='EMIT')

bpy.types.ImageFormatSettings.file_format = 'TIFF'
bpy.types.ImageFormatSettings.color_depth = '16'

image.save()