Skip to content

Commit 83d6811

Browse files
committed
Improved __repr__ for SLACDebugOption and SLACOptimizerParams.
1 parent 4d602a5 commit 83d6811

File tree

1 file changed

+6
-5
lines changed

1 file changed

+6
-5
lines changed

cpp/pybind/t/pipelines/slac/slac.cpp

Lines changed: 6 additions & 5 deletions
Original file line numberDiff line numberDiff line change
@@ -94,10 +94,11 @@ void pybind_slac_definitions(py::module &m) {
9494
"folder.")
9595
.def("__repr__", [](const SLACOptimizerParams &params) {
9696
return fmt::format(
97-
"SLACOptimizerParams[max_iterations={:d}, "
97+
"SLACOptimizerParams(max_iterations={:d}, "
9898
"voxel_size={:e}, distance_threshold={:e}, "
9999
"fitness_threshold={:e}, regularizer_weight={:e}, "
100-
"device={}, slac_folder={}].",
100+
"device=open3d.core.Device(\"{}\"), "
101+
"slac_folder=\"{}\")",
101102
params.max_iterations_, params.voxel_size_,
102103
params.distance_threshold_, params.fitness_threshold_,
103104
params.regularizer_weight_, params.device_.ToString(),
@@ -117,9 +118,9 @@ void pybind_slac_definitions(py::module &m) {
117118
"will be skipped for visualization.")
118119
.def("__repr__", [](const SLACDebugOption &debug_option) {
119120
return fmt::format(
120-
"SLACDebugOption[debug={}, "
121-
"debug_start_node_idx={:d}].",
122-
debug_option.debug_,
121+
"SLACDebugOption(debug={}, "
122+
"debug_start_node_idx={:d})",
123+
debug_option.debug_ ? "True" : "False",
123124
debug_option.debug_start_node_idx_);
124125
});
125126
auto control_grid =

0 commit comments

Comments
 (0)