View source on GitHub |
Translates image in X or Y dimension.
tfa.image.translate_xy(
image: tfa.types.TensorLike
,
translate_to: tfa.types.TensorLike
,
replace: tfa.types.TensorLike
) -> tfa.types.TensorLike
Args | |
---|---|
image
|
A 3D image Tensor .
|
translate_to
|
A 1D Tensor to translate [x, y] .
|
replace
|
A one or three value 1D Tensor to fill empty pixels.
|
Returns | |
---|---|
Translated image along X or Y axis, with space outside image filled with replace. |
Raises | |
---|---|
ValueError
|
if axis is neither 0 nor 1. |