Disable printing the ops on error in TFLite converter.
PiperOrigin-RevId: 335521410 Change-Id: Ic54a57683ee796eb19116c3d8b4f861f22e1356b
This commit is contained in:
parent
e888d69e4e
commit
9c4a57e69b
@ -139,6 +139,9 @@ Status ConvertTFExecutorToTFLOrFlatbuffer(
|
|||||||
bool emit_select_tf_ops, bool emit_custom_ops,
|
bool emit_select_tf_ops, bool emit_custom_ops,
|
||||||
const mlir::TFL::QuantizationSpecs& quant_specs, std::string* result,
|
const mlir::TFL::QuantizationSpecs& quant_specs, std::string* result,
|
||||||
mlir::PassManager* pass_manager) {
|
mlir::PassManager* pass_manager) {
|
||||||
|
// Explicitly disable dumping Op details on failures.
|
||||||
|
module.getContext()->printOpOnDiagnostic(false);
|
||||||
|
|
||||||
// Register a warning handler only log to std out.
|
// Register a warning handler only log to std out.
|
||||||
mlir::ScopedDiagnosticHandler s(
|
mlir::ScopedDiagnosticHandler s(
|
||||||
module.getContext(), [](mlir::Diagnostic& diag) {
|
module.getContext(), [](mlir::Diagnostic& diag) {
|
||||||
|
Loading…
Reference in New Issue
Block a user