Skip to content
Closed
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
2 changes: 1 addition & 1 deletion python/tvm/relay/frontend/tflite.py
Original file line number Diff line number Diff line change
Expand Up @@ -3210,7 +3210,7 @@ def get_pad_value(data, kernel, stride):
"""

out = int(math.ceil(float(data) / float(stride)))
pad = max(0, (out - 1) * stride + kernel - data)
pad = max(0, (out - 1) * int(stride) + int(kernel) - int(data))
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Do we want to somehow test the compilation for skylake/cascadelake target?

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Also, do we know why this fails with int64? AFAIU from your RFC: https://discuss.tvm.apache.org/t/int64-vs-int32-dtype-error/8555 this used to work before.

pad_before = pad // 2
pad_after = pad - pad_before
return pad_before, pad_after
Expand Down
2 changes: 2 additions & 0 deletions src/printer/relay_text_printer.cc
Original file line number Diff line number Diff line change
Expand Up @@ -305,6 +305,8 @@ Doc RelayTextPrinter::ScalarLiteral(DataType dtype, const T& value) {
std::ostringstream os;
if (dtype == DataType::Int(32)) {
os << value;
} else if (dtype == DataType::Int(64)) {
os << value << "i64";
} else if (dtype == DataType::Float(32)) {
os << value << 'f';
} else if (dtype == DataType::Float(64)) {
Expand Down