static */
| 63 | } |
| 64 | |
| 65 | /* static */ string ToString(const WindowDimension& dim) { |
| 66 | using absl::StrAppend; |
| 67 | using absl::StrCat; |
| 68 | string str = StrCat("(size=", dim.size()); |
| 69 | if (dim.stride() != 1) { |
| 70 | StrAppend(&str, ",stride=", dim.stride()); |
| 71 | } |
| 72 | if (dim.padding_low() != 0) { |
| 73 | StrAppend(&str, ",padding_low=", dim.padding_low()); |
| 74 | } |
| 75 | if (dim.padding_high() != 0) { |
| 76 | StrAppend(&str, ",padding_high=", dim.padding_high()); |
| 77 | } |
| 78 | if (dim.base_dilation() != 1) { |
| 79 | StrAppend(&str, ",base_dilation=", dim.base_dilation()); |
| 80 | } |
| 81 | if (dim.window_dilation() != 1) { |
| 82 | StrAppend(&str, ",window_dilation=", dim.window_dilation()); |
| 83 | } |
| 84 | if (dim.window_reversal()) { |
| 85 | StrAppend(&str, ",window_reversal"); |
| 86 | } |
| 87 | StrAppend(&str, ")"); |
| 88 | return str; |
| 89 | } |
| 90 | |
| 91 | string ToString(const Window& window) { |
| 92 | using absl::StrAppend; |