mirror of
https://github.com/saymrwulf/onnxruntime.git
synced 2026-07-30 20:18:08 +00:00
Replace gsl::narrow with narrow in WebNN code (#22733)
Replace use of `gsl::narrow` with `narrow` to build for WebNN @snnn ### Description Building for WebNN with exceptions disabled cannot use `gsl::narrow`. Replace with `narrow` ### Motivation and Context Address issue #22712
This commit is contained in:
parent
db72096d17
commit
00461d1205
1 changed files with 2 additions and 2 deletions
|
|
@ -73,8 +73,8 @@ Status SplitOpBuilder::AddToModelBuilderImpl(ModelBuilder& model_builder,
|
|||
// Check that the splits evenly divide.
|
||||
if (split_count > 0 && splits.empty() && input_shape[axis] % split_count != 0) {
|
||||
// Divide inputs into variable size outputs:
|
||||
splits.insert(splits.end(), split_count - 1, gsl::narrow<uint32_t>(input_shape[axis]) / split_count);
|
||||
splits.insert(splits.end(), gsl::narrow<uint32_t>(input_shape[axis]) % split_count);
|
||||
splits.insert(splits.end(), split_count - 1, narrow<uint32_t>(input_shape[axis]) / split_count);
|
||||
splits.insert(splits.end(), narrow<uint32_t>(input_shape[axis]) % split_count);
|
||||
}
|
||||
|
||||
if (splits.empty()) {
|
||||
|
|
|
|||
Loading…
Reference in a new issue