W3cubDocs

/TensorFlow 2.4

tf.raw_ops.ImageProjectiveTransformV2

Applies the given transform to each of the images.

If one row of transforms is [a0, a1, a2, b0, b1, b2, c0, c1], then it maps the output point (x, y) to a transformed input point (x', y') = ((a0 x + a1 y + a2) / k, (b0 x + b1 y + b2) / k), where k = c0 x + c1 y + 1. If the transformed point lays outside of the input image, the output pixel is set to 0.

Args
images A Tensor. Must be one of the following types: uint8, int32, int64, half, float32, float64. 4-D with shape [batch, height, width, channels].
transforms A Tensor of type float32. 2-D Tensor, [batch, 8] or [1, 8] matrix, where each row corresponds to a 3 x 3 projective transformation matrix, with the last entry assumed to be 1. If there is one row, the same transformation will be applied to all images.
output_shape A Tensor of type int32. 1-D Tensor [new_height, new_width].
interpolation A string. Interpolation method, "NEAREST" or "BILINEAR".
fill_mode An optional string. Defaults to "CONSTANT". Fill mode, "REFLECT", "WRAP", or "CONSTANT".
name A name for the operation (optional).
Returns
A Tensor. Has the same type as images.

© 2020 The TensorFlow Authors. All rights reserved.
Licensed under the Creative Commons Attribution License 3.0.
Code samples licensed under the Apache 2.0 License.
https://www.tensorflow.org/versions/r2.4/api_docs/python/tf/raw_ops/ImageProjectiveTransformV2