-
Notifications
You must be signed in to change notification settings - Fork 74.8k
Closed
Labels
TF 2.3Issues related to TF 2.3Issues related to TF 2.3comp:opsOPs related issuesOPs related issuesstat:awaiting tensorflowerStatus - Awaiting response from tensorflowerStatus - Awaiting response from tensorflowertype:bugBugBug
Description
System information
- Have I written custom code (as opposed to using a stock example script provided in TensorFlow): yes
- OS Platform and Distribution (e.g., Linux Ubuntu 16.04): Ubuntu 18.04 (Google Colab)
- TensorFlow installed from (source or binary): pip
- TensorFlow version (use command below): 2.3
- Python version: 3.6.9
Describe the current behavior
I used these transform values
transform = [
[1, 0.027, -4.905, -0.025, 1.096, 4.518, 0, 0],
[1.041, 0.01, -10.256, -0.01, 1, -0.67, 0, 0],
[1, 0, 0, 0, 1.06, -2.536, 0, 0]
]
but the resulting images got.... weird dash lines. To view the images, you can open my notebook from link on the standalone code section.
Describe the expected behavior
It should be seamless without weird lines?
Standalone code to reproduce the issue
https://colab.research.google.com/drive/1z6zDhE6ikQr-aYHluxvlrpOhriztOmB0?usp=sharing
Other question
tensorflow/tensorflow/core/kernels/image_ops.cc
Lines 61 to 83 in 4910e8e
OP_REQUIRES_OK(ctx, ctx->GetAttr("interpolation", &interpolation_str)); | |
if (interpolation_str == "NEAREST") { | |
interpolation_ = Interpolation::NEAREST; | |
} else if (interpolation_str == "BILINEAR") { | |
interpolation_ = Interpolation::BILINEAR; | |
} else { | |
LOG(ERROR) << "Invalid interpolation " << interpolation_str | |
<< ". Supported types: NEAREST, BILINEAR"; | |
} | |
string mode_str; | |
OP_REQUIRES_OK(ctx, ctx->GetAttr("fill_mode", &mode_str)); | |
if (mode_str == "REFLECT") { | |
fill_mode_ = Mode::FILL_REFLECT; | |
} else if (mode_str == "WRAP") { | |
fill_mode_ = Mode::FILL_WRAP; | |
} else if (mode_str == "CONSTANT") { | |
fill_mode_ = Mode::FILL_CONSTANT; | |
} else if (mode_str == "NEAREST") { | |
fill_mode_ = Mode::FILL_NEAREST; | |
} else { | |
LOG(ERROR) << "Invalid mode " << mode_str | |
<< ". Supported types: REFLECT, WRAP, CONSTANT, NEAREST"; | |
} |
Also is this is only logging? It's not stopping me entering random string into
fill_mode
and interpolation
parameters?
Speculation
My speculation is, it seems like the code responsible for map the coordinate miss by 1 pixel? I tried to understand image_ops
code but I don't get which one it is.
Metadata
Metadata
Assignees
Labels
TF 2.3Issues related to TF 2.3Issues related to TF 2.3comp:opsOPs related issuesOPs related issuesstat:awaiting tensorflowerStatus - Awaiting response from tensorflowerStatus - Awaiting response from tensorflowertype:bugBugBug