Skip to content
This repository was archived by the owner on Apr 28, 2023. It is now read-only.

Commit cf08de0

Browse files
authored
Merge pull request #298 from mitmul/fix-serializeToProtobuf
Fix serializeToProtobuf method of Options
2 parents 46a7b74 + dedf920 commit cf08de0

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

tensor_comprehensions/pybinds/pybind_options.cc

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -90,7 +90,10 @@ PYBIND11_MODULE(mapping_options, m) {
9090
"Require TC to try and execute different TC expressions interleaved (Max), separately (Min)\nor interleaved as long as sufficient parallelism is exploited (Preserve3Coincident) by\nperforming loop fusion and fission. Applies before tiling")
9191
.def(
9292
"serializeToProtobuf",
93-
&tc::CudaMappingOptions::toProtobufSerializedString,
93+
[](tc::CudaMappingOptions& instance) {
94+
std::string str = instance.toProtobufSerializedString();
95+
return py::bytes(str);
96+
},
9497
"Serialize the options to a protobuf string")
9598
.def(
9699
"tile",

0 commit comments

Comments
 (0)