Set proper default values for pool attributes (#15559)

### Description
Setting proper default value for attributes of pool operators


### Motivation and Context
Fixed AB#14719

Global pooling and pooling operators usually share the same underlying
implementation. When we detect the operator is global, code for setting
up the attributes is skipped. This may cause un-deterministic behavior.
This commit is contained in:
Chen Fu 2023-04-19 17:24:35 -07:00 committed by GitHub
parent f2889b41c1
commit 29d00fb776
No known key found for this signature in database
GPG key ID: 4AEE18F83AFDEB23

View file

@ -93,8 +93,8 @@ struct PoolAttributes {
TensorShapeVector strides;
TensorShapeVector dilations; // Introduced in MaxPool_10
// default_dilations is true if dilations is not set or all dilations are 1
bool default_dilations;
AutoPadType auto_pad;
bool default_dilations{false};
AutoPadType auto_pad{AutoPadType::NOTSET};
TensorShapeVector SetOutputSize(const TensorShape& input_shape,
int64_t output_channel,