Skip to content

Commit

Permalink
ensure NHWC
Browse files Browse the repository at this point in the history
  • Loading branch information
kali committed Jun 29, 2023
1 parent bee07d0 commit d418890
Showing 1 changed file with 2 additions and 0 deletions.
2 changes: 2 additions & 0 deletions tflite/src/model.rs
Original file line number Diff line number Diff line change
Expand Up @@ -4,6 +4,7 @@ use flatbuffers::{FlatBufferBuilder, Push, Vector, WIPOffset};
use tract_hir::internal::*;
use tract_hir::ops::cnn::ConvUnary;
use tract_hir::ops::konst::Const;
use tract_hir::ops::nn::DataFormat;
use tract_hir::prelude::tract_itertools::Itertools;
use tract_hir::tract_core::ops::source::TypedSource;

Expand Down Expand Up @@ -135,6 +136,7 @@ fn write_subgraph<'f>(
})
.into(),
)?);
ensure!(conv.pool_spec.data_format == DataFormat::NHWC);
let options = Conv2DOptions::create(builder, &Conv2DOptionsArgs {
padding: Padding::VALID,
stride_w: 1,
Expand Down

0 comments on commit d418890

Please sign in to comment.