Skip to content

Commit

Permalink
debug
Browse files Browse the repository at this point in the history
  • Loading branch information
wejoncy committed Dec 2, 2024
1 parent bf095dd commit d64d79c
Showing 1 changed file with 7 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -61,8 +61,6 @@ Status SqueezeOpBuilder::AddToModelBuilderImpl(ModelBuilder& model_builder,
auto* coreml_squeeze = layer->mutable_squeeze();
TensorShapeVector axes;
GetAxes(model_builder, node, axes);
std::vector<int64_t> input_shape;
GetShape(*input_defs[0], input_shape, logger);
#if defined(COREML_ENABLE_MLPROGRAM)
if (model_builder.CreateMLProgram()) {
using namespace CoreML::Specification::MILSpec;
Expand All @@ -76,6 +74,13 @@ Status SqueezeOpBuilder::AddToModelBuilderImpl(ModelBuilder& model_builder,
// coreml squeeze op does support negative axes
AddOperationInput(*op, "axes", model_builder.AddConstant(op->type(), "axes", AsSpan(axes)));
}
std::vector<int64_t> input_shape;
std::cout << "========================\n";
GetShape(*node.OutputDefs()[0], input_shape, logger);
for (size_t i = 0; i < input_shape.size(); ++i) {
std::cout << input_shape[i] << " ";
}
std::cout << std::endl;

Check warning on line 83 in onnxruntime/core/providers/coreml/builders/impl/squeeze_op_builder.cc

View workflow job for this annotation

GitHub Actions / Optional Lint C++

[cpplint] reported by reviewdog 🐶 Add #include <iostream> for cout [build/include_what_you_use] [4] Raw Output: onnxruntime/core/providers/coreml/builders/impl/squeeze_op_builder.cc:83: Add #include <iostream> for cout [build/include_what_you_use] [4]
AddOperationOutput(*op, *node.OutputDefs()[0]);
model_builder.AddOperation(std::move(op));
} else // NOLINT
Expand Down

0 comments on commit d64d79c

Please sign in to comment.