Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Make tfdbg tests pass in Windows Bazel build #6821

Merged
merged 1 commit into from Jan 13, 2017
Merged
Show file tree
Hide file tree
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Jump to
Jump to file
Failed to load files.
Diff view
Diff view
2 changes: 1 addition & 1 deletion tensorflow/core/kernels/BUILD
Expand Up @@ -430,7 +430,6 @@ ARRAY_DEPS = [
cc_library(
name = "array_not_windows",
deps = [
":debug_ops",
":immutable_constant_op",
],
)
Expand Down Expand Up @@ -469,6 +468,7 @@ cc_library(
":bitcast_op",
":concat_op",
":constant_op",
":debug_ops",
":depth_space_ops",
":diag_op",
":edit_distance_op",
Expand Down
2 changes: 1 addition & 1 deletion tensorflow/core/kernels/debug_ops.h
Expand Up @@ -127,7 +127,7 @@ class DebugNanCountOp : public OpKernel {
const T* input_flat = input.template flat<T>().data();

for (int64 i = 0; i < input_shape.num_elements(); ++i) {
if (Eigen::numext::isnan(input_flat[i])) {
if (Eigen::numext::isnan(static_cast<double>(input_flat[i]))) {
nan_count++;
}
}
Expand Down
3 changes: 2 additions & 1 deletion tensorflow/python/debug/cli/analyzer_cli_test.py
Expand Up @@ -1608,7 +1608,8 @@ def testMultipleDumpsPrintTensorWithNumber(self):
self.assertEqual(" dtype: int32", output.lines[1])
self.assertEqual(" shape: ()", output.lines[2])
self.assertEqual("", output.lines[3])
self.assertEqual("array(%d, dtype=int32)" % i, output.lines[4])
self.assertTrue(output.lines[4].startswith("array(%d" % i))
self.assertTrue(output.lines[4].endswith(")"))

def testMultipleDumpsPrintTensorInvalidNumber(self):
output = self._registry.dispatch_command("pt",
Expand Down
2 changes: 1 addition & 1 deletion tensorflow/python/debug/debug_data.py
Expand Up @@ -290,7 +290,7 @@ def __init__(self, dump_root, debug_dump_rel_path):
self._debug_op = base.split("_")[-2]
self._output_slot = int(base.split("_")[-3])

namespace = os.path.dirname(debug_dump_rel_path)
namespace = os.path.dirname(debug_dump_rel_path).replace("\\", "/")
node_base_name = "_".join(base.split("_")[:-3])
if not namespace or namespace == ".":
self._node_name = node_base_name
Expand Down
2 changes: 1 addition & 1 deletion tensorflow/python/debug/debug_data_test.py
Expand Up @@ -133,7 +133,7 @@ def testDTypeComplexWorks(self):
a = np.array([1j, 3j, 3j, 7j], dtype=np.complex128)
self.assertFalse(debug_data.has_inf_or_nan(self._dummy_datum, a))

b = np.array([1j, 3j, 3j, 7j, np.nan], dtype=np.complex256)
b = np.array([1j, 3j, 3j, 7j, np.nan], dtype=np.complex128)
self.assertTrue(debug_data.has_inf_or_nan(self._dummy_datum, b))

def testDTypeIntegerWorks(self):
Expand Down
2 changes: 1 addition & 1 deletion tensorflow/tools/ci_build/windows/bazel/bazel_test_lib.sh
Expand Up @@ -121,7 +121,7 @@ function get_failing_cpu_py_tests() {
//$1/tensorflow/python:session_test + \
//$1/tensorflow/python:supervisor_test + \
//$1/tensorflow/python:sync_replicas_optimizer_test + \
//$1/tensorflow/python/debug/... + \
//$1/tensorflow/python/debug:curses_ui_test + \
//$1/tensorflow/python/kernel_tests:as_string_op_test + \
//$1/tensorflow/python/kernel_tests:benchmark_test + \
//$1/tensorflow/python/kernel_tests:cast_op_test + \
Expand Down