File tree Expand file tree Collapse file tree 1 file changed +6
-6
lines changed
core/conversion/converters/impl Expand file tree Collapse file tree 1 file changed +6
-6
lines changed Original file line number Diff line number Diff line change @@ -80,20 +80,20 @@ auto reduce_registrations TRTORCH_UNUSED =
80
80
[](ConversionCtx* ctx, const torch::jit::Node* n, args& args) -> bool {
81
81
auto in_tensor = args[0 ].ITensorOrFreeze (ctx);
82
82
auto dims = args[1 ].unwrapToIntList ();
83
- c10::List<int64_t > dims_copy ;
83
+ c10::List<int64_t > calculated_dims ;
84
84
auto in_dims = util::toVec (in_tensor->getDimensions ());
85
85
LOG_DEBUG (" InDims " << in_dims); // Some abuse of toDim but just for debug info
86
86
LOG_DEBUG (" Dim to reduce(original):" << util::toDims (dims)); // Some abuse of toDim but just for debug info
87
87
for (int i = 0 ; i < dims.size (); i++) {
88
88
auto dim_val = dims[i] == -1 ? (in_dims.size () - 1 ) : dims[i];
89
- dims_copy .push_back (dim_val);
89
+ calculated_dims .push_back (dim_val);
90
90
}
91
-
92
- LOG_DEBUG (" Dim to reduce(converted):" << util::toDims (dims_copy )); // Some abuse of toDim but just for debug info
91
+
92
+ LOG_DEBUG (" Dim to reduce(converted):" << util::toDims (calculated_dims )); // Some abuse of toDim but just for debug info
93
93
94
94
uint32_t axis_mask = 0 ;
95
- for (size_t d = 0 ; d < dims_copy .size (); d++) {
96
- axis_mask |= 1 << dims_copy [d];
95
+ for (size_t d = 0 ; d < calculated_dims .size (); d++) {
96
+ axis_mask |= 1 << calculated_dims [d];
97
97
}
98
98
LOG_DEBUG (" Axis Mask" << std::bitset<32 >(axis_mask));
99
99
You can’t perform that action at this time.
0 commit comments