| 208 | namespace { |
| 209 | |
| 210 | Maybe<Shape> GetPhysicalShape(const Shape& logical_shape, const NdSbp& nd_sbp, |
| 211 | const ParallelDesc& parallel_desc, |
| 212 | const Optional<int64_t>& parallel_id) { |
| 213 | if (parallel_id.has_value()) { |
| 214 | return GetPhysicalShape(logical_shape, nd_sbp, parallel_desc, JUST(parallel_id)); |
| 215 | } else { |
| 216 | return std::make_shared<Shape>(DimVector(logical_shape.NumAxes(), 0)); |
| 217 | } |
| 218 | } |
| 219 | |
| 220 | } // namespace |
| 221 |
no test coverage detected